-
-
Notifications
You must be signed in to change notification settings - Fork 1.8k
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
Support client certificates #11099
Support client certificates #11099
Conversation
This change adds support for configurations where the webserver requests a client certificate, e.g. via nginx configuration options ssl_client_certificate and ssl_verify_client. The client certificate handling is done via InteractiveKeyManager which prompts for a client certificate from a file or the devices keystore. This change is NOT about client certificate authentication to the nextcloud server instance. The regular authentication mechanisms will be used as soon as the communication on TLS level is established. The change addresses ticket nextcloud#603, while not being a generic solution IMO.
master-IT test failed: https://www.kaminsky.me/nc-dev/android-integrationTests/6889-IT-master-23-14 |
stable-IT test failed: https://www.kaminsky.me/nc-dev/android-integrationTests/6889-IT-stable-23-16 |
Library PR for reference: nextcloud/android-library#1005 Hello @stephanritscher and thank you for your interest! I don't disagree with this feature in itself, but I'm not sure I am okay with the approach taken. Specifically, my concerns are:
My initial assesment is in a nutshell, that I don't think this is a bad idea, but this is not a way of implementing it that I would approve. |
Not an expert on the topic but I think the talk Android app has support for client-certificates so I think it is worth checking how it is implemented there and I would always root for a single approach used throughout the different clients for maintenance / knowledge reasons. |
Hi @AlvaroBrey, thanks for your comments - which I can understand in a way, but I have a slightly different way of looking at this. My design intention for InteractiveKeyManager was a library which is easy to integrate into any app not supporting client certificates (I previously did this for dav5x which now supports client certificates as well as Munin-for-Android and monitclient) and easy to maintain the integration as patch. This boils down to maintaining certificate state in the library to reduce the API interface and to having a separate UI (which is not conform with the rest of the app). So the main points of your reasoning were decided on deliberately, but from different perspective (which I still consider valid). My general assumption was to consider my work as private but publish it in case others find it useful (and rebasing/rebuiling the APK once or twice a year didn't hurt me). The PR the was requested of @Torqu3Wr3nch (which shows I wasn't quite wrong that this could be relevant). Now basically you and @AndyScherzinger request a redevelopment of the feature, which is fine, and maybe I would judge the same in your position. I anticipated parts of it so I hesitated to create the PR until it was requested by a third party. Unfortunately I moved to Syncthing for (private) file sharing and Radicale3 as CardDAV/CalDAV server so I won't invest major efforts here. Feel free to reuse code of mine, and yes, I agree with the discussion in #603 that this is an important feature (and I don't understand that only one of the nextcloud apps seems to support it). I wish you all the best, |
Hey @stephanritscher, the general consensus internally is aligned with my original message, so I'll close this. Many thanks for your interest and goodwill, however. Cheers! |
This change adds support for configurations where the webserver requests a client certificate, e.g. via nginx configuration options ssl_client_certificate and ssl_verify_client.
The client certificate handling is done via InteractiveKeyManager which prompts for a client certificate from a file or the devices keystore.
This change is NOT about client certificate authentication to the nextcloud server instance. The regular authentication mechanisms will be used as soon as the communication on TLS level is established.
The change addresses ticket #603, while not being a generic solution IMO.