diff --git a/src/KeyKeeper/PasswordStore/PassStoreFileAccessor.cs b/src/KeyKeeper/PasswordStore/PassStoreFileAccessor.cs index 8169c34..61ddb4c 100644 --- a/src/KeyKeeper/PasswordStore/PassStoreFileAccessor.cs +++ b/src/KeyKeeper/PasswordStore/PassStoreFileAccessor.cs @@ -63,8 +63,8 @@ public class PassStoreFileAccessor : IPassStore file.Seek((file.Position + 4096 - 1) / 4096 * 4096, SeekOrigin.Begin); key.Salt = hdr.PreSalt; - this.key = hdr.KdfInfo.GetKdf().Derive(key, 32); - using OuterEncryptionReader cryptoReader = new(file, this.key, ((OuterAesHeader)hdr.OuterCryptoHeader).InitVector); + byte[] masterKey = hdr.KdfInfo.GetKdf().Derive(key, 32); + using OuterEncryptionReader cryptoReader = new(file, masterKey, ((OuterAesHeader)hdr.OuterCryptoHeader).InitVector); using BinaryReader rd = new(cryptoReader); { @@ -103,6 +103,7 @@ public class PassStoreFileAccessor : IPassStore throw PassStoreFileException.UnexpectedEndOfFile; } } + this.key = masterKey; } public void Lock() diff --git a/src/KeyKeeper/RepositoryWindow.axaml b/src/KeyKeeper/RepositoryWindow.axaml index 849cd20..eb57a79 100644 --- a/src/KeyKeeper/RepositoryWindow.axaml +++ b/src/KeyKeeper/RepositoryWindow.axaml @@ -3,6 +3,7 @@ xmlns:vm="using:KeyKeeper.ViewModels" x:Class="KeyKeeper.RepositoryWindow" Title="KeyKeeper - Хранилище паролей" + CanResize="False" Width="800" Height="600" Background="White" @@ -13,7 +14,7 @@ @@ -42,8 +43,7 @@ -