use of com.jsql.model.InjectionModel in project jsql-injection by ron190.
the class MysqlNormalHeaderTestSuite method initialize.
@BeforeClass
public static void initialize() throws Exception {
InjectionModel model = new InjectionModel();
MediatorModel.register(model);
model.displayVersion();
MediatorModel.model().addObserver(new SystemOutTerminal());
PreferencesUtil.setNotTestingConnection(true);
ParameterUtil.initQueryString("http://" + AbstractTestSuite.HOSTNAME + "/simulate_header.php");
ParameterUtil.initRequest("");
ParameterUtil.initHeader("lib: 0");
ConnectionUtil.setMethodInjection(MethodInjection.HEADER);
ConnectionUtil.setTypeRequest("POST");
MediatorModel.model().beginInjection();
MediatorModel.model().setStrategy(StrategyInjection.NORMAL);
}
use of com.jsql.model.InjectionModel in project jsql-injection by ron190.
the class MysqlTimeHeaderTestSuite method initialize.
@BeforeClass
public static void initialize() throws Exception {
InjectionModel model = new InjectionModel();
MediatorModel.register(model);
model.displayVersion();
MediatorModel.model().addObserver(new SystemOutTerminal());
PreferencesUtil.setNotTestingConnection(true);
ParameterUtil.initQueryString("http://" + AbstractTestSuite.HOSTNAME + "/simulate_header.php");
ParameterUtil.initRequest("");
ParameterUtil.initHeader("lib: 1*");
ConnectionUtil.setMethodInjection(MethodInjection.HEADER);
ConnectionUtil.setTypeRequest("POST");
MediatorModel.model().beginInjection();
MediatorModel.model().setStrategy(StrategyInjection.TIME);
}
use of com.jsql.model.InjectionModel in project jsql-injection by ron190.
the class MainApplication method main.
/**
* Application starting point.
* @param args CLI parameters (not used)
* @throws URISyntaxException
*/
public static void main(String[] args) throws URISyntaxException {
// Configure global environnement settings
CertificateUtil.ignoreCertificationChain();
ExceptionUtil.setUncaughtExceptionHandler();
ProxyUtil.setProxy();
AuthenticationUtil.setKerberosCifs();
// Initialize MVC
InjectionModel model = new InjectionModel();
MediatorModel.register(model);
try {
JFrameView view = new JFrameView();
MediatorGui.register(view);
model.addObserver(view.getObserver());
} catch (HeadlessException e) {
LOGGER.error("HeadlessException, command line execution in jSQL not supported yet: " + e.getMessage(), e);
return;
} catch (AWTError e) {
// Fix #22668: Assistive Technology not found
LOGGER.error("Java Access Bridge missing or corrupt, check your access bridge definition in JDK_HOME/jre/lib/accessibility.properties: " + e.getMessage(), e);
return;
}
model.displayVersion();
// Check application status
if (!ProxyUtil.isChecked(ShowOnConsole.YES)) {
return;
}
if (PreferencesUtil.isCheckUpdateActivated()) {
GitUtil.checkUpdate(ShowOnConsole.NO);
}
I18n.checkCurrentLanguage();
GitUtil.showNews();
Dimension screenSize = Toolkit.getDefaultToolkit().getScreenSize();
int width = (int) screenSize.getWidth();
if (width >= 3840 && !PreferencesUtil.is4K()) {
LOGGER.warn("Your screen seems compatible with 4K resolution, please activate high-definition mode in Preferences");
}
}
use of com.jsql.model.InjectionModel in project jsql-injection by ron190.
the class OracleBlindGetTestSuite method initialize.
@BeforeClass
public static void initialize() throws InjectionFailureException {
InjectionModel model = new InjectionModel();
MediatorModel.register(model);
model.displayVersion();
MediatorModel.model().addObserver(new SystemOutTerminal());
ConnectionUtil.setUrlBase("http://" + AbstractTestSuite.HOSTNAME + "/oracle_simulate_get.php");
ParameterUtil.setQueryString(Arrays.asList(new SimpleEntry<String, String>("lib", "1")));
ConnectionUtil.setMethodInjection(MethodInjection.QUERY);
MediatorModel.model().beginInjection();
MediatorModel.model().setStrategy(StrategyInjection.BLIND);
}
use of com.jsql.model.InjectionModel in project jsql-injection by ron190.
the class SQLServerBlindGetTestSuite method initialize.
@BeforeClass
public static void initialize() throws InjectionFailureException {
InjectionModel model = new InjectionModel();
MediatorModel.register(model);
model.displayVersion();
MediatorModel.model().addObserver(new SystemOutTerminal());
ConnectionUtil.setUrlBase("http://" + AbstractTestSuite.HOSTNAME + "/sqlserver_simulate_get.php");
ParameterUtil.setQueryString(Arrays.asList(new SimpleEntry<String, String>("lib", "1")));
ConnectionUtil.setMethodInjection(MethodInjection.QUERY);
MediatorModel.model().beginInjection();
MediatorModel.model().setStrategy(StrategyInjection.BLIND);
}
Aggregations