File::...nstants(3pm)

πŸ“¦
version 0.906 Β· 4 versions
, in debian trixie, ubuntu resolute, ubuntu stonking

πŸ’– File::KDBX::Constants β€” the manual page, but make it slay πŸ’–

okay bestie, sit down, hydrate, because this is the File::KDBX::Constants page from the User Contributed Perl Documentation and it is literally about every KDBX-related constant you could ever want. no cap.

VERSION: version 0.906 ✨


🌸 SYNOPSIS 🌸

use File::KDBX::Constants qw(:all);

say KDBX_VERSION_4_1;

πŸ¦‹ DESCRIPTION πŸ¦‹

so this module is the plug: it hands you importable constants all about KDBX πŸ’…. you can pull them in one at a time or in lil groups (we call those groups tags). the tags that exist are, in this exact order:

  • :magic
  • :version
  • :header
  • :compression
  • :cipher
  • :random_stream
  • :kdf
  • :variant_map
  • :inner_header
  • :key_file
  • :history
  • :icon
  • :bool
  • :time
  • :yubikey
  • :all β€” all of the above, the whole buffet πŸ“

and if you're sitting there like "bestie what are the actual values", the page says: go view the source of this module to see the constant values (but really you shouldn't care). periodt. πŸ™ˆ


πŸ‘‘ FUNCTIONS πŸ‘‘

to_header_constant

$constant = to_header_constant($number);
$constant = to_header_constant($string);

hand it an integer or a string and it gives you back a header constant. iconic little converter, fr fr.

to_compression_constant

$constant = to_compression_constant($number);
$constant = to_compression_constant($string);

same vibe, but for compression constants β€” integer or string in, constant out 🫢.

to_inner_header_constant

$constant = to_inner_header_constant($number);
$constant = to_inner_header_constant($string);

yep, again: integer or string, and you get an inner header constant back.

to_icon_constant

$constant = to_icon_constant($number);
$constant = to_icon_constant($string);

number or string ➑️ icon constant. she's consistent πŸ’…


⭐ CONSTANTS ⭐

:magic

constants for figuring out what kind of file you're looking at πŸ”:

  • KDBX_SIG1
  • KDBX_SIG1_FIRST_BYTE
  • KDBX_SIG2_1
  • KDBX_SIG2_2

:version

constants for sniffing out the format version of a file:

  • KDBX_VERSION_2_0
  • KDBX_VERSION_3_0
  • KDBX_VERSION_3_1
  • KDBX_VERSION_4_0
  • KDBX_VERSION_4_1
  • KDBX_VERSION_OLDEST
  • KDBX_VERSION_LATEST
  • KDBX_VERSION_MAJOR_MASK
  • KDBX_VERSION_MINOR_MASK

constants for parsing and generating KDBX file headers πŸŽ€:

  • HEADER_END
  • HEADER_COMMENT
  • HEADER_CIPHER_ID
  • HEADER_COMPRESSION_FLAGS
  • HEADER_MASTER_SEED
  • HEADER_TRANSFORM_SEED
  • HEADER_TRANSFORM_ROUNDS
  • HEADER_ENCRYPTION_IV
  • HEADER_INNER_RANDOM_STREAM_KEY
  • HEADER_STREAM_START_BYTES
  • HEADER_INNER_RANDOM_STREAM_ID
  • HEADER_KDF_PARAMETERS
  • HEADER_PUBLIC_CUSTOM_DATA

:compression

constants for identifying the compression state of a file:

  • COMPRESSION_NONE
  • COMPRESSION_GZIP

:cipher

cipher constants, as promised:

  • CIPHER_UUID_AES128
  • CIPHER_UUID_AES256
  • CIPHER_UUID_CHACHA20
  • CIPHER_UUID_SALSA20
  • CIPHER_UUID_SERPENT
  • CIPHER_UUID_TWOFISH

:random_stream

constants about memory protection stream ciphers 🌈:

  • STREAM_ID_RC4_VARIANT
    • 🚨 okay listen: this one is insecure and not implemented. do not come for me, I'm just the messenger.
  • STREAM_ID_SALSA20
  • STREAM_ID_CHACHA20
  • STREAM_SALSA20_IV

