aboutsummaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authorPetr Svenda2021-02-18 09:02:08 +0100
committerPetr Svenda2021-02-18 09:02:08 +0100
commitd725af6166e506aeaefd680b4368d6ddc4db916e (patch)
treecd594943d86423c0cc6ec1e286237aa50176c847
parent0fb1b04a6fbb172db6682380be34a44d68197ba3 (diff)
downloadsec-certs-d725af6166e506aeaefd680b4368d6ddc4db916e.tar.gz
sec-certs-d725af6166e506aeaefd680b4368d6ddc4db916e.tar.zst
sec-certs-d725af6166e506aeaefd680b4368d6ddc4db916e.zip
add more precise detection of Common Criteria methodology reference
-rw-r--r--sec_certs/cert_rules.py8
1 files changed, 5 insertions, 3 deletions
diff --git a/sec_certs/cert_rules.py b/sec_certs/cert_rules.py
index d8749495..291bfe3b 100644
--- a/sec_certs/cert_rules.py
+++ b/sec_certs/cert_rules.py
@@ -58,8 +58,7 @@ rules_protection_profiles = [
'PP-SSCD.+?',
'PP_DBMS_.+?'
# 'Protection Profile',
- 'CCMB-20.+?',
- 'CCMB-20[0-9]+?-[0-9]+?-[0-9]+?',
+ #'CCMB-20.+?',
'BSI-CCPP-.+?',
'ANSSI-CC-PP.+?',
'WBIS_V[0-9]\\.[0-9]',
@@ -97,6 +96,8 @@ rules_standard_id = [
'[Xx]\\.509',
'RFC [0-9]+',
'(?:SCP|scp)[ \']*[0-9][0-9]',
+ 'CC[I]*MB-20[0-9]+?-[0-9]+?-[0-9]+?', # Common Criteria methodology
+ 'CCIMB-9[0-9]-[0-9]+?' # Common Criteria methodology old
]
rules_security_level = [
@@ -504,7 +505,8 @@ fips_rules['rules_fips_algorithms'] = rules_fips_remove_algorithm_ids
fips_rules['rules_security_level'] = rules_fips_security_level
fips_rules['rules_cert_id'] = rules_fips_cert
fips_common_rules = copy.deepcopy(common_rules) # make separate copy not to process cc rules by fips's re.compile
+fips_rules.update(fips_common_rules)
for rule in fips_rules:
for current_rule in range(len(fips_rules[rule])):
- fips_rules[rule][current_rule] = re.compile(fips_rules[rule][current_rule])
+ fips_rules[rule][current_rule] = re.compile(fips_rules[rule][current_rule] + REGEXEC_SEP) \ No newline at end of file