Skip to content

Cannot add GPG signing sub-key #14009

@etanot

Description

@etanot
Type:

Bug report

Description

When I'm trying to add my GPG signing sub-key, Gitea shows me this error message:

This GPG key is not usable with any email address associated with your account.

Basically, I run gpg --armor --export <signing-sub-key-id>! (notice, I've added a ! at end of ID, to tell GPG to only export my master key and specific sub-key information, see this gnupg-users mailing list thread). I've no issue with adding my sub-key this way to Github and Gitlab.

Steps to Reproduce

  • Run gpg --armor --export <signing-sub-key-id>! command.
  • Copy the output of the command (public key).
  • Go Settings -> SSH/GPG keys -> Manage GPG keys.
  • Click on Add key button in Manage GPG keys section.
  • Paste the copied public key.
  • Now, click on green Add key button.

Expected Output

Key should be added successfully.

Actual Output

Getting this error message, This GPG key is not usable with any email address associated with your account.

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