pterodactyl / panel

Pterodactyl® is a free, open-source game server management panel built with PHP, React, and Go. Designed with security in mind, Pterodactyl runs all game servers in isolated Docker containers while exposing a beautiful and intuitive UI to end users.
https://pterodactyl.io
Other
6.58k stars 1.64k forks source link

Application API - Not showing API keys created by other admins #5175

Open JustinPooters opened 1 month ago

JustinPooters commented 1 month ago

Current Behavior

When I create an Application API key from the Admin dashboard, other admin's can't see the keys I made (and I can't see theirs). I've also confirmed this on another server. Same issue.

Expected Behavior

I'd expect on the application api page every admin sees all API keys.

Steps to Reproduce

Create an Application API key. Login with another user It's not there.

Panel Version

1.11.7

Wings Version

1.11.13

Games and/or Eggs Affected

None

Docker Image

None

Error Logs

Not relevant.

Is there an existing issue for this?

MackenzieMolloy commented 1 month ago

I believe this is intentional however I agree that all Application API keys should be visible to all Admins since it does pose the potential for malicious users to generate keys without other panel admins noticing.

In the meantime, you can view the api_keys table to see all API Keys - this table does also include normal User API Keys.

JustinPooters commented 1 month ago

That was exactly my worry. We use Pterodactyl for our game servers. If we dismiss someone who had admin rights and they still have an active API key, it could be exploited for malicious purposes.

MackenzieMolloy commented 1 month ago

I'll make a PR later today to adjust this behaviour for you.

I'm not sure if the Pterodactyl team will merge it as, like I said, I think the current functionality is intentional.

If you don't know how to build the source files, feel free to reach out to me on Discord ('wackenzie' is my tag).

Happy to help.