NAME

File::KDBX::Cipher::Stream - A cipher stream encrypter/decrypter

VERSION

version 0.906

SYNOPSIS

use File::KDBX::Cipher::Stream;

my $cipher = File::KDBX::Cipher::Stream->new(algorithm => $algorithm, key => $key, iv => $iv);

DESCRIPTION

A subclass of File::KDBX::Cipher for encrypting and decrypting data using a stream cipher.

ATTRIBUTES

counter

$counter = $cipher->counter;

Get the initial counter / block count into the keystream.

offset

$offset = $cipher->offset;

Get the initial byte offset into the keystream. This has precedence over "counter" if both are set.

METHODS

crypt

$ciphertext = $cipher->crypt($plaintext);
$plaintext = $cipher->crypt($ciphertext);

Encrypt or decrypt some data. These ciphers are symmetric, so encryption and decryption are the same operation. This method is an alias for both "encrypt" in File::KDBX::Cipher and "decrypt" in File::KDBX::Cipher.

keystream

$stream = $cipher->keystream;

Access the keystream.

dup

$cipher_copy = $cipher->dup(%attributes);

Get a copy of an existing cipher with the counter reset, optionally applying new attributes.

BUGS

Please report any bugs or feature requests on the bugtracker website https://github.com/chazmcgarvey/File-KDBX/issues

When submitting a bug or request, please include a test-file or a patch to an existing test-file that illustrates the bug or desired feature.

AUTHOR

Charles McGarvey <ccm@cpan.org>

COPYRIGHT AND LICENSE

This software is copyright (c) 2022 by Charles McGarvey.

This is free software; you can redistribute it and/or modify it under the same terms as the Perl 5 programming language system itself.