-
-
Notifications
You must be signed in to change notification settings - Fork 5.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Disable SSH key deletion of externally managed Keys #13985
Disable SSH key deletion of externally managed Keys #13985
Conversation
When a user has a login source which has SSH key management key addition and deletion using the UI should be disabled. Fix go-gitea#13983 Signed-off-by: Andrew Thornton <art27@cantab.net>
5ed49e9
to
4ca803f
Compare
Is it breaking? What happens to existing gitea-local keys that were previously added? Do they become unremovable? |
Oh crap I've just realised that I missed something - the keys do actually have a login_source. |
Codecov Report
@@ Coverage Diff @@
## master #13985 +/- ##
==========================================
- Coverage 42.37% 42.24% -0.14%
==========================================
Files 726 726
Lines 77839 77908 +69
==========================================
- Hits 32982 32909 -73
- Misses 39447 39579 +132
- Partials 5410 5420 +10
Continue to review full report at Codecov.
|
Signed-off-by: Andrew Thornton <art27@cantab.net>
Lets try again - this time the buttons are disabled if the key is an externally managed key |
LGTM (not tested). I think for our goal we'll just drop all buttons and replace with a single button to direct users to the LDAP user management external url, which would still require a custom template, but it's good that there's no risk of some commandline tool removing externally managed keys |
🚀 |
When a user has a login source which has SSH key management
deletion of keys from that source using the UI should be disabled.
Fix #13983
Signed-off-by: Andrew Thornton art27@cantab.net