:kdf

constants all about key derivation functions and their config:

  • KDF_UUID_AES
  • KDF_UUID_AES_CHALLENGE_RESPONSE
    • this is what KeePassXC calls "KDF_AES_KDBX4" πŸ’œ
  • KDF_UUID_ARGON2D
  • KDF_UUID_ARGON2ID
  • KDF_PARAM_UUID
  • KDF_PARAM_AES_ROUNDS
  • KDF_PARAM_AES_SEED
  • KDF_PARAM_ARGON2_SALT
  • KDF_PARAM_ARGON2_PARALLELISM
  • KDF_PARAM_ARGON2_MEMORY
  • KDF_PARAM_ARGON2_ITERATIONS
  • KDF_PARAM_ARGON2_VERSION
  • KDF_PARAM_ARGON2_SECRET
  • KDF_PARAM_ARGON2_ASSOCDATA
  • KDF_DEFAULT_AES_ROUNDS
  • KDF_DEFAULT_ARGON2_ITERATIONS
  • KDF_DEFAULT_ARGON2_MEMORY
  • KDF_DEFAULT_ARGON2_PARALLELISM
  • KDF_DEFAULT_ARGON2_VERSION

:variant_map

constants for parsing and generating KDBX4 variant maps πŸ—ΊοΈ:

  • VMAP_VERSION
  • VMAP_VERSION_MAJOR_MASK
  • VMAP_TYPE_END
  • VMAP_TYPE_UINT32
  • VMAP_TYPE_UINT64
  • VMAP_TYPE_BOOL
  • VMAP_TYPE_INT32
  • VMAP_TYPE_INT64
  • VMAP_TYPE_STRING
  • VMAP_TYPE_BYTEARRAY

:inner_header

constants for parsing and generating KDBX4 inner headers:

  • INNER_HEADER_END
  • INNER_HEADER_INNER_RANDOM_STREAM_ID
  • INNER_HEADER_INNER_RANDOM_STREAM_KEY
  • INNER_HEADER_BINARY
  • INNER_HEADER_BINARY_FLAG_PROTECT

:key_file

constants for identifying key file types πŸ”‘:

  • KEY_FILE_TYPE_BINARY
  • KEY_FILE_TYPE_HASHED
  • KEY_FILE_TYPE_HEX
  • KEY_FILE_TYPE_XML

:history

constants for history-related default values (the defaults, the whole defaults, nothing but the defaults):

  • HISTORY_DEFAULT_MAX_AGE
  • HISTORY_DEFAULT_MAX_ITEMS
  • HISTORY_DEFAULT_MAX_SIZE

:iteration

constants for searching algorithms. yes bestie, the algorithm girlies are here:

  • ITERATION_IDS β€” Iterative deepening search
  • ITERATION_BFS β€” Breadth-first search
  • ITERATION_DFS β€” Depth-first search

:icon

