|
86 | 86 | 'impact': 'Local license text may need to be scanned',
|
87 | 87 | 'action': 'Add options --detect.blackduck.signature.scanner.license.search=true and optionally --detect.blackduck.signature.scanner.upload.source.mode=true',
|
88 | 88 | 'cli': 'lic',
|
89 |
| - 'cli_search': 'detect.blackduck.signature.scanner.upload.source.mode', |
90 |
| - 'cli_text': '--detect.blackduck.signature.scanner.upload.source.mode=true (CAUTION - will upload local source files)', |
| 89 | + 'cli_search': 'detect.blackduck.signature.scanner.license.search', |
| 90 | + 'cli_text': '--detect.blackduck.signature.scanner.license.search=true\n' |
| 91 | + '--detect.blackduck.signature.scanner.upload.source.mode=true (CAUTION - will upload local source files)', |
| 92 | + |
91 | 93 | },
|
92 | 94 |
|
93 | 95 | 'FILES3': {
|
|
100 | 102 | 'cli_text': '--detect.blackduck.signature.scanner.snippet.matching=SNIPPET_MATCHING (To search for copied OSS source files and functions within source files)',
|
101 | 103 | },
|
102 | 104 |
|
| 105 | + 'FILES4': { |
| 106 | + 'level': 'imp', |
| 107 | + 'desc': 'Folders included in scan which should probably be excluded', |
| 108 | + 'impact': 'Scan size may be larger than required and additional components identified', |
| 109 | + 'action': 'Rerun with --full option to see list of folders to exclude, then use the --detect.excluded.directories option to exclude folders', |
| 110 | + 'cli': 'scan', |
| 111 | + 'cli_search': 'detect.excluded.directories', |
| 112 | + 'cli_text': '--detect.excluded.directories=XXX with --detect.excluded.directories.search.depth=X (search for and exclude folders from scan - see list of folders for exclusion using --full option)', |
| 113 | + }, |
| 114 | + |
103 | 115 | 'SCAN1': {
|
104 | 116 | 'level': 'crit',
|
105 | 117 | 'desc': 'Overall scan size {:>,d} MB) is too large (default max scan size 5GB)',
|
|
139 | 151 | 'level': 'imp',
|
140 | 152 | 'desc': 'Large amount of data ({:>,d} MB) in {} binary files found',
|
141 | 153 | 'impact': 'Binary files not analysed by standard scan, will increase scan size and impact Capacity license usage',
|
142 |
| - 'action': 'Remove files or ignore folders (using .bdignore files), also consider using Binary scan', |
| 154 | + 'action': 'See list of binary files using --full option, then remove files or ignore folders (using .bdignore files), also consider using Binary scan', |
143 | 155 | 'cli': 'scan',
|
144 | 156 | 'cli_search': 'detect.binary.scan.file.name.patterns',
|
145 | 157 | 'cli_text': '--detect.binary.scan.file.name.patterns=exe,bin,dll (for example) and --detect.binary.scan.search.depth=X (folder depth to search for binaries)'
|
|
166 | 178 | 'level': 'crit',
|
167 | 179 | 'desc': 'Required package manager programs ({}) missing for dependency scan in invocation folder',
|
168 | 180 | 'impact': 'Scan will fail',
|
169 |
| - 'action': 'Install required package manager programs', |
| 181 | + 'action': 'See list of affected PMs using --full option, then install required package manager programs', |
170 | 182 | },
|
171 | 183 |
|
172 | 184 | 'PACKAGES4': {
|
173 | 185 | 'level': 'imp',
|
174 | 186 | 'desc': 'Required package manager programs ({}) missing for dependency scan in sub-folders',
|
175 | 187 | 'impact': 'The scan will fail if the scan depth is modified from the default level 0',
|
176 |
| - 'action': 'Install required package manager programs', |
| 188 | + 'action': 'See list of affected PMs using --full option, , then install required package manager programs', |
177 | 189 | },
|
178 | 190 |
|
179 | 191 | 'PACKAGES5': {
|
|
186 | 198 | 'PACKAGES6': {
|
187 | 199 | 'level': 'crit',
|
188 | 200 | 'desc': 'Missing lockfiles/PMs for package manager files in invocation folder',
|
189 |
| - 'impact': 'Dependency scan will fail unless lockfiles created, PMs installed or --detect.accuracy.required=NONE specified', |
190 |
| - 'action': 'Either install required package manager programs, create lockfiles or specify --detect.accuracy.required=NONE (reduced accuracy scan)', |
| 201 | + 'impact': 'Dependency scan will fail', |
| 202 | + 'action': 'See list of affected PMs using --full option, then either install required package manager programs, create lockfiles or specify --detect.accuracy.required=NONE (reduced accuracy scan)', |
191 | 203 | 'cli': 'reqd',
|
192 | 204 | 'cli_search': 'detect.accuracy.required',
|
193 | 205 | 'cli_text': '--detect.accuracy.required=NONE (OR specify --detect.XXXX.path=<LOCATION> where XXX is package manager OR install package managers OR create lockfiles)',
|
|
196 | 208 | 'PACKAGES7': {
|
197 | 209 | 'level': 'imp',
|
198 | 210 | 'desc': 'Missing lockfiles/PMs will cause scan to fail for package manager files in sub-folders',
|
199 |
| - 'impact': 'Dependency scan will fail if scan depth > 0 unless lockfiles created, PMs installed or --detect.accuracy.required=NONE specified', |
200 |
| - 'action': 'Either install required package manager programs, create lockfiles or specify --detect.accuracy.required=NONE (reduced accuracy scan)', |
| 211 | + 'impact': 'Dependency scan will fail if scan depth > 0', |
| 212 | + 'action': 'See list of affected PMs using --full option, then either install required package manager programs, create lockfiles or specify --detect.accuracy.required=NONE (reduced accuracy scan)', |
201 | 213 | 'cli': 'reqd',
|
202 | 214 | 'cli_search': 'detect.accuracy.required',
|
203 | 215 | 'cli_text': '--detect.accuracy.required=NONE (OR specify --detect.XXXX.path=<LOCATION> where XXX is package manager OR install package managers)',
|
|
233 | 245 | # 'cli_search': 'detect.accuracy.required',
|
234 | 246 | # 'cli_text': '--detect.accuracy.required=NONE (OR install JS packages)',
|
235 | 247 | # },
|
236 |
| - # |
| 248 | + |
237 | 249 | 'PACKAGES12': {
|
238 | 250 | 'level': 'imp',
|
239 | 251 | 'desc': 'Lockfile(s) required for dependency scan missing in invocation folder',
|
|
260 | 272 |
|
261 | 273 |
|
262 | 274 | def message(id, val1='', val2=''):
|
| 275 | + if id in global_values.message_list: |
| 276 | + return |
263 | 277 | if id in messages_dict:
|
| 278 | + global_values.message_list.append(id) |
264 | 279 | if val2 != '':
|
265 | 280 | mtext = f"- {levtexts[messages_dict[id]['level']]}: " + messages_dict[id]['desc'].format(val1, val2) + '\n'
|
266 | 281 | elif val1 != '':
|
|
0 commit comments