Fod Uploader
Fod Uploader
FoDUploader
Fortify on Demand provides a build server integration (BSI) tool called FoDUploader to help you upload application code from a build
server. FoDUploader runs from the command-line on all major operating systems and thus can easily be integrated into a build script.
• Sending files to Fortify on Demand without size limitations aside from those specified in Static Assessment File Requirements
• Transmitting files securely from a client workstation to Fortify on Demand
• Transmitting through a proxy, if required
• API key pair or PAT authentication
Downloading FoDUploader
FoDUploader is available as a Java application named FoDUpload.jar. FoDUpload.jar and its source code is hosted at https://
github.com/fod-dev/fod-uploader-java.
Running FoDUploader
Prerequisite: Java 8 or later must be installed.
To run FoDUploader:
In a command-line interface, run FodUpload.jar with the appropriate arguments. You can also insert the command in your build script to
integrate with your build server. The basix syntax is:
java -jar FoDUpload.jar -z "<zip_file_path>" {-ac <key> <secret>|-uc <username> <password>} {-rid
<relID>|-bsi <token>} -purl <purl> -aurl <aurl> -tc <tcode> -ep {1|SingleScanOnly|2|SubscriptionOnly|
3|SingleScanFirstThenSubscription|4|SubscriptionFirstThenSingleScan}
If the command is properly executed, the command-line displays the bytes sent and the upload status. Otherwise, the command-line
displays an error message indicating the part of the command that is incorrect.
FoDUploader Arguments
The following table describes the FoDUploader arguments. Arguments can be specified in any order.
Note: Flag arguments are false by default. Include a flag to set it to true—you do not need to specify true or false.
Note: Arguments are for version 5.4.1. Details on the latest release is available at https://github.com/fod-dev/fod-uploader-java.
1 of 4 21/10/2024, 9:32 AM
FoDUploader https://emea.fortify.com/Docs/en/Content/Tools/FoDUploader/BSI_Abo...
-zipLocation -z Yes Location of the zip file. Enclose the path with quotation marks to
escape special characters.
If multiple entitlements are available, the scan will use the oldest
entitlement. If the release has an active subscription, the scan will use
the active subscription.
-userCredentials -uc Yes1 Your user credentials. Enclose the username and password separately
with quotation marks to escape special characters.
-releaseId -rid Yes2 Release ID. The release must have saved scan settings in the portal for
the release ID to be used as a token.
-technologyStackId -ts Yes 4 Technology stack as an integer: 32 (Auto Detect) 1 (.NET), 23 (.Net
Core), 2 (ABAP), 21 (Apex/Visualforce), 3 (ASP), 5 (CFML), 6
(COBOL), 29 (Dart/Futter) 22 (Go), 27 (Infrastructure-As-Code/
Dockerfile), 7 (JAVA/J2EE/Kotlin), 16 (JS/TS/HTML), 18 (MBS/C/C++/
Scala), 9 (PHP), 10 (PYTHON), 28 (React Native), 17 (Ruby), 12
(Swift/Objective C/C++), 11 (VB6), 14 (VBScript)
-isBinaryScan -bs No4 Scan compiled and source code (the feature must be enabled).
2 of 4 21/10/2024, 9:32 AM
FoDUploader https://emea.fortify.com/Docs/en/Content/Tools/FoDUploader/BSI_Abo...
-inProgressScanActionType -pp No If an in-progress scan exists, the action to take for the new scan: 0/
DoNotStartScan (default), 1/CancelScanInProgress, 2/Queue
-pollingInterval -I No Length of time in minutes between polling Fortify on Demand for the
scan status. Polling stops once a scan is canceled, completed, or
paused. If the polling interval is not set or set to 0, no polling is done.
Exit codes:
-allowPolicyFail -apf No Return exit(0) instead of exit(1) if the scan fails the security policy
specified in Fortify on Demand
2 Use either release ID or BSI token. If both are provided, then the scan settings that are retrieved from the release ID will be used.
4 Required if neither release ID nor BSI token is provided. Provided values override existing release ID or BSI token settings.
3 of 4 21/10/2024, 9:32 AM
FoDUploader https://emea.fortify.com/Docs/en/Content/Tools/FoDUploader/BSI_Abo...
Examples
Command-line examples:
Usage notes:
• If java.exe is in the directory from which the command is run or if the java.exe directory is included in the file system path, simply
reference java as the path.
• If the java.exe is not in the path, the full path is required (for example, C:\Program Files (x86)\Java\jre-9\bin\java.exe).
The -jar operator informs java.exe that it is working with a JAR file for the rest of the command set.
• If FodUpload.jar is in the directory from which the command is being run, simply reference FoDUpload.jar as the path.
• If FodUpload.jar is in a different directory, the full path is required (for example, C:\fod_upload\fodupload.jar).
4 of 4 21/10/2024, 9:32 AM