-
Notifications
You must be signed in to change notification settings - Fork 22
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
chore: Squash-merge develop branch into main
fix: `fcli ssc appversion create`: Command will now fail instead of creating uncommitted application version if the application version specified on `--copy-from` option does not exist fix: FoD: Update `wait-for` commands to use internal API (closes #526, #500) feat: Add `fcli config public-key` commands for managing trusted public keys feat: Add `fcli fod issue list` command feat: Add `fcli ssc issue list` command feat: Add `fcli ssc action` commands for running a variety of yaml-based actions feat: Add `fcli fod action` commands for running a variety of yaml-based actions feat: Migrate FortifyVulnerabilityExporter functionality to yaml-based fcli actions feat: Add actions for generating BitBucket, GitHub, GitLab, SARIF and SonarQube vulnerability reports feat: Add actions for generating application version/release summary feat: Add preview actions for generating GitHub Pull Request comments feat: Add sample actions for checking security policy criteria
- Loading branch information
Showing
417 changed files
with
14,626 additions
and
1,459 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1,36 @@ | ||
apply from: "${sharedGradleScriptsDir}/fcli-java.gradle" | ||
task zipResources_templates(type: Zip) { | ||
destinationDirectory = file("${buildDir}/generated-zip-resources/com/fortify/cli/common") | ||
archiveFileName = "actions.zip" | ||
from("${projectDir}/src/main/resources//com/fortify/cli/common/actions/zip") { | ||
// TODO We should also sign file; how do we invoke a sign operation from Gradle? | ||
filter(line->project.version.startsWith('0.') | ||
? line | ||
: line.replaceAll("https://fortify.github.io/fcli/schemas/action/fcli-action-schema-dev.json", "https://fortify.github.io/fcli/schemas/action/fcli-action-schema-${fcliActionSchemaVersion}.json")) | ||
} | ||
} | ||
|
||
apply from: "${sharedGradleScriptsDir}/fcli-java.gradle" | ||
|
||
// Generate build properties and associated resource-config.json file | ||
ext.buildPropertiesDir = "${buildDir}/generated-build-properties" | ||
task generateFcliBuildProperties { | ||
doLast { | ||
def outputDir = "${buildPropertiesDir}/com/fortify/cli/common" | ||
mkdir "${outputDir}" | ||
ant.propertyfile(file: "${outputDir}/fcli-build.properties") { | ||
entry(key: "projectName", value: "fcli") | ||
entry(key: "projectVersion", value: project.version) | ||
entry(key: "buildDate", value: buildTime.format('yyyy-MM-dd HH:mm:ss')) | ||
entry(key: "actionSchemaVersion", value: fcliActionSchemaVersion) | ||
} | ||
def resourceConfigOutputDir = "${buildPropertiesDir}/META-INF/native-image/fcli-build-properties" | ||
mkdir "${resourceConfigOutputDir}" | ||
def contents = | ||
'{"resources":[\n' + | ||
' {"pattern":"com/fortify/cli/common/fcli-build.properties"}\n' + | ||
']}\n' | ||
file("${resourceConfigOutputDir}/resource-config.json").text = contents; | ||
println contents | ||
} | ||
} | ||
sourceSets.main.output.dir buildPropertiesDir, builtBy: generateFcliBuildProperties |
32 changes: 32 additions & 0 deletions
32
...-common/src/main/java/com/fortify/cli/common/action/cli/cmd/AbstractActionGetCommand.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
/******************************************************************************* | ||
* Copyright 2021, 2023 Open Text. | ||
* | ||
* The only warranties for products and services of Open Text | ||
* and its affiliates and licensors ("Open Text") are as may | ||
* be set forth in the express warranty statements accompanying | ||
* such products and services. Nothing herein should be construed | ||
* as constituting an additional warranty. Open Text shall not be | ||
* liable for technical or editorial errors or omissions contained | ||
* herein. The information contained herein is subject to change | ||
* without notice. | ||
*******************************************************************************/ | ||
package com.fortify.cli.common.action.cli.cmd; | ||
|
||
import com.fortify.cli.common.action.cli.mixin.ActionResolverMixin; | ||
import com.fortify.cli.common.action.helper.ActionLoaderHelper.ActionValidationHandler; | ||
import com.fortify.cli.common.cli.cmd.AbstractRunnableCommand; | ||
|
||
import picocli.CommandLine.Mixin; | ||
|
||
public abstract class AbstractActionGetCommand extends AbstractRunnableCommand { | ||
@Mixin private ActionResolverMixin.RequiredParameter actionResolver; | ||
|
||
@Override | ||
public final Integer call() { | ||
initMixins(); | ||
System.out.println(actionResolver.loadActionContents(getType(), ActionValidationHandler.WARN)); | ||
return 0; | ||
} | ||
|
||
protected abstract String getType(); | ||
} |
Oops, something went wrong.