Skip to content

warning when trying to load empty string as public key #2079

@simonLeary42

Description

@simonLeary42

loadXML documents that it will send a warning if it tries to read an empty string. This came up when I was writing unit tests for garbage public keys, because phpunit is configured to convert warnings to errors.

ValueError: DOMDocument::loadXML(): Argument #1 ($source) must not be empty
.../phpseclib/Crypt/EC/Formats/Keys/XML.php:142
.../phpseclib/Crypt/EC/Formats/Keys/XML.php:77
.../phpseclib/Crypt/Common/AsymmetricKey.php:145
.../phpseclib/Crypt/PublicKeyLoader.php:40

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions