-
Notifications
You must be signed in to change notification settings - Fork 8
Cert authenticated flatpak #55
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
Conversation
3b26cf9 to
f9eab13
Compare
f9eab13 to
e62a0af
Compare
ianballou
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Working well, just a couple of small comments!
| elsif valid_uuid | ||
| host = database.connection[:hosts][{ uuid: client_cert.uuid }] | ||
| if host.nil? | ||
| repo_response = ForemanApi.new.fetch_host_repositories(client_cert.uuid, request.params) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Might be good to add some error checking for the ForemanApi call.
| repo_response = ForemanApi.new.fetch_host_repositories(client_cert.uuid, request.params) | |
| repo_response = ForemanApi.new.fetch_host_repositories(client_cert.uuid, request.params) | |
| halt repo_response.code.to_i, repo_response.body unless repo_response.code.to_i == 200 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Updated.. 👍🏼
| end | ||
| catalog = container_gateway_main.host_catalog(client_cert.uuid).select_map(::Sequel[:repositories][:name]) | ||
| pulp_index = JSON.parse(pulp_response.body) | ||
| pulp_index["Results"].select! { |result| catalog.include?(result["Name"]) } |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Could check if there is a Results section and throw an error otherwise.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Updated.. 👍🏼
e62a0af to
438a562
Compare
ianballou
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks!
Test that cert clients can consume flatpaks from capsules correctly. This is applicable only to Rhel 10.1+ clients. On rhel9 clients, verify that placing the certs doesn't break the original flow of username/password authentication which is still required. Rhel 10.1+ clients can similarly use user auth for fetching content but they'll not have LCE support for their content.