Skip to content

Commit 55b070e

Browse files
Merge remote-tracking branch 'refs/remotes/origin/CM-63882-cli-fix-scan-type-validation' into CM-63882-cli-fix-scan-type-validation
2 parents 9fa9442 + 316a177 commit 55b070e

13 files changed

Lines changed: 190 additions & 30 deletions

File tree

.github/workflows/build_executable.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ jobs:
3838
steps:
3939
- name: Run Cimon
4040
if: matrix.os == 'ubuntu-22.04'
41-
uses: cycodelabs/cimon-action@f99ad5557cb80964bc2b2e76a47bf4b5ba6e323b # v0.10.0
41+
uses: cycodelabs/cimon-action@3ca67e875f34772093aa3bf3c185a711720bf5d9 # v0.10.1
4242
with:
4343
client-id: ${{ secrets.CIMON_CLIENT_ID }}
4444
secret: ${{ secrets.CIMON_SECRET }}
@@ -68,7 +68,7 @@ jobs:
6868

6969
- name: Load cached Poetry setup
7070
id: cached-poetry
71-
uses: actions/cache@cdf6c1fa76f9f475f3d7449005a359c84ca0f306 # v5.0.3
71+
uses: actions/cache@27d5ce7f107fe9357f9df03efb73ab90386fccae # v5.0.5
7272
with:
7373
path: ~/.local
7474
key: poetry-${{ matrix.os }}-2 # increment to reset cache

.github/workflows/docker-image.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ jobs:
3737

3838
- name: Load cached Poetry setup
3939
id: cached_poetry
40-
uses: actions/cache@cdf6c1fa76f9f475f3d7449005a359c84ca0f306 # v5.0.3
40+
uses: actions/cache@27d5ce7f107fe9357f9df03efb73ab90386fccae # v5.0.5
4141
with:
4242
path: ~/.local
4343
key: poetry-ubuntu-1 # increment to reset cache
@@ -76,7 +76,7 @@ jobs:
7676
- name: Build and push
7777
id: docker_build
7878
if: ${{ github.event_name == 'workflow_dispatch' || startsWith(github.ref, 'refs/tags/v') }}
79-
uses: docker/build-push-action@d08e5c354a6adb9ed34480a06d141179aa583294 # v7.0.0
79+
uses: docker/build-push-action@bcafcacb16a39f128d818304e6c9c0c18556b85f # v7.1.0
8080
with:
8181
context: .
8282
platforms: linux/amd64,linux/arm64
@@ -86,7 +86,7 @@ jobs:
8686
- name: Verify build
8787
id: docker_verify_build
8888
if: ${{ github.event_name != 'workflow_dispatch' && !startsWith(github.ref, 'refs/tags/v') }}
89-
uses: docker/build-push-action@d08e5c354a6adb9ed34480a06d141179aa583294 # v7.0.0
89+
uses: docker/build-push-action@bcafcacb16a39f128d818304e6c9c0c18556b85f # v7.1.0
9090
with:
9191
context: .
9292
platforms: linux/amd64,linux/arm64

.github/workflows/pre_release.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ jobs:
1515

1616
steps:
1717
- name: Run Cimon
18-
uses: cycodelabs/cimon-action@f99ad5557cb80964bc2b2e76a47bf4b5ba6e323b # v0.10.0
18+
uses: cycodelabs/cimon-action@3ca67e875f34772093aa3bf3c185a711720bf5d9 # v0.10.1
1919
with:
2020
client-id: ${{ secrets.CIMON_CLIENT_ID }}
2121
secret: ${{ secrets.CIMON_SECRET }}
@@ -39,7 +39,7 @@ jobs:
3939

4040
- name: Load cached Poetry setup
4141
id: cached-poetry
42-
uses: actions/cache@cdf6c1fa76f9f475f3d7449005a359c84ca0f306 # v5.0.3
42+
uses: actions/cache@27d5ce7f107fe9357f9df03efb73ab90386fccae # v5.0.5
4343
with:
4444
path: ~/.local
4545
key: poetry-ubuntu-1 # increment to reset cache

.github/workflows/release.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ jobs:
1414

1515
steps:
1616
- name: Run Cimon
17-
uses: cycodelabs/cimon-action@f99ad5557cb80964bc2b2e76a47bf4b5ba6e323b # v0.10.0
17+
uses: cycodelabs/cimon-action@3ca67e875f34772093aa3bf3c185a711720bf5d9 # v0.10.1
1818
with:
1919
client-id: ${{ secrets.CIMON_CLIENT_ID }}
2020
secret: ${{ secrets.CIMON_SECRET }}
@@ -38,7 +38,7 @@ jobs:
3838

