Cert authenticated flatpak#55
Merged
Merged
Conversation
sjha4
commented
Jul 3, 2025
3b26cf9 to
f9eab13
Compare
f9eab13 to
e62a0af
Compare
ianballou
reviewed
Jul 16, 2025
Member
ianballou
left a comment
There was a problem hiding this comment.
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) |
Member
There was a problem hiding this comment.
Might be good to add some error checking for the ForemanApi call.
Suggested change
| 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 |
| 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"]) } |
Member
There was a problem hiding this comment.
Could check if there is a Results section and throw an error otherwise.
e62a0af to
438a562
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
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.