[Pkg-privacy-commits] [obfsproxy] 310/353: Only search for mark in expected space.
Ximin Luo
infinity0 at moszumanska.debian.org
Sat Aug 22 13:02:16 UTC 2015
This is an automated email from the git hooks/post-receive script.
infinity0 pushed a commit to branch master
in repository obfsproxy.
commit 7a374dd4446543339eee75421fbc1af73aa2c011
Author: Philipp Winter <phw at torproject.org>
Date: Mon Mar 3 23:10:51 2014 +0100
Only search for mark in expected space.
We know in which array slice the mark is expected. As a result, we don't have
to look any further than that. Patch by Yawning Angel. See the following
ticket for reference: <https://bugs.torproject.org/11092>.
---
obfsproxy/transports/scramblesuit/util.py | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/obfsproxy/transports/scramblesuit/util.py b/obfsproxy/transports/scramblesuit/util.py
index bbb6c6a..bb0557e 100644
--- a/obfsproxy/transports/scramblesuit/util.py
+++ b/obfsproxy/transports/scramblesuit/util.py
@@ -79,7 +79,7 @@ def locateMark( mark, payload ):
`mark' could not be found, `None' is returned.
"""
- index = payload.find(mark)
+ index = payload.find(mark, 0, const.MAX_PADDING_LENGTH + const.MARK_LENGTH)
if index < 0:
log.debug("Could not find the mark just yet.")
return None
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-privacy/packages/obfsproxy.git
More information about the Pkg-privacy-commits
mailing list