3939
- name: Load cached Poetry setup
4040
id: cached-poetry
41-
uses: actions/cache@cdf6c1fa76f9f475f3d7449005a359c84ca0f306 # v5.0.3
41+
uses: actions/cache@27d5ce7f107fe9357f9df03efb73ab90386fccae # v5.0.5
4242
with:
4343
path: ~/.local
4444
key: poetry-ubuntu-1 # increment to reset cache

.github/workflows/ruff.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ jobs:
1010
runs-on: ubuntu-latest
1111
steps:
1212
- name: Run Cimon
13-
uses: cycodelabs/cimon-action@f99ad5557cb80964bc2b2e76a47bf4b5ba6e323b # v0.10.0
13+
uses: cycodelabs/cimon-action@3ca67e875f34772093aa3bf3c185a711720bf5d9 # v0.10.1
1414
with:
1515
client-id: ${{ secrets.CIMON_CLIENT_ID }}
1616
secret: ${{ secrets.CIMON_SECRET }}
@@ -30,7 +30,7 @@ jobs:
3030

3131
- name: Load cached Poetry setup
3232
id: cached-poetry
33-
uses: actions/cache@cdf6c1fa76f9f475f3d7449005a359c84ca0f306 # v5.0.3
33+
uses: actions/cache@27d5ce7f107fe9357f9df03efb73ab90386fccae # v5.0.5
3434
with:
3535
path: ~/.local
3636
key: poetry-ubuntu-1 # increment to reset cache

.github/workflows/tests.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ jobs:
1111

1212
steps:
1313
- name: Run Cimon
14-
uses: cycodelabs/cimon-action@f99ad5557cb80964bc2b2e76a47bf4b5ba6e323b # v0.10.0
14+
uses: cycodelabs/cimon-action@3ca67e875f34772093aa3bf3c185a711720bf5d9 # v0.10.1
1515
with:
1616
client-id: ${{ secrets.CIMON_CLIENT_ID }}
1717
secret: ${{ secrets.CIMON_SECRET }}
@@ -32,7 +32,7 @@ jobs:
3232

3333
- name: Load cached Poetry setup
3434
id: cached-poetry
35-
uses: actions/cache@cdf6c1fa76f9f475f3d7449005a359c84ca0f306 # v5.0.3
35+
uses: actions/cache@27d5ce7f107fe9357f9df03efb73ab90386fccae # v5.0.5
3636
with:
3737
path: ~/.local
3838
key: poetry-ubuntu-1 # increment to reset cache

.github/workflows/tests_full.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ jobs:
2424
steps:
2525
- name: Run Cimon
2626
if: matrix.os == 'ubuntu-latest'
27-
uses: cycodelabs/cimon-action@f99ad5557cb80964bc2b2e76a47bf4b5ba6e323b # v0.10.0
27+
uses: cycodelabs/cimon-action@3ca67e875f34772093aa3bf3c185a711720bf5d9 # v0.10.1
2828
with:
2929
client-id: ${{ secrets.CIMON_CLIENT_ID }}
3030
secret: ${{ secrets.CIMON_SECRET }}
@@ -47,7 +47,7 @@ jobs:
4747

4848
- name: Load cached Poetry setup
4949
id: cached-poetry
50-
uses: actions/cache@cdf6c1fa76f9f475f3d7449005a359c84ca0f306 # v5.0.3
50+
uses: actions/cache@27d5ce7f107fe9357f9df03efb73ab90386fccae # v5.0.5
5151
with:
5252
path: ~/.local
5353
key: poetry-${{ matrix.os }}-${{ matrix.python-version }}-3 # increment to reset cache

CODEOWNERS

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
* @elsapet @gotbadger @mateusz-sterczewski
1+
* @avishaiamiel @omerr-cycode

