MCPcopy Index your code
hub / github.com/cSploit/android / setForwarding

Method setForwarding

cSploit/src/org/csploit/android/core/System.java:1176–1188  ·  view source on GitHub ↗
(boolean enabled)

Source from the content-addressed store, hash-verified

1174 }
1175
1176 public static void setForwarding(boolean enabled){
1177 Logger.debug("Setting ipv4 forwarding to " + enabled);
1178
1179 String status = (enabled ? "1" : "0"),
1180 cmd = "echo " + status + " > " + IPV4_FORWARD_FILEPATH;
1181
1182 try{
1183 getTools().shell.run(cmd);
1184 }
1185 catch(Exception e){
1186 Logger.error(e.getMessage());
1187 }
1188 }
1189
1190 public static void clean(boolean releaseLocks){
1191 setForwarding(false);

Callers 4

cleanMethod · 0.95
startMethod · 0.95
stopMethod · 0.95
onStartMethod · 0.95

Calls 4

debugMethod · 0.95
getToolsMethod · 0.95
errorMethod · 0.95
runMethod · 0.45

Tested by

no test coverage detected