Skip to content
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

fix error in module iam_server_certificate for _compare_cert #2104

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
fix error in module iam_server_certificate for _compare_cert
  • Loading branch information
andrewjroth committed Jun 14, 2024
commit ef0f0ce4d862cee8a30d1be3a2871ad3fb02c361
8 changes: 2 additions & 6 deletions plugins/modules/iam_server_certificate.py
Original file line number Diff line number Diff line change
@@ -137,12 +137,8 @@ def _compare_cert(cert_a, cert_b):
# Trim out the whitespace before comparing the certs. While this could mean
# an invalid cert 'matches' a valid cert, that's better than some stray
# whitespace breaking things
cert_a.replace("\r", "")
cert_a.replace("\n", "")
cert_a.replace(" ", "")
cert_b.replace("\r", "")
cert_b.replace("\n", "")
cert_b.replace(" ", "")
cert_a = cert_a.replace("\r", "").replace("\n", "").replace(" ", "")
cert_b = cert_b.replace("\r", "").replace("\n", "").replace(" ", "")

return cert_a == cert_b