README.md

Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,7 @@ This guide walks you through both installation and usage.
2121
2. [Available Options](#available-options)
2222
3. [MCP Tools](#mcp-tools)
2323
4. [Usage Examples](#usage-examples)
24+
5. [Advanced Configuration](#advanced-configuration)
2425
5. [Platform Command](#platform-command-beta)
2526
1. [Discovering Commands](#discovering-commands)
2627
2. [Examples](#platform-examples)
@@ -559,6 +560,38 @@ cycode mcp -t streamable-http -H 127.0.0.2 -p 9000 &
559560
}
560561
```
561562

563+
### Advanced Configuration
564+
##### Custom Certificates and Timeouts (Proxy Environments)
565+
566+
If your organization uses a corporate proxy or a custom CA bundle for HTTPS inspection, you need to tell Cycode CLI (and the underlying Python TLS stack) where to find the trusted certificate bundle. You can also increase the MCP tool call timeout if scans are being cut short.
567+
568+
| Environment Variable | Description |
569+
|----------------------|-------------|
570+
| `REQUESTS_CA_BUNDLE` | Path to a custom CA bundle file (`.pem` or `.crt`). Used by the `requests` library for all HTTPS calls made by Cycode CLI. |
571+
| `SSL_CERT_FILE` | Path to a custom CA bundle file. Used by Python's low-level `ssl` module. Set this alongside `REQUESTS_CA_BUNDLE` for full coverage. |
572+
| `MCP_TOOL_TIMEOUT` | Timeout (in seconds) that MCP clients such as Claude and GitHub Copilot wait for a tool call to complete. Increase this if long-running scans are being cut off before they finish. |
573+
574+
> [!TIP]
575+
> Set both `REQUESTS_CA_BUNDLE` and `SSL_CERT_FILE` to the same CA bundle path. `REQUESTS_CA_BUNDLE` covers the HTTP layer; `SSL_CERT_FILE` covers the lower-level TLS layer. Using only one may still cause certificate errors in some environments.
576+
577+
Example `mcp.json` configuration with custom certificates and a longer timeout:
578+
579+
```json
580+
{
581+
"mcpServers": {
582+
"cycode": {
583+
"command": "cycode",
584+
"args": ["mcp"],
585+
"env": {
586+
"REQUESTS_CA_BUNDLE": "/path/to/your/corporate-ca-bundle.pem",
587+
"SSL_CERT_FILE": "/path/to/your/corporate-ca-bundle.pem",
588+
"MCP_TOOL_TIMEOUT": "1800"
589+
}
590+
}
591+
}
592+
}
593+
```
594+
562595
> [!NOTE]
563596
> The MCP server requires proper Cycode CLI authentication to function. Make sure you have authenticated using `cycode auth` or configured your credentials before starting the MCP server.
564597
@@ -608,6 +641,8 @@ This information can be helpful when:
608641
- Identifying authentication problems
609642
- Debugging transport-specific issues
610643
644+
### MCP Configuration
645+
611646
612647
# Platform Command \[BETA\]
613648

cycode/cli/files_collector/sca/maven/restore_maven_dependencies.py

Lines changed: 21 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
import json
12
from os import path
23
from pathlib import Path
34
from typing import Optional
@@ -20,6 +21,16 @@
2021
MAVEN_DEP_TREE_FILE_NAME = 'bcde.mvndeps'
2122

2223

24+
def _has_dependency_graph(bom_content: Optional[str]) -> bool:
25+
try:
26+
if not bom_content:
27+
return False
28+
bom = json.loads(bom_content)
29+
return any(dep.get('dependsOn') for dep in bom.get('dependencies', []))
30+
except Exception:
31+
return False
32+
33+
2334
class RestoreMavenDependencies(BaseRestoreDependencies):
2435
def __init__(self, ctx: typer.Context, is_git_diff: bool, command_timeout: int) -> None:
2536
super().__init__(ctx, is_git_diff, command_timeout)
@@ -46,8 +57,16 @@ def try_restore_dependencies(self, document: Document) -> Optional[Document]:
4657
if document.content is None:
4758
return self.restore_from_secondary_command(document, manifest_file_path)
4859

49-
# super() reads the content and cleans up any generated file; no re-read needed
50-
return super().try_restore_dependencies(document)
60+
restore_dependencies_document = super().try_restore_dependencies(document)
61+
if restore_dependencies_document is None:
62+
return None
63+
64+
if not _has_dependency_graph(restore_dependencies_document.content):
65+
fallback = self.restore_from_secondary_command(document, manifest_file_path)
66+
if fallback is not None and fallback.content is not None:
67+
return fallback
68+
69+
return restore_dependencies_document
5170

5271
def restore_from_secondary_command(self, document: Document, manifest_file_path: str) -> Optional[Document]:
5372
restore_content = execute_commands(

0 commit comments

Comments
 (0)