|
| 1 | +const sampleBasePath = `${import.meta.env?.BASE_URL ?? '/'}sample-scripts/`; |
| 2 | + |
1 | 3 | export const sampleScripts = Object.freeze([ |
2 | 4 | { |
3 | 5 | id: 'array-replacements', |
4 | 6 | title: 'Array Replacements', |
5 | 7 | family: 'lookup-array', |
6 | 8 | description: 'Large lookup array with string indirection.', |
7 | | - publicPath: '/sample-scripts/array_replacements.js', |
| 9 | + publicPath: `${sampleBasePath}array_replacements.js`, |
8 | 10 | }, |
9 | 11 | { |
10 | 12 | id: 'array-replacements-prototype-calls', |
11 | 13 | title: 'Array Replacements Prototype Calls', |
12 | 14 | family: 'lookup-array', |
13 | 15 | description: 'Lookup-array sample with prototype-call indirection.', |
14 | | - publicPath: '/sample-scripts/array_replacements_prototype_calls.js', |
| 16 | + publicPath: `${sampleBasePath}array_replacements_prototype_calls.js`, |
15 | 17 | }, |
16 | 18 | { |
17 | 19 | id: 'array-function-proxies', |
18 | 20 | title: 'Array Function Proxies', |
19 | 21 | family: 'proxy-calls', |
20 | 22 | description: 'Local proxies and indirection through helper wrappers.', |
21 | | - publicPath: '/sample-scripts/array_function_replacements_local_proxies.js', |
| 23 | + publicPath: `${sampleBasePath}array_function_replacements_local_proxies.js`, |
22 | 24 | }, |
23 | 25 | { |
24 | 26 | id: 'augmented-array-replacements', |
25 | 27 | title: 'Augmented Array Replacements', |
26 | 28 | family: 'augmented-array', |
27 | 29 | description: 'Array shuffling pattern that reveals more structures after cleanup.', |
28 | | - publicPath: '/sample-scripts/augmented_array_function_replacements.js', |
| 30 | + publicPath: `${sampleBasePath}augmented_array_function_replacements.js`, |
29 | 31 | }, |
30 | 32 | { |
31 | 33 | id: 'augmented-proxied-array', |
32 | 34 | title: 'Augmented Proxied Array', |
33 | 35 | family: 'mixed-obfuscation', |
34 | 36 | description: 'Proxy-heavy augmented array sample useful for ordering tests.', |
35 | | - publicPath: '/sample-scripts/augmented_proxied_array_function_replacements.js', |
| 37 | + publicPath: `${sampleBasePath}augmented_proxied_array_function_replacements.js`, |
36 | 38 | }, |
37 | 39 | { |
38 | 40 | id: 'obfuscator-io-not-boolean-tilde', |
39 | 41 | title: 'Obfuscator.io NotBooleanTilde', |
40 | 42 | family: 'obfuscator.io', |
41 | 43 | description: 'Obfuscator.io sample using not-boolean-tilde patterns.', |
42 | | - publicPath: '/sample-scripts/obfuscator.io-NotBooleanTilde.js', |
| 44 | + publicPath: `${sampleBasePath}obfuscator.io-NotBooleanTilde.js`, |
43 | 45 | }, |
44 | 46 | { |
45 | 47 | id: 'obfuscator-io-set-cookie', |
46 | 48 | title: 'Obfuscator.io SetCookie', |
47 | 49 | family: 'obfuscator.io', |
48 | 50 | description: 'Classic obfuscator.io anti-debug and indirection sample.', |
49 | | - publicPath: '/sample-scripts/obfuscator.io-setCookie.js', |
| 51 | + publicPath: `${sampleBasePath}obfuscator.io-setCookie.js`, |
50 | 52 | }, |
51 | 53 | { |
52 | 54 | id: 'caesar-plus', |
53 | 55 | title: 'Caesar Plus', |
54 | 56 | family: 'caesar-plus', |
55 | 57 | description: 'Caesar-style sample for processor-oriented structure discovery.', |
56 | | - publicPath: '/sample-scripts/caesar_plus.js', |
| 58 | + publicPath: `${sampleBasePath}caesar_plus.js`, |
57 | 59 | }, |
58 | 60 | ]); |
59 | 61 |
|
|
0 commit comments