Skip to content

Public key parsing question #1349

Description

@peledins-zimperium

In scripts/update-public-key.sh

# Seach the file and make sure the first key id found is the expected key id.
FOUND_KEY_ID=$(gpg --with-colons --show-keys $PUBLIC_KEY_FILE | grep "^fpr" | head -n1 | cut -f10 -d":")
if [[ "$FOUND_KEY_ID" != "$PUBLIC_KEY_ID" ]]; then
    echo >&2 "Key id: ${FOUND_KEY_ID} from ${PUBLIC_KEY_FILE} did not match expected key id: ${PUBLIC_KEY_ID}"
    exit 1
fi

What if PUBLIC_KEY_FILE contains two keys: first one expected, second one unneeded? Possibly needs to count public keys in the file.

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