Skip to content

Commit

Permalink
Merge pull request openshift#2590 from joelsmith/fixsso
Browse files Browse the repository at this point in the history
Fix faux-HTTP client of SSO SSH endpoint to send \r\n as per spec
  • Loading branch information
joelsmith authored Jun 6, 2017
2 parents 609c3ca + 700b59d commit 1c7e149
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion scripts/iam-tools/saml_aws_creds.py
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ def get_temp_credentials(metadata_id, idp_host, ssh_args=None):
# through an HTTPS session to idp_host:443.
ssh_cmd = ['ssh', '-p', '2222', '-a', '-l', 'user', '-o',
r'''ProxyCommand=bash -c "exec openssl s_client -servername %h -connect %h:443 -quiet 2>/dev/null \
< <(echo -e 'CONNECT 127.0.0.1:%p HTTP/1.1\nHost: %h:443\n'; cat -)"''']
< <(echo -en 'CONNECT 127.0.0.1:%p HTTP/1.1\r\nHost: %h:443\r\n\r\n'; cat -)"''']
if ssh_args:
ssh_cmd.extend(ssh_args)
ssh_cmd.extend([idp_host, metadata_id])
Expand Down

0 comments on commit 1c7e149

Please sign in to comment.