Work at SourceForge, help us to make it a better place! We have an immediate need for a Support Technician in our San Francisco or Denver office.
I just noticed, that Kypass on iOS uses some sort of different compression levels than keepass 2.x does?
If I use a kdbx on PC and save it, its about 1/3 of size bigger then when I saved it last on iOS. I do see no difference in the export of the xml, so can someone explain to whats happening here?
I found some hints, that also Android Version does this:
If it is a setting in the GZIP-Library (like compression level), maybe it would be great to make it available in the database settings.
I am using the databases mobile and with one database the difference is 28 KByte --> 18 KByte and I have a bigger one which I have not tested yet, which has 161 KByte as a kdbx.
Uff, I just tested the 161 KByte File on iOS.
The file will have 55 KByte (!!!) after usage on the iPad.
So the compression is a lot better and makes sense for mobility (Data bandwidth and data usage).
Differences in database file sizes of the same database across OSes are usually attributed to differences in the implementation of the lossless GZIP compression algorithm or differences in support for entry histories. Since Kypass is a third-party port of KeePass, the KyPass developer is probably in a better position to account for the specific differences.
My gerneral question was, if the library that is used in keepass might have different compression levels and is set to a "fast" variant.
Maybe it is something that can even be improved by Dominik.
KeePass uses the GZipStream class  provided by the .NET Framework. Specifying a compression level is not supported by .NET 4.0 and earlier. In .NET 4.5, the compression was improved (by using the ZLib library), levels are supported and it defaults to best compression (not speed).
In short: under .NET 4.5 you get a good compression, and under .NET 4.0 and earlier a moderate compression.
Many thanks. That explains it. We use .Net 4.0 at work.
There are another reason :)
KeePass use the class XmlTextWriter to generate the xml file.
This class add a lot of carriage return, tabulation and spaces by default to have a good looking xml file.
The XML generated by KyPass use [NSXMLDocument XMLDataWithOptions:NSXMLNodeCompactEmptyElement] function that doesn't add return, tabulation and spaces