Use fast modular exponentiation for UniformDH
obfs3 currently uses Python's built-in
pow() for modular exponentiation. The computation can be made less expensive by using GMPY. Apart from making UniformDH computationally less expensive, it creates less of a timing signature. That's relevant for ScrambleSuit as its two authentication methods should be indistinguishable.
I have patches for this improvement in my user repository in the branch
Note that the patch requires the module
gmpy which is not part of Python's standard library. Debian knows the package as