Matthias Bertschy
5d4bd2e94e
removing enable/disable colors, as not compatible with all loggers
...
Signed-off-by: Matthias Bertschy <matthias.bertschy@gmail.com >
2025-02-18 11:38:47 +01:00
Eng Zer Jun
2005010568
Replace golang.org/x/exp/slices with slices from stdlib ( #1783 )
2025-01-17 20:51:08 +02:00
Amir Malka
14ffe35437
add trigger by indication in posture report
...
Signed-off-by: Amir Malka <amirm@armosec.io >
2025-01-09 16:13:29 +02:00
Matthias Bertschy
70a9380966
fix go imports
...
Signed-off-by: Matthias Bertschy <matthias.bertschy@gmail.com >
2025-01-09 12:14:56 +01:00
Ben
4f3ef49f99
Implementing capability to print out the "print" statements of the rego
...
Signed-off-by: Ben <ben@armosec.io >
2024-11-20 00:10:18 +02:00
Matthias Bertschy
761d4c6ff4
gofmt and try to make linter happy
...
Signed-off-by: Matthias Bertschy <matthias.bertschy@gmail.com >
2024-11-19 15:10:37 +01:00
jnathangreeg
7735087937
fix the repo scan get stucked bug
...
Signed-off-by: jnathangreeg <jonathang@armosec.io >
2024-11-19 15:13:31 +02:00
Matthias Bertschy
2d77ea7b62
use pager.EachListItem to filter parented resources
...
Signed-off-by: Matthias Bertschy <matthias.bertschy@gmail.com >
2024-07-03 16:41:12 +02:00
David Wertenteil
3cbd2c458d
fix scanning repo
...
Signed-off-by: David Wertenteil <dwertent@armosec.io >
2024-05-06 16:22:38 +03:00
Matthias Bertschy
9521cf1974
bump syft version
...
Signed-off-by: Matthias Bertschy <matthias.bertschy@gmail.com >
2024-04-29 14:00:18 +02:00
fanqiaojun
bd35d521f2
Fix some comments
...
Signed-off-by: fanqiaojun <fanqiaojun@yeah.net >
2024-04-13 15:42:01 +08:00
Matthias Bertschy
d27284b6f6
remove api calls from scan repo
...
Signed-off-by: Matthias Bertschy <matthias.bertschy@gmail.com >
2024-04-09 07:37:58 +02:00
YiscahLevySilas1
0477f8cb03
use regolibrary v2
...
Signed-off-by: YiscahLevySilas1 <yiscahls@armosec.io >
2024-03-26 09:05:01 +02:00
Matthias Bertschy
da022a1cf0
set BuildNumber and Client from env
...
Signed-off-by: Matthias Bertschy <matthias.bertschy@gmail.com >
2024-03-12 16:11:58 +01:00
David Wertenteil
abefe8c21a
Merge pull request #1593 from kubescape/daily
...
update daily report
2024-03-11 09:26:28 +02:00
mmmmmmorty
f5e110c212
Fix bug for no matches of yalib in one file mapping
...
Signed-off-by: mmmmmmorty <mmmmmmorty@outlook.com >
2024-03-08 10:50:39 +02:00
Matthias Bertschy
2429d2b89d
move versioncheck to kubescape/backend
...
Signed-off-by: Matthias Bertschy <matthias.bertschy@gmail.com >
2024-03-06 14:44:37 +01:00
MMMMMMorty
bc33f10d0a
feat: Add the debugging ability for scanning Helm chart ( #1215 )
...
* Fix issue 11552
Signed-off-by: MMMMMMorty <465346562@qq.com >
* Add helm chart mapping node for sarif printer
Signed-off-by: mmmmmmorty <mmmmmmorty@outlook.com >
* add MappingNodes to getWorkloadFromHelmChart
Signed-off-by: mmmmmmorty <mmmmmmorty@outlook.com >
* clear the code to mappingnode and parseFile
Signed-off-by: mmmmmmorty <mmmmmmorty@outlook.com >
* add input to fixPathsToString
Signed-off-by: mmmmmmorty <mmmmmmorty@outlook.com >
* add fixs for error message
Signed-off-by: mmmmmmorty <mmmmmmorty@outlook.com >
* Add solution for multiple files in one yaml helm chart file
Signed-off-by: mmmmmmorty <mmmmmmorty@outlook.com >
* Add parseFile tests
Signed-off-by: mmmmmmorty <mmmmmmorty@outlook.com >
---------
Signed-off-by: MMMMMMorty <465346562@qq.com >
Signed-off-by: mmmmmmorty <mmmmmmorty@outlook.com >
2024-03-01 14:31:51 +02:00
Matthias Bertschy
3e287db1f9
remove libgit files and dependencies
...
Signed-off-by: Matthias Bertschy <matthias.bertschy@gmail.com >
2024-01-20 10:24:21 +01:00
Amir Malka
4b8786bcaa
checking for compatible policy rules before pulling k8s resources; failing to pull some k8s resource should not fail the entire scan ( #1578 )
...
Signed-off-by: Amir Malka <amirm@armosec.io >
2024-01-09 09:44:45 +02:00
David Wertenteil
65a557db90
fixed test ( #1573 )
...
* fixed test
Signed-off-by: David Wertenteil <dwertent@armosec.io >
* update cosign-release version
Signed-off-by: David Wertenteil <dwertent@armosec.io >
* fixed filepath related tests
Signed-off-by: David Wertenteil <dwertent@armosec.io >
* failed windows tests
Signed-off-by: David Wertenteil <dwertent@armosec.io >
* fixed cosign version
Signed-off-by: David Wertenteil <dwertent@armosec.io >
* update go version
Signed-off-by: David Wertenteil <dwertent@armosec.io >
* fixed test
Signed-off-by: David Wertenteil <dwertent@armosec.io >
* change actor
Signed-off-by: David Wertenteil <dwertent@armosec.io >
* Cosign use secret
Signed-off-by: David Wertenteil <dwertent@armosec.io >
* update cosign
Signed-off-by: David Wertenteil <dwertent@armosec.io >
* update cosign
Signed-off-by: David Wertenteil <dwertent@armosec.io >
---------
Signed-off-by: David Wertenteil <dwertent@armosec.io >
2024-01-07 16:26:34 +02:00
VaibhavMalik4187
155889a479
Added missing tests for locationresolver
...
Wrote new tests to cover the unhandled statements in the
`NewFixPathLocationResolver` and `ResolveLocation` functions.
Signed-off-by: VaibhavMalik4187 <vaibhavmalik2018@gmail.com >
2023-12-23 17:23:07 +05:30
Matthias Bertschy
e29e6a5e8a
add wlid annotation to workloadconfigurationscans and summaries
...
Signed-off-by: Matthias Bertschy <matthias.bertschy@gmail.com >
2023-12-12 10:42:02 +01:00
Yuval Leibovich
e4e795c6dc
Merge pull request #1548 from kubescape/remove-armoBuiltin
...
Removal of "armoBuiltin" attribute from JSON files
2023-11-27 16:17:35 +02:00
VaibhavMalik4187
d1b78856ca
Added tests for versioncheck and printer packages
...
Wrote new tests for the following files:
- junit.go
- pdf.go
- versioncheck.go
Signed-off-by: VaibhavMalik4187 <vaibhavmalik2018@gmail.com >
2023-11-27 18:25:34 +05:30
Yuval Leibovich
69362ae415
Update MITRE.json
...
Signed-off-by: Yuval Leibovich <89763818+yuleib@users.noreply.github.com >
2023-11-27 12:01:14 +02:00
Yuval Leibovich
bb17e1de78
Update NSA.json
...
Signed-off-by: Yuval Leibovich <89763818+yuleib@users.noreply.github.com >
2023-11-27 11:57:31 +02:00
Yuval Leibovich
504891f519
Update C-0001.json
...
Signed-off-by: Yuval Leibovich <89763818+yuleib@users.noreply.github.com >
2023-11-27 11:51:09 +02:00
Daniel Grunberger
952beddcc3
add scan source
...
Signed-off-by: Daniel Grunberger <danielgrunberger@armosec.io >
2023-11-27 11:24:25 +02:00
Mehdi Moussaif
70a010976e
Removed unused functions
...
Signed-off-by: Mehdi Moussaif <m.moussaif42@gmail.com >
2023-11-26 19:06:10 +01:00
sulemaanhamza
c84a8a7dea
Enhancements in strutils and added test-suite with edge-case test-cases
...
Signed-off-by: sulemaanhamza <sulemanhamza97@gmail.com >
2023-11-26 12:43:17 +05:00
Matthias Bertschy
2adb72be8e
Merge pull request #1509 from mohaidoss/tests/cautils-jsonutils
...
Adding Unit Tests and Bug Fix for core/cautils
2023-11-25 10:47:36 +01:00
Matthias Bertschy
43ba550f72
Merge pull request #1486 from cbrom/core_cautils_getter_json_tests
...
Adding Additional Test Cases for JSONDecoder in core/cautils/getter
2023-11-25 10:43:36 +01:00
Mehdi Moussaif
9611fb631b
Adding tests core/cautils/kustomizeddirectory
...
Signed-off-by: Mehdi Moussaif <m.moussaif42@gmail.com >
2023-11-24 23:43:10 +01:00
Mehdi Moussaif
44ddbc6ae5
Bug fix IsKustomizeDirectory returning parent dir
...
Signed-off-by: Mehdi Moussaif <m.moussaif42@gmail.com >
2023-11-24 23:42:17 +01:00
cbrom
f86fa99316
reverted core/cautils/getter/json.go file, as the json and init of json is necessary
...
Signed-off-by: cbrom <kb.cbrom@gmail.com >
2023-11-25 00:59:45 +03:00
cbrom
2603f04cfc
added tests for empty and invalid string inputs to JSONDecoder
...
Signed-off-by: cbrom <kb.cbrom@gmail.com >
changed test input to clearly show its not a valid
Signed-off-by: cbrom <kb.cbrom@gmail.com >
added tests for valid json input to JSONDecoder function
Signed-off-by: cbrom <kb.cbrom@gmail.com >
check for specific error message instead of just error return
Signed-off-by: cbrom <kb.cbrom@gmail.com >
check for specific error message instead of just error return
Signed-off-by: cbrom <kb.cbrom@gmail.com >
package imports added
Signed-off-by: cbrom <kb.cbrom@gmail.com >
removed unnecessary mock json file
Signed-off-by: cbrom <kb.cbrom@gmail.com >
min function moved to kscloudapi.go
Signed-off-by: cbrom <kb.cbrom@gmail.com >
added necessary functions to make a post api call
Signed-off-by: cbrom <kb.cbrom@gmail.com >
getLatestVersion now uses KSCloudAPI functions
Signed-off-by: cbrom <kb.cbrom@gmail.com >
reverted moved function min back
Signed-off-by: cbrom <kb.cbrom@gmail.com >
removed unncessary functions and simplified post method
Signed-off-by: cbrom <kb.cbrom@gmail.com >
modified call to APIPostRequest
Signed-off-by: cbrom <kb.cbrom@gmail.com >
renamed HTTPPost request function and added httpClient param (for testing purposes)
Signed-off-by: cbrom <kb.cbrom@gmail.com >
changed function name call
Signed-off-by: cbrom <kb.cbrom@gmail.com >
removed HTTPPost function test
Signed-off-by: cbrom <kb.cbrom@gmail.com >
net/http imported
Signed-off-by: cbrom <kb.cbrom@gmail.com >
bytes import removed
Signed-off-by: cbrom <kb.cbrom@gmail.com >
test added for HTTPPost function
Signed-off-by: cbrom <kb.cbrom@gmail.com >
removed json decoder as it is not necessary anymore
Signed-off-by: cbrom <kb.cbrom@gmail.com >
removed HttpPost function
Signed-off-by: cbrom <kb.cbrom@gmail.com >
2023-11-25 00:00:58 +03:00
Mehdi Moussaif
dfd13aea6f
Add tests for krewutils
...
Signed-off-by: Mehdi Moussaif <m.moussaif42@gmail.com >
2023-11-24 18:48:04 +01:00
Mehdi Moussaif
9fda098f70
Add tests for workloadmappingutils
...
Signed-off-by: Mehdi Moussaif <m.moussaif42@gmail.com >
2023-11-24 18:37:19 +01:00
Mehdi Moussaif
94f6261055
Add Test to PrettyJson
...
Signed-off-by: Mehdi Moussaif <m.moussaif42@gmail.com >
2023-11-24 17:42:43 +01:00
Mehdi Moussaif
1d7519c3b7
Added tests for core/cautils/versioncheck
...
Signed-off-by: Mehdi Moussaif <m.moussaif42@gmail.com >
2023-11-24 15:39:06 +01:00
Mehdi Moussaif
6cf03bd679
bug resetting the var LatestReleaseVersion
...
Signed-off-by: Mehdi Moussaif <m.moussaif42@gmail.com >
enhancement of update CMD
Signed-off-by: Mehdi Moussaif <m.moussaif42@gmail.com >
2023-11-24 15:38:09 +01:00
Matthias Bertschy
5d795edd31
Merge pull request #1493 from mohaidoss/fix-download-artifacts
...
Fix for Kubescape Reading Policies from Local File
2023-11-23 12:56:54 +01:00
Mehdi Moussaif
fd390bbd37
Bug fix where kubescape fails to read from framework local paths
...
Fix typo in error description
Bug fix where kubescape get policies from file
Signed-off-by: Mehdi Moussaif <m.moussaif42@gmail.com >
Missing '.json' extension when getting Framework Paths
Signed-off-by: Mehdi Moussaif <m.moussaif42@gmail.com >
Appropriate test case for FrameworksPaths
Bug fix where kubescape fails to read from frameworks local paths
Signed-off-by: Mehdi Moussaif <m.moussaif42@gmail.com >
2023-11-23 12:46:44 +01:00
Cbrom
5455855e65
Merge branch 'kubescape:master' into core_cautils_datastructuremethods_tests
2023-11-22 22:13:58 +03:00
cbrom
12056f4cad
fixed a test where it would run 1 test case twice
...
Signed-off-by: cbrom <kb.cbrom@gmail.com >
2023-11-22 19:28:30 +03:00
cbrom
d96ab483a4
code improvement on type assertion for useFromKubescapeVersion and useUntilKubescapeVersion
...
Signed-off-by: cbrom <kb.cbrom@gmail.com >
2023-11-22 19:27:52 +03:00
Matthias Bertschy
dc6c379aa2
Merge pull request #1487 from cbrom/core_cautils_datastructuremethods_tests
...
Adding Tests and Refactoring for ruleWithKSOpaDependency Function in cautils
2023-11-22 17:21:17 +01:00
VaibhavMalik4187
beb6d9535c
Added tests for cautils
...
Wrote new tests for the following files:
- controllink.go
- display.go
- fileutils.go
- getter/getpoliciesutils.go
- getter/utils.go
Signed-off-by: VaibhavMalik4187 <vaibhavmalik2018@gmail.com >
2023-11-22 20:24:16 +05:30
cbrom
4ae45cd727
added tests for non string values of useUntilKubescapeVersion and useFromKubescapeVersion
...
Signed-off-by: cbrom <kb.cbrom@gmail.com >
2023-11-22 11:39:36 +03:00