Commit d1492bb
committed
feat(scanner): Add detected license mapping to
Add the detected license mapping from the `ScannerConfiguration` to the
`ScanContext` to make it available to `ScannerWrapper`s. This is
currently only required by the `FossId` implementation because FossID
can return arbitrary strings as licenses. These strings can sometimes
not be parsed as SPDX expressions and can therefore not be returned as
part of a `LicenseFinding` in the `ScanSummary`.
A better solution could be to automatically convert all license strings
returned by FossID to a form that can be parsed as SPDX expression, then
the mapping could be applied globally. However, as this would be a
breaking configuration change it is not implemented now and only added
as a TODO comment instead.
Signed-off-by: Martin Nonnenmacher <[email protected]>ScanContext
1 parent ffce6dc commit d1492bb
File tree
4 files changed
+40
-7
lines changed- plugins/scanners/fossid/src/main/kotlin
- scanner/src/main/kotlin
4 files changed
+40
-7
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
310 | 310 | | |
311 | 311 | | |
312 | 312 | | |
313 | | - | |
| 313 | + | |
| 314 | + | |
| 315 | + | |
| 316 | + | |
| 317 | + | |
| 318 | + | |
| 319 | + | |
| 320 | + | |
| 321 | + | |
314 | 322 | | |
315 | 323 | | |
316 | 324 | | |
| |||
857 | 865 | | |
858 | 866 | | |
859 | 867 | | |
860 | | - | |
| 868 | + | |
| 869 | + | |
861 | 870 | | |
862 | 871 | | |
863 | 872 | | |
| |||
875 | 884 | | |
876 | 885 | | |
877 | 886 | | |
878 | | - | |
| 887 | + | |
879 | 888 | | |
880 | 889 | | |
881 | 890 | | |
| |||
Lines changed: 3 additions & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
85 | 85 | | |
86 | 86 | | |
87 | 87 | | |
88 | | - | |
| 88 | + | |
| 89 | + | |
| 90 | + | |
89 | 91 | | |
90 | 92 | | |
91 | 93 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
19 | 19 | | |
20 | 20 | | |
21 | 21 | | |
| 22 | + | |
22 | 23 | | |
23 | 24 | | |
24 | 25 | | |
| 26 | + | |
| 27 | + | |
25 | 28 | | |
26 | 29 | | |
27 | 30 | | |
| |||
40 | 43 | | |
41 | 44 | | |
42 | 45 | | |
43 | | - | |
| 46 | + | |
| 47 | + | |
| 48 | + | |
| 49 | + | |
| 50 | + | |
| 51 | + | |
| 52 | + | |
| 53 | + | |
| 54 | + | |
| 55 | + | |
| 56 | + | |
44 | 57 | | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
124 | 124 | | |
125 | 125 | | |
126 | 126 | | |
127 | | - | |
| 127 | + | |
| 128 | + | |
128 | 129 | | |
129 | 130 | | |
130 | 131 | | |
| |||
139 | 140 | | |
140 | 141 | | |
141 | 142 | | |
142 | | - | |
| 143 | + | |
| 144 | + | |
| 145 | + | |
| 146 | + | |
| 147 | + | |
| 148 | + | |
| 149 | + | |
| 150 | + | |
| 151 | + | |
143 | 152 | | |
144 | 153 | | |
145 | 154 | | |
| |||
0 commit comments