Skip to content

Commit

Permalink
Dsomm (#452)
Browse files Browse the repository at this point in the history
* decrease slug size

* start importing dsomm

* start importing dsomm

* lint

* finish dsomm iso mappings importer

* add ability to also use SAMM as a glue

* lint

* add makefile target

* final touches

* lint

---------

Signed-off-by: Spyros <[email protected]>
  • Loading branch information
northdpole authored Nov 19, 2023
1 parent d1f2162 commit f9d156b
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 1 deletion.
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,7 @@ import-all:
make migrate-upgrade && export FLASK_APP=$(CURDIR)/cre.py &&\
python cre.py --add --from_spreadsheet https://docs.google.com/spreadsheets/d/1eZOEYgts7d_-Dr-1oAbogPfzBLh6511b58pX3b59kvg &&\
python cre.py --generate_embeddings && \
python cre.py --zap_in --cheatsheets_in --github_tools_in --capec_in --owasp_secure_headers_in --pci_dss_4_in --juiceshop_in --dsomm_in --cloud_native_security_controls_in &&\
python cre.py --zap_in --cheatsheets_in --github_tools_in --capec_in --owasp_secure_headers_in --pci_dss_4_in --juiceshop_in --dsomm_in --dsomm_in --cloud_native_security_controls_in &&\
python cre.py --generate_embeddings

import-neo4j:
Expand Down
12 changes: 12 additions & 0 deletions application/utils/external_project_parsers/dsomm.py
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,10 @@
"vcs usage is not explicitly covered by ISO 27001 - too specific",
"System hardening, virtual environments are not explicitly covered by ISO 27001 - too specific",
]
manual_mappings = {
"Usage of feature toggles": "344-611",
"Usage of edge encryption at transit": "435-702",
}


def parse(
Expand Down Expand Up @@ -91,6 +95,14 @@ def parse(
)

dbstandard = cache.add_node(standard)
if manual_mappings.get(aname):
cs = cache.get_CREs(manual_mappings.get(aname))
for c in cs:
cache.add_link(
cre=db.dbCREfromCRE(c),
node=dbstandard,
type=defs.LinkTypes.LinkedTo,
)
# use SAMM as Glue
if activity.get("references").get("samm2"):
for sectionID in activity.get("references").get("samm2"):
Expand Down

0 comments on commit f9d156b

Please sign in to comment.