mirror of
https://github.com/moparisthebest/SSLDroid
synced 2024-11-30 04:42:17 -05:00
Make sure the server socket only listens on localhost
Signed-off-by: Balint Kovacs <blint@blint.hu>
This commit is contained in:
parent
f83d37f2ca
commit
e33cf5dc17
@ -1,6 +1,7 @@
|
|||||||
package hu.blint.ssldroid;
|
package hu.blint.ssldroid;
|
||||||
|
|
||||||
import java.io.IOException;
|
import java.io.IOException;
|
||||||
|
import java.net.InetAddress;
|
||||||
import java.net.ServerSocket;
|
import java.net.ServerSocket;
|
||||||
|
|
||||||
import android.util.Log;
|
import android.util.Log;
|
||||||
@ -27,7 +28,7 @@ public class TcpProxy {
|
|||||||
|
|
||||||
public void serve() throws IOException {
|
public void serve() throws IOException {
|
||||||
try {
|
try {
|
||||||
ss = new ServerSocket(listenPort);
|
ss = new ServerSocket(listenPort, 50, InetAddress.getLocalHost());
|
||||||
Log.d("SSLDroid", "Listening for connections on port "
|
Log.d("SSLDroid", "Listening for connections on port "
|
||||||
+ this.listenPort + " ...");
|
+ this.listenPort + " ...");
|
||||||
} catch (Exception e) {
|
} catch (Exception e) {
|
||||||
|
Loading…
Reference in New Issue
Block a user