1
0
Fork 0
mirror of https://github.com/vanitasvitae/Smack.git synced 2024-12-22 18:48:00 +01:00

Merge pull request #196 from cl90/4.2

Bugfix in SOCKS5 authentication
This commit is contained in:
Florian Schmaus 2018-01-19 13:21:55 +01:00 committed by GitHub
commit 77c0865326
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -137,7 +137,7 @@ public class Socks5ProxySocketConnection implements ProxySocketConnection {
System.arraycopy(userBytes, 0, buf, index,
user.length());
index += user.length();
byte[] passwordBytes = user.getBytes(StringUtils.UTF8);
byte[] passwordBytes = passwd.getBytes(StringUtils.UTF8);
buf[index++] = (byte) (passwordBytes.length);
System.arraycopy(passwordBytes, 0, buf, index,
passwd.length());