constants for the default icons used by KeePass password safe implementations. there are... so many. and we're listing every single one, no skips, main character energy only πŸŽ€:

  • ICON_PASSWORD
  • ICON_PACKAGE_NETWORK
  • ICON_MESSAGEBOX_WARNING
  • ICON_SERVER
  • ICON_KLIPPER
  • ICON_EDU_LANGUAGES
  • ICON_KCMDF
  • ICON_KATE
  • ICON_SOCKET
  • ICON_IDENTITY
  • ICON_KONTACT
  • ICON_CAMERA
  • ICON_IRKICKFLASH
  • ICON_KGPG_KEY3
  • ICON_LAPTOP_POWER
  • ICON_SCANNER
  • ICON_MOZILLA_FIREBIRD
  • ICON_CDROM_UNMOUNT
  • ICON_DISPLAY
  • ICON_MAIL_GENERIC
  • ICON_MISC
  • ICON_KORGANIZER
  • ICON_ASCII
  • ICON_ICONS
  • ICON_CONNECT_ESTABLISHED
  • ICON_FOLDER_MAIL
  • ICON_FILESAVE
  • ICON_NFS_UNMOUNT
  • ICON_MESSAGE
  • ICON_KGPG_TERM
  • ICON_KONSOLE
  • ICON_FILEPRINT
  • ICON_FSVIEW
  • ICON_RUN
  • ICON_CONFIGURE
  • ICON_KRFB
  • ICON_ARK
  • ICON_KPERCENTAGE
  • ICON_SAMBA_UNMOUNT
  • ICON_HISTORY
  • ICON_MAIL_FIND
  • ICON_VECTORGFX
  • ICON_KCMMEMORY
  • ICON_TRASHCAN_FULL
  • ICON_KNOTES
  • ICON_CANCEL
  • ICON_HELP
  • ICON_KPACKAGE
  • ICON_FOLDER
  • ICON_FOLDER_BLUE_OPEN
  • ICON_FOLDER_TAR
  • ICON_DECRYPTED
  • ICON_ENCRYPTED
  • ICON_APPLY
  • ICON_SIGNATURE
  • ICON_THUMBNAIL
  • ICON_KADDRESSBOOK
  • ICON_VIEW_TEXT
  • ICON_KGPG
  • ICON_PACKAGE_DEVELOPMENT
  • ICON_KFM_HOME
  • ICON_SERVICES
  • ICON_TUX
  • ICON_FEATHER
  • ICON_APPLE
  • ICON_W
  • ICON_MONEY
  • ICON_CERTIFICATE
  • ICON_SMARTPHONE

:bool

the booleans, the originals, the icons themselves πŸ’€:

  • FALSE
  • TRUE

:time

time constants, obviously:

  • TIME_SECONDS_AD1_TO_UNIX_EPOCH

:yubikey

constants for working with YubiKeys. hardware key girlies, this one's for you πŸ”₯:

  • YUBICO_VID
  • YUBIKEY_PID
  • NEO_OTP_PID
  • NEO_OTP_CCID_PID
  • NEO_CCID_PID
  • NEO_U2F_PID
  • NEO_OTP_U2F_PID
  • NEO_U2F_CCID_PID
  • NEO_OTP_U2F_CCID_PID
  • YK4_OTP_PID
  • YK4_U2F_PID
  • YK4_OTP_U2F_PID
  • YK4_CCID_PID
  • YK4_OTP_CCID_PID
  • YK4_U2F_CCID_PID
  • YK4_OTP_U2F_CCID_PID
  • PLUS_U2F_OTP_PID
  • ONLYKEY_VID
  • ONLYKEY_PID
  • YK_EUSBERR
  • YK_EWRONGSIZ
  • YK_EWRITEERR
  • YK_ETIMEOUT
  • YK_ENOKEY
  • YK_EFIRMWARE
  • YK_ENOMEM
  • YK_ENOSTATUS
  • YK_ENOTYETIMPL
  • YK_ECHECKSUM
  • YK_EWOULDBLOCK
  • YK_EINVALIDCMD
  • YK_EMORETHANONE
  • YK_ENODATA
  • CONFIG1_VALID
  • CONFIG2_VALID
  • CONFIG1_TOUCH
  • CONFIG2_TOUCH
  • CONFIG_LED_INV
  • CONFIG_STATUS_MASK

😭 BUGS 😭

found a bug? want a feature? bestie, please report it on the bugtracker website at <https://github.com/chazmcgarvey/File-KDBX/issues> 🫢

and when you submit a bug or a request, please include a test-file β€” or a patch to an existing test-file β€” that illustrates the bug or the desired feature. that's it. that's the ask. it helps so much, fr fr. ✨


πŸ’… AUTHOR πŸ’…

Charles McGarvey <ccm@cpan.org>


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.


okay that's the whole page and yes you read all of it, proud of you πŸ₯Ή this was File::...nstants(3pm) from the User Contributed Perl Documentation, and it's perl v5.40.1, dated 2025-05-04. go forth and import your constants, bestie πŸ’œπŸ¦‹πŸŒΈ

πŸ“¦ where this page comes from