Lib fully migrated to Standard

CryptographicEngine.DeriveKeyMaterial exception...
This commit is contained in:
bg45
2017-09-23 18:30:04 -04:00
parent 32e629231c
commit 3bf8015280
13 changed files with 142 additions and 69 deletions

View File

@@ -87,9 +87,9 @@ namespace ModernKeePassLibPCL.Keys
Construct(iocKeyFile, bThrowIfDbFile);
}
private void Construct(IOConnectionInfo iocFile, bool bThrowIfDbFile)
private async void Construct(IOConnectionInfo iocFile, bool bThrowIfDbFile)
{
byte[] pbFileData = IOConnection.ReadFile(iocFile);
byte[] pbFileData = await IOConnection.ReadFile(iocFile);
if(pbFileData == null) throw new FileNotFoundException();
if(bThrowIfDbFile && (pbFileData.Length >= 8))
@@ -310,7 +310,7 @@ namespace ModernKeePassLibPCL.Keys
return pbKeyData;
}
private static void CreateXmlKeyFile(string strFile, byte[] pbKeyData)
private static async void CreateXmlKeyFile(string strFile, byte[] pbKeyData)
{
Debug.Assert(strFile != null);
if(strFile == null) throw new ArgumentNullException("strFile");
@@ -318,7 +318,7 @@ namespace ModernKeePassLibPCL.Keys
if(pbKeyData == null) throw new ArgumentNullException("pbKeyData");
IOConnectionInfo ioc = IOConnectionInfo.FromPath(strFile);
Stream sOut = IOConnection.OpenWrite(ioc);
Stream sOut = await IOConnection.OpenWrite(ioc);
#if ModernKeePassLibPCL
var settings = new XmlWriterSettings() { Encoding = StrUtil.Utf8 };