use of com.checkmarx.sdk.dto.RemoteRepositoryInfo in project checkmarx-spring-boot-java-sdk by checkmarx-ltd.
the class ScaTest method initScaConfig.
protected RestClientConfig initScaConfig(String repoUrlProp, boolean useOnPremAuthentication) throws MalformedURLException {
RestClientConfig config = initScaConfig(useOnPremAuthentication);
config.getScaConfig().setSourceLocationType(SourceLocationType.REMOTE_REPOSITORY);
RemoteRepositoryInfo repoInfo = new RemoteRepositoryInfo();
URL repoUrl = new URL(repoUrlProp);
repoInfo.setUrl(repoUrl);
repoInfo.setUsername(githubProperties.getToken());
config.getScaConfig().setRemoteRepositoryInfo(repoInfo);
return config;
}
use of com.checkmarx.sdk.dto.RemoteRepositoryInfo in project cx-flow by checkmarx-ltd.
the class ScaCommonSteps method createRestClientConfig.
protected RestClientConfig createRestClientConfig(ScaProperties scaProperties, String projectName) {
ScaConfig scaConfig = new ScaConfig();
scaConfig.setTenant(scaProperties.getTenant());
scaConfig.setApiUrl(scaProperties.getApiUrl());
scaConfig.setUsername(scaProperties.getUsername());
scaConfig.setPassword(scaProperties.getPassword());
scaConfig.setAccessControlUrl(scaProperties.getAccessControlUrl());
scaConfig.setRemoteRepositoryInfo(new RemoteRepositoryInfo());
RestClientConfig restClientConfig = new RestClientConfig();
restClientConfig.setScaConfig(scaConfig);
restClientConfig.setProjectName(projectName);
return restClientConfig;
}
use of com.checkmarx.sdk.dto.RemoteRepositoryInfo in project checkmarx-spring-boot-java-sdk by checkmarx-ltd.
the class AstTest method getScanConfig.
private RestClientConfig getScanConfig() throws MalformedURLException {
AstConfig astConfig = AstConfig.builder().apiUrl(astProperties.getApiUrl()).webAppUrl(astProperties.getWebAppUrl()).clientSecret(astProperties.getClientSecret()).clientId("CxFlow").sourceLocationType(SourceLocationType.REMOTE_REPOSITORY).build();
RemoteRepositoryInfo repoInfo = new RemoteRepositoryInfo();
URL repoUrl = new URL(githubProperties.getUrl());
repoInfo.setUrl(repoUrl);
astConfig.setRemoteRepositoryInfo(repoInfo);
astConfig.setResultsPageSize(10);
astConfig.setPresetName("Checkmarx Default");
RestClientConfig config = new RestClientConfig();
config.setAstConfig(astConfig);
config.setProjectName("sdkAstProject");
config.setProgressInterval(5);
return config;
}
Aggregations