-
Notifications
You must be signed in to change notification settings - Fork 88
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
endless loop when root certificate is found in intermediate certificates set #355
Comments
I do see two easy ways of fixing this, but I would like @felixfontein input: Is a root certificate really it's own parent? |
@JensHeinrich I guess it is and it is not :-) In any case, I would not fix it in that function, but instead add a generic loop detection, to avoid the same issue happening with cycles longer than one. Basically create a set of all certificates so far in the chain (the actual certificate + all intermediates), and if a new parent found is already in that set, stop with an error. |
Maybe just use a dedicated class and fail the append if it is already in there? |
resolved_by_pr #360 |
SUMMARY
When a root certificate is found inside the intermediate certificates set, it is it's own parent and therefor the loop never ends
ISSUE TYPE
COMPONENT NAME
plugins/modules/certificate_complete_chain.py
ANSIBLE VERSION
COLLECTION VERSION
CONFIGURATION
OS / ENVIRONMENT
STEPS TO REPRODUCE
EXPECTED RESULTS
Module to fail giving a
'Cannot complete chain. Stuck at certificate {0}'
messageACTUAL RESULTS
Not ending ansible task as the loop in line 315 of the file is never finished
The text was updated successfully, but these errors were encountered: