From 4266ae7ce57c9ae42f2c3612bbed67448fdf119b Mon Sep 17 00:00:00 2001 From: Jake Moshenko Date: Mon, 23 May 2016 15:05:54 -0400 Subject: [PATCH] Fix the x5c header in our registry jwts. --- util/security/registry_jwt.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/util/security/registry_jwt.py b/util/security/registry_jwt.py index c12e49b43..bdf877dc8 100644 --- a/util/security/registry_jwt.py +++ b/util/security/registry_jwt.py @@ -67,7 +67,8 @@ def build_context_and_subject(user, token, oauthtoken): @lru_cache(maxsize=1) def _load_certificate_bytes(certificate_file_path): with open(certificate_file_path) as cert_file: - return ''.join(cert_file.readlines()[1:-1]).rstrip('\n') + cert_lines = cert_file.readlines()[1:-1] + return ''.join([cert_line.rstrip('\n') for cert_line in cert_lines]) @lru_cache(maxsize=1)