use of org.csploit.android.plugins.PacketForger in project android by cSploit.
the class MainFragment method registerPlugins.
private void registerPlugins() {
if (!System.getPlugins().isEmpty())
return;
System.registerPlugin(new RouterPwn());
System.registerPlugin(new Traceroute());
System.registerPlugin(new PortScanner());
System.registerPlugin(new Inspector());
System.registerPlugin(new ExploitFinder());
System.registerPlugin(new LoginCracker());
System.registerPlugin(new Sessions());
System.registerPlugin(new MITM());
System.registerPlugin(new PacketForger());
}
use of org.csploit.android.plugins.PacketForger in project android by cSploit.
the class CSploitApplication method onCreate.
@Override
public void onCreate() {
SharedPreferences themePrefs = getSharedPreferences("THEME", 0);
Boolean isDark = themePrefs.getBoolean("isDark", false);
if (isDark)
setTheme(R.style.DarkTheme);
else
setTheme(R.style.AppTheme);
super.onCreate();
ACRA.init(this);
Services.init(this);
// initialize the system
try {
System.init(this);
} catch (Exception e) {
// ignore exception when the user has wifi off
if (!(e instanceof NoRouteToHostException))
System.errorLogging(e);
}
ACRA.setConfig(ACRA.getConfig().setApplicationLogFile(System.getCorePath() + "/cSploitd.log"));
// load system modules even if the initialization failed
System.registerPlugin(new RouterPwn());
System.registerPlugin(new Traceroute());
System.registerPlugin(new PortScanner());
System.registerPlugin(new Inspector());
System.registerPlugin(new ExploitFinder());
System.registerPlugin(new LoginCracker());
System.registerPlugin(new Sessions());
System.registerPlugin(new MITM());
System.registerPlugin(new PacketForger());
}
use of org.csploit.android.plugins.PacketForger in project android by cSploit.
the class MainActivity method onCreate.
@Override
public void onCreate(Bundle savedInstanceState) {
SharedPreferences themePrefs = getSharedPreferences("THEME", 0);
Boolean isDark = themePrefs.getBoolean("isDark", false);
boolean connectivityAvailable;
if (isDark)
setTheme(R.style.DarkTheme);
else
setTheme(R.style.AppTheme);
super.onCreate(savedInstanceState);
setContentView(R.layout.target_layout);
lv = (ListView) findViewById(R.id.android_list);
lv.setOnItemClickListener(new ListView.OnItemClickListener() {
@Override
public void onItemClick(AdapterView<?> parent, View view, int position, long id) {
if (mActionMode != null) {
((TargetAdapter) lv.getAdapter()).toggleSelection(position);
return;
}
Target target = (Target) mTargetAdapter.getItem(position);
System.setCurrentTarget(target);
new Thread(new Runnable() {
@Override
public void run() {
startActivityForResult(new Intent(MainActivity.this, ActionActivity.class), WIFI_CONNECTION_REQUEST);
overridePendingTransition(R.anim.fadeout, R.anim.fadein);
}
}).start();
Toast.makeText(MainActivity.this, getString(R.string.selected_) + System.getCurrentTarget(), Toast.LENGTH_SHORT).show();
}
});
isWifiAvailable = Network.isWifiConnected(this);
connectivityAvailable = isWifiAvailable || Network.isConnectivityAvailable(this);
// startup
if (!System.isInitialized()) {
// :(
if (isWifiAvailable) {
// retry
try {
System.init(MainActivity.this.getApplicationContext());
System.registerPlugin(new RouterPwn());
System.registerPlugin(new Traceroute());
System.registerPlugin(new PortScanner());
System.registerPlugin(new Inspector());
System.registerPlugin(new ExploitFinder());
System.registerPlugin(new LoginCracker());
System.registerPlugin(new Sessions());
System.registerPlugin(new MITM());
System.registerPlugin(new PacketForger());
} catch (Exception e) {
if (!(e instanceof NoRouteToHostException))
System.errorLogging(e);
onInitializationError(System.getLastError());
return;
}
}
} else {
System.reloadNetworkMapping();
}
boolean coreInstalled = System.isCoreInstalled();
boolean coreBeating = System.isCoreInitialized();
if (coreInstalled && !coreBeating) {
coreBeating = startCore();
if (coreBeating) {
onCoreBeating();
} else if (isRootMissing) {
return;
}
}
if (!connectivityAvailable) {
if (!coreInstalled) {
onInitializationError(getString(R.string.no_core_no_connectivity));
return;
} else if (!coreBeating) {
onInitializationError(getString(R.string.heart_attack));
return;
}
}
if (!coreInstalled) {
UPDATE_MESSAGE = getString(R.string.missing_core_update);
} else if (!coreBeating) {
UPDATE_MESSAGE = getString(R.string.heart_attack_update);
} else if (!isWifiAvailable) {
UPDATE_MESSAGE = getString(R.string.no_wifi_available);
}
if (connectivityAvailable)
startUpdateChecker();
if (coreBeating && isWifiAvailable)
startNetworkRadar();
createLayout();
}
Aggregations