Skip to content

PGP keys aren't deleted when user is deleted #14531

Closed
@aveao

Description

@aveao
  • Gitea version (or commit ref): Tested on both 1.13.1 and gfcfbab99f
  • Git version: 2.17.1
  • Operating system: Debian 10

Gitea is from downloads, and is running as a systemd service.

Description

Current behavior

When a user deletes their account, their pgp key(s) in pgp_key_import table isn't deleted. As such, when the user registers again with the same email and tries to add the PGP key, it causes a unique constraint violation, and gitea throws a 500.

Expected behavior

  • Bugfix: When a user deletes their account, their PGP key(s) in pgp_key_import should be deleted too.
  • Nice to have in addition to bugfix: Trying to add non-unique PGP keys should probably display a better error page.

Screenshots

500 error

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions