Skip to content
This repository has been archived by the owner on Apr 26, 2024. It is now read-only.

Commit

Permalink
Revert "Add test case to detect dodgy b64 encoding"
Browse files Browse the repository at this point in the history
This reverts commit 5fe76b9.

I think I had this accidentally commited on my local develop branch, and
so it accidentally got merged into upstream develop.

This should re-land with corrections in #16504.
  • Loading branch information
David Robertson committed Oct 24, 2023
1 parent 2f35424 commit 2f1065f
Showing 1 changed file with 0 additions and 14 deletions.
14 changes: 0 additions & 14 deletions tests/http/test_proxyagent.py
Original file line number Diff line number Diff line change
Expand Up @@ -217,20 +217,6 @@ def test_parse_proxy(
)


class TestBasicProxyCredentials(TestCase):
def test_long_user_pass_string_encoded_without_newlines(self) -> None:
"""Reproduces https://github.com/matrix-org/synapse/pull/16504."""
creds = BasicProxyCredentials(
b"looooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooonguser:[email protected]:9988"
)
auth_value = creds.as_proxy_authorization_value()
self.assertNotIn(b"\n", auth_value)
self.assertEqual(
creds.as_proxy_authorization_value(),
b"Basic: bG9vb29vb29vb29vb29vb29vb29vb29vb29vb29vb29vb29vb29vb29vb29vb29vb29vb29vb29vb29vb29vb29vb29vb29vbmd1c2VyOnBhc3M=",
)


class MatrixFederationAgentTests(TestCase):
def setUp(self) -> None:
self.reactor = ThreadedMemoryReactorClock()
Expand Down

0 comments on commit 2f1065f

Please sign in to comment.