Package 'rkeepass'

Title: Read KeePass Database Files
Description: Read entries from KeePass '.kdbx' database files (versions 3.x and 4.x) using the 'keepass-rs' Rust library. Supports password and keyfile authentication.
Authors: David Schoch [aut, cre] (ORCID: <https://orcid.org/0000-0003-2952-4812>)
Maintainer: David Schoch <[email protected]>
License: MIT + file LICENSE
Version: 0.1.0
Built: 2026-09-23 12:13:47 UTC
Source: https://github.com/schochastics/rkeepass

Help Index


Read a KeePass Database File

Description

Reads entries from a KeePass .kdbx database file (versions 3.x and 4.x).

Usage

kdbx_read(path, password = NULL, keyfile = NULL)

Arguments

path

Character scalar. Path to the .kdbx file.

password

Character scalar or NULL. The database master password.

keyfile

Character scalar or NULL. Path to a key file.

Details

At least one of password or keyfile must be provided. The function auto-detects the KDBX version (3.x or 4.x). Protected fields (like passwords) are automatically decrypted. Fields that are empty or not set in the database are returned as NA.

Value

A data.frame of class kdbx_entries with one row per entry and columns:

uuid

Character. The unique identifier of the entry.

group_path

Character. The slash-separated path of the group containing this entry (e.g., "Root/Internet"). The first component is the name of the database's root group, which is "Root" by default but can be renamed in KeePass.

title

Character. The entry title.

username

Character. The username field.

password

Character. The password field (decrypted).

url

Character. The URL field.

notes

Character. The notes field.

Passwords are masked when the result is printed (see print.kdbx_entries()) but are stored in plain text in the password column.

Examples

path <- system.file("extdata", "example.kdbx", package = "rkeepass")
db <- kdbx_read(path, password = "test123")
db[db$group_path == "Root/Internet", ]

Print KeePass entries

Description

Prints the entries returned by kdbx_read() with the password column masked, so that passwords do not end up in the console or in logs.

Usage

## S3 method for class 'kdbx_entries'
print(x, ..., reveal = FALSE)

Arguments

x

A kdbx_entries object.

...

Passed on to print.data.frame().

reveal

Logical. If TRUE, passwords are printed in plain text.

Value

x, invisibly.

Examples

path <- system.file("extdata", "example.kdbx", package = "rkeepass")
db <- kdbx_read(path, password = "test123")
db
print(db, reveal = TRUE)