@li0ard/cpfx - v0.1.2
    Preparing search index...

    @li0ard/cpfx - v0.1.2

    @li0ard/cpfx
    Декодер PFX и ключевого контейнера КриптоПро
    docs




    # из NPM
    npm i @li0ard/cpfx

    # из JSR
    bunx jsr i @li0ard/cpfx
    import { proceedPFX } from "@li0ard/cpfx";

    const file = await Bun.file("/path/to.pfx").bytes();
    const result = await proceedPFX(file, "password");

    console.log(result.pem);
    import { proceedCryptoProContainer } from "@li0ard/cpfx";

    const headerKey = await Bun.file("/path/to/header.key").bytes();
    const masksKey = await Bun.file("/path/to/masks.key").bytes();
    const primaryKey = await Bun.file("/path/to/primary.key").bytes();
    const result = await proceedCryptoProContainer(
    headerKey,
    masksKey,
    primaryKey,
    "password"
    );

    console.log(result.pem);
    import { changeContainerExportable } from "@li0ard/cpfx";

    const headerKey = Bun.file("/path/to/header.key");
    const newHeaderKey = changeContainerExportable(await file.bytes(), true); // Разрешить экспорт

    await headerKey.write(newHeaderKey);