Commit 817e0f9
committed
fix(data-mapper-v2): Address Copilot review comments for security and robustness
Security fixes:
- Replace polynomial regex with string-based parsing in XsltMetadataSerializer
- Add prototype pollution protection in XsltParser with safe property assignment
Robustness improvements:
- Add robust xslt3 path resolution checking multiple locations
- Add XSLT size validation (5MB limit) before processing
- Add XSLT parsing error handling with user-friendly messages
- Handle empty map definition with null-coalescing fallback
- Prevent stale test results with ref-based deduplication
- Add detailed temp file cleanup logging
Performance optimization:
- Optimize position updates to avoid flooding undo history
Testing:
- Add comprehensive test suites for Redux slices, utilities, and query hooks
- 217 new tests added (484 total tests now passing)1 parent c24e650 commit 817e0f9
22 files changed
Lines changed: 2472 additions & 64 deletions
File tree
- Localize/lang
- apps
- vs-code-designer/src/app/commands/dataMapper
- vs-code-react/src
- libs/data-mapper-v2/src
- core
- queries/__test__
- state
- __test__
- mapHandling
- utils/__test__
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
400 | 400 | | |
401 | 401 | | |
402 | 402 | | |
| 403 | + | |
403 | 404 | | |
404 | 405 | | |
405 | 406 | | |
| |||
1964 | 1965 | | |
1965 | 1966 | | |
1966 | 1967 | | |
| 1968 | + | |
1967 | 1969 | | |
1968 | 1970 | | |
1969 | 1971 | | |
| |||
3166 | 3168 | | |
3167 | 3169 | | |
3168 | 3170 | | |
| 3171 | + | |
3169 | 3172 | | |
3170 | 3173 | | |
3171 | 3174 | | |
| |||
3810 | 3813 | | |
3811 | 3814 | | |
3812 | 3815 | | |
3813 | | - | |
3814 | 3816 | | |
3815 | 3817 | | |
3816 | 3818 | | |
| |||
4098 | 4100 | | |
4099 | 4101 | | |
4100 | 4102 | | |
4101 | | - | |
| 4103 | + | |
4102 | 4104 | | |
4103 | 4105 | | |
4104 | 4106 | | |
| |||
4276 | 4278 | | |
4277 | 4279 | | |
4278 | 4280 | | |
| 4281 | + | |
4279 | 4282 | | |
4280 | 4283 | | |
4281 | 4284 | | |
| |||
4920 | 4923 | | |
4921 | 4924 | | |
4922 | 4925 | | |
4923 | | - | |
4924 | 4926 | | |
4925 | 4927 | | |
4926 | 4928 | | |
| |||
Lines changed: 75 additions & 7 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
46 | 46 | | |
47 | 47 | | |
48 | 48 | | |
| 49 | + | |
| 50 | + | |
| 51 | + | |
| 52 | + | |
| 53 | + | |
| 54 | + | |
| 55 | + | |
| 56 | + | |
| 57 | + | |
| 58 | + | |
| 59 | + | |
| 60 | + | |
| 61 | + | |
| 62 | + | |
| 63 | + | |
| 64 | + | |
| 65 | + | |
| 66 | + | |
| 67 | + | |
| 68 | + | |
| 69 | + | |
| 70 | + | |
| 71 | + | |
| 72 | + | |
| 73 | + | |
| 74 | + | |
| 75 | + | |
| 76 | + | |
| 77 | + | |
| 78 | + | |
| 79 | + | |
| 80 | + | |
| 81 | + | |
| 82 | + | |
| 83 | + | |
| 84 | + | |
| 85 | + | |
| 86 | + | |
| 87 | + | |
| 88 | + | |
| 89 | + | |
| 90 | + | |
| 91 | + | |
| 92 | + | |
| 93 | + | |
| 94 | + | |
49 | 95 | | |
50 | 96 | | |
51 | 97 | | |
| |||
242 | 288 | | |
243 | 289 | | |
244 | 290 | | |
| 291 | + | |
| 292 | + | |
| 293 | + | |
| 294 | + | |
| 295 | + | |
| 296 | + | |
| 297 | + | |
| 298 | + | |
| 299 | + | |
| 300 | + | |
| 301 | + | |
245 | 302 | | |
246 | 303 | | |
247 | 304 | | |
| |||
256 | 313 | | |
257 | 314 | | |
258 | 315 | | |
259 | | - | |
| 316 | + | |
260 | 317 | | |
261 | | - | |
262 | 318 | | |
263 | | - | |
264 | | - | |
| 319 | + | |
| 320 | + | |
| 321 | + | |
| 322 | + | |
| 323 | + | |
265 | 324 | | |
266 | 325 | | |
267 | 326 | | |
| |||
341 | 400 | | |
342 | 401 | | |
343 | 402 | | |
| 403 | + | |
| 404 | + | |
| 405 | + | |
344 | 406 | | |
345 | 407 | | |
| 408 | + | |
346 | 409 | | |
347 | 410 | | |
348 | 411 | | |
| 412 | + | |
349 | 413 | | |
350 | | - | |
351 | | - | |
352 | | - | |
| 414 | + | |
| 415 | + | |
| 416 | + | |
| 417 | + | |
| 418 | + | |
| 419 | + | |
| 420 | + | |
353 | 421 | | |
354 | 422 | | |
355 | 423 | | |
| |||
Lines changed: 10 additions & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
113 | 113 | | |
114 | 114 | | |
115 | 115 | | |
116 | | - | |
117 | | - | |
| 116 | + | |
| 117 | + | |
| 118 | + | |
| 119 | + | |
| 120 | + | |
| 121 | + | |
| 122 | + | |
| 123 | + | |
| 124 | + | |
| 125 | + | |
118 | 126 | | |
119 | 127 | | |
120 | 128 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
231 | 231 | | |
232 | 232 | | |
233 | 233 | | |
234 | | - | |
| 234 | + | |
| 235 | + | |
| 236 | + | |
235 | 237 | | |
236 | 238 | | |
237 | 239 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
11 | 11 | | |
12 | 12 | | |
13 | 13 | | |
14 | | - | |
| 14 | + | |
15 | 15 | | |
16 | 16 | | |
17 | 17 | | |
| |||
134 | 134 | | |
135 | 135 | | |
136 | 136 | | |
| 137 | + | |
| 138 | + | |
| 139 | + | |
137 | 140 | | |
138 | 141 | | |
139 | | - | |
140 | | - | |
141 | | - | |
142 | | - | |
143 | | - | |
144 | | - | |
145 | | - | |
146 | | - | |
147 | | - | |
148 | | - | |
149 | | - | |
| 142 | + | |
| 143 | + | |
| 144 | + | |
| 145 | + | |
| 146 | + | |
| 147 | + | |
| 148 | + | |
| 149 | + | |
| 150 | + | |
| 151 | + | |
| 152 | + | |
| 153 | + | |
| 154 | + | |
| 155 | + | |
| 156 | + | |
| 157 | + | |
| 158 | + | |
| 159 | + | |
| 160 | + | |
| 161 | + | |
| 162 | + | |
| 163 | + | |
| 164 | + | |
| 165 | + | |
| 166 | + | |
| 167 | + | |
| 168 | + | |
| 169 | + | |
| 170 | + | |
150 | 171 | | |
151 | | - | |
152 | | - | |
153 | | - | |
154 | | - | |
155 | | - | |
156 | | - | |
157 | | - | |
158 | | - | |
159 | | - | |
| 172 | + | |
| 173 | + | |
| 174 | + | |
| 175 | + | |
| 176 | + | |
| 177 | + | |
| 178 | + | |
| 179 | + | |
| 180 | + | |
160 | 181 | | |
161 | 182 | | |
162 | 183 | | |
| |||
0 commit comments