]> Dogcows Code - chaz/p5-File-KDBX/blobdiff - lib/File/KDBX/KDF.pm
Make transform_rounds work with Argon KDF
[chaz/p5-File-KDBX] / lib / File / KDBX / KDF.pm
index ce32945361ad81ea6114421932b5a1d9e7b19e44..60b4acf516677f15ec1827ab2603196f5612a94f 100644 (file)
@@ -16,6 +16,15 @@ our $VERSION = '999.999'; # VERSION
 
 my %KDFS;
 
+our %ROUNDS_INFO = (
+    KDF_UUID_ARGON2D()  => {p => KDF_PARAM_ARGON2_ITERATIONS, d => KDF_DEFAULT_ARGON2_ITERATIONS},
+    KDF_UUID_ARGON2ID() => {p => KDF_PARAM_ARGON2_ITERATIONS, d => KDF_DEFAULT_ARGON2_ITERATIONS},
+);
+our $DEFAULT_ROUNDS_INFO = {
+    p => KDF_PARAM_AES_ROUNDS,
+    d => KDF_DEFAULT_AES_ROUNDS,
+};
+
 =method new
 
     $kdf = File::KDBX::KDF->new(parameters => \%params);
@@ -43,7 +52,8 @@ sub new {
 
     $kdf = $kdf->init(%attributes);
 
-Called by method to set attributes. You normally shouldn't call this.
+Called by L</new> to set attributes. You normally shouldn't call this. Returns itself to allow method
+chaining.
 
 =cut
 
@@ -109,7 +119,7 @@ sub _transform { die 'Not implemented' }
 
     $kdf->randomize_seed;
 
-Generate a new random seed/salt.
+Generate and set a new random seed/salt.
 
 =cut
 
This page took 0.016144 seconds and 4 git commands to generate.