1File::KDBX::Dumper(3) User Contributed Perl DocumentationFile::KDBX::Dumper(3)
2
3
4

NAME

6       File::KDBX::Dumper - Write KDBX files
7

VERSION

9       version 0.906
10

ATTRIBUTES

12   kdbx
13           $kdbx = $dumper->kdbx;
14           $dumper->kdbx($kdbx);
15
16       Get or set the File::KDBX instance with the data to be dumped.
17
18   format
19       Get the file format used for writing the database. Normally the format
20       is auto-detected from the database, which is the safest choice.
21       Possible formats:
22
23       •   "V3"
24
25       •   "V4"
26
27       •   "KDB"
28
29       •   "XML" (only used if explicitly set)
30
31       •   "Raw" (only used if explicitly set)
32
33       WARNING: There is a potential for data loss if you explicitly use a
34       format that doesn't support the features used by the KDBX database
35       being written.
36
37       The most common reason to explicitly specify the file format is to save
38       a database as an unencrypted XML file:
39
40           $kdbx->dump_file('database.xml', format => 'XML');
41
42   inner_format
43       Get the format of the data inside the KDBX envelope. This only applies
44       to "V3" and "V4" formats. Possible formats:
45
46       •   "XML" - Write the database groups and entries as XML (default)
47
48       •   "Raw" - Write "raw" in File::KDBX instead of the actual database
49           contents
50
51   allow_upgrade
52           $bool = $dumper->allow_upgrade;
53
54       Whether or not to allow implicitly upgrading a database to a newer
55       version. When enabled, in order to avoid potential data loss, the
56       database can be upgraded as-needed in cases where the database file
57       format version is too low to support new features being used.
58
59       The default is to allow upgrading.
60
61   randomize_seeds
62           $bool = $dumper->randomize_seeds;
63
64       Whether or not to randomize seeds in a database before writing. The
65       default is to randomize seeds, and there's not often a good reason not
66       to do so. If disabled, the seeds associated with the KDBX database will
67       be used as they are.
68

METHODS

70   new
71           $dumper = File::KDBX::Dumper->new(%attributes);
72
73       Construct a new File::KDBX::Dumper.
74
75   init
76           $dumper = $dumper->init(%attributes);
77
78       Initialize a File::KDBX::Dumper with a new set of attributes.
79
80       This is called by "new".
81
82   reset
83           $dumper = $dumper->reset;
84
85       Set a File::KDBX::Dumper to a blank state, ready to dump another KDBX
86       file.
87
88   dump
89           $dumper->dump(\$string, %options);
90           $dumper->dump(\$string, $key, %options);
91           $dumper->dump(*IO, %options);
92           $dumper->dump(*IO, $key, %options);
93           $dumper->dump($filepath, %options);
94           $dumper->dump($filepath, $key, %options);
95
96       Dump a KDBX file.
97
98       The $key is either a File::KDBX::Key or a primitive castable to a Key
99       object. Available options:
100
101       •   "kdbx" - Database to dump (default: value of "kdbx")
102
103       •   "key" - Alternative way to specify $key (default: value of
104           "File::KDBX/key")
105
106       Other options are supported depending on the first argument. See
107       "dump_string", "dump_file" and "dump_handle".
108
109   dump_string
110           $dumper->dump_string(\$string, %options);
111           $dumper->dump_string(\$string, $key, %options);
112           \$string = $dumper->dump_string(%options);
113           \$string = $dumper->dump_string($key, %options);
114
115       Dump a KDBX file to a string / memory buffer. Available options:
116
117       •   "kdbx" - Database to dump (default: value of "kdbx")
118
119       •   "key" - Alternative way to specify $key (default: value of
120           "File::KDBX/key")
121
122   dump_file
123           $dumper->dump_file($filepath, %options);
124           $dumper->dump_file($filepath, $key, %options);
125
126       Dump a KDBX file to a filesystem. Available options:
127
128       •   "kdbx" - Database to dump (default: value of "kdbx")
129
130       •   "key" - Alternative way to specify $key (default: value of
131           "File::KDBX/key")
132
133       •   "mode" - File mode / permissions (see "chmod LIST" in perlfunc
134
135       •   "uid" - User ID (see "chown LIST" in perlfunc)
136
137       •   "gid" - Group ID (see "chown LIST" in perlfunc)
138
139       •   "atomic" - Write to the filepath atomically (default: true)
140
141   dump_handle
142           $dumper->dump_handle($fh, %options);
143           $dumper->dump_handle(*IO, $key, %options);
144           $dumper->dump_handle($fh, %options);
145           $dumper->dump_handle(*IO, $key, %options);
146
147       Dump a KDBX file to an output stream / file handle. Available options:
148
149       •   "kdbx" - Database to dump (default: value of "kdbx")
150
151       •   "key" - Alternative way to specify $key (default: value of
152           "File::KDBX/key")
153

BUGS

155       Please report any bugs or feature requests on the bugtracker website
156       <https://github.com/chazmcgarvey/File-KDBX/issues>
157
158       When submitting a bug or request, please include a test-file or a patch
159       to an existing test-file that illustrates the bug or desired feature.
160

AUTHOR

162       Charles McGarvey <ccm@cpan.org>
163
165       This software is copyright (c) 2022 by Charles McGarvey.
166
167       This is free software; you can redistribute it and/or modify it under
168       the same terms as the Perl 5 programming language system itself.
169
170
171
172perl v5.36.1                      2023-09-27             File::KDBX::Dumper(3)
Impressum