> For the complete documentation index, see [llms.txt](https://knowledgebase.autorabit.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://knowledgebase.autorabit.com/product-guides/integral-zone/iz-suite/iz-scan/ci-cd-integration/using-maven.md).

# Using Maven

## CICD Integration - Using Maven

{% hint style="warning" %}
Before scanning applications using IZ Scan, make sure you have:

* Purchased a valid license for IZ Scan.
* Downloaded and installed **`Apache Maven`** 3.6.3 or higher. Refer to [Installing Apache Maven](https://maven.apache.org/)
* Downloaded and installed JDK 11
* Follow the instructions on [Generating Security Token](/product-guides/integral-zone/iz-suite/iz-scan/ci-cd-integration/generate-security-token.md) to generate a security token
  {% endhint %}

### Adding Repositories

1. The binaries required to scan the projects are available in **`IZ Maven Central`** repository. Include the following repositories and plugin repositories in settings.xml

```xml
&lt;repositories>
    &lt;repository>
        &lt;id>iz-maven-repo&lt;/id>
        &lt;name>IZ Maven Repo&lt;/name>
        &lt;url>https://iz-public-m2.s3.eu-west-2.amazonaws.com/releases&lt;/url>
    &lt;/repository>
&lt;/repositories>
```

```xml
&lt;pluginRepositories>
    &lt;pluginRepository>
        &lt;id>iz-maven-plugin-repo&lt;/id>
        &lt;url>https://iz-public-m2.s3.eu-west-2.amazonaws.com/releases&lt;/url>
    &lt;/pluginRepository>
&lt;/pluginRepositories>
```

### CI/CD Integration

1. Go to the project root directory from the command line/terminal
2. Run **`mvn com.integralzone.iz:iz-scan-cli:scan`** command with the following options
   1. -DserviceHost=xxx\
      \&#xNAN;*IZ Scan service URL*
   2. -DauthToken=xxx\
      \&#xNAN;*Security token generated from the server*
   3. -DapplicationKey=x.x\
      \&#xNAN;*Unique ID of the application / project being scanned*
   4. -DapplicationName=.\
      \&#xNAN;*Name of the application being scanned*
   5. -Dsource=xxx\
      \&#xNAN;*Optional. Location of the project source directory. If ignored, the current directory will be used as the project source directory*
   6. -DscmBranchName=xxx + *Optional. SCM branch for which code is being analyzed. If ignored, the default value will be **`master`***
   7. -DpullRequestId=xxx + \_Optional.SCM Pull request name for which code is being analyzed
   8. -Dorganization=xxx + *Optional. Organization under which the project should be categorized. If ignored, the default organization will be used. Value can be any of Organization Name / Id / Ext Id*
   9. -DsarifReport=xxx + \_Optional. Used to generate issues in SARIF format. The output report file path must be specified using this parameter.

Please refer to the section [below](/product-guides/integral-zone/iz-suite/iz-scan/ci-cd-integration/using-maven.md) for instructions on how to retrieve the organization ID.

1. A complete example may look like&#x20;

```
PROJECT_ROOT_DIR> mvn com.integralzone.iz:iz-scan-cli:scan 
-DserviceHost=${FALCON_HOST} 
-DauthToken=${FALCON_TOKEN} 
-DapplicationKey=orders-sapi 
-Dsource=.
-DapplicationName="Orders SAPI"
```

### Retrieve Organization ID

1. Navigate to the main menu **`Organizations`** -> **`Organizations`**
2. In the displayed list of organizations, each one will have an associated **`Id`** as shown below.&#x20;

<figure><img src="/files/9ZnBroZCJMHoPUyRzM4z" alt=""><figcaption></figcaption></figure>

3. Use the Organization ID when performing the CICD scan with the **`-Dorganization`** parameter.

```
_For example: -Dorganization=cm0oy5hht00efv640wm935np9_
```

### Setting Proxy Details

If the system from which the projects are analyzed is configured with a proxy, then set the following arguments with proxy server details -

1. Windows&#x20;

```
-Dhttps.proxyHost=PROXY_HOST -Dhttps.proxyPort=PROXY_PORT -Dhttp.proxyHost=PROXY_HOST -Dhttp.proxyPort=PROXY_PORT -Djava.net.useSystemProxies=true
```

{% hint style="info" %}

* Replace **`PROXY_HOST`** and **`PROXY_PORT`** with appropriate values for Porxy server host and port
* If **`https.proxyPort`** is not specified default value will be 443
* If **`http.proxyPort`** is not specified default value will be 80
  {% endhint %}

### See Also

* [Mule Code Coverage](/product-guides/integral-zone/iz-suite/iz-scan/ci-cd-integration/mule-coverage-reports.md)
* [Aborting Builds](/product-guides/integral-zone/iz-suite/iz-scan/ci-cd-integration/terminate-build.md)
* [Install IZ Scan for Cloud](/product-guides/integral-zone/iz-suite/iz-scan/vs-code-extension/installation/cloud-version.md)
* [Install IZ Scan for Desktop](/product-guides/integral-zone/iz-suite/iz-scan/vs-code-extension/installation/desktop-version.md)


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://knowledgebase.autorabit.com/product-guides/integral-zone/iz-suite/iz-scan/ci-cd-integration/using-maven.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
