Compare commits
718 Commits
c91e735e9a
...
v8.13.142-
| Author | SHA256 | Date | |
|---|---|---|---|
|
c42a39b757
|
|||
|
131b29e8b6
|
|||
|
faaa4db9f3
|
|||
|
582a110f04
|
|||
|
f61b149ab5
|
|||
|
51556707e2
|
|||
|
d8458b7220
|
|||
|
d31654a9ac
|
|||
|
b7760d5868
|
|||
|
c68a163982
|
|||
|
c7dd4c40cd
|
|||
|
e319a049de
|
|||
|
d1616934af
|
|||
|
14f1b99268
|
|||
|
147b54450f
|
|||
|
a8a27980eb
|
|||
|
d52df34b7b
|
|||
|
70f42be6ec
|
|||
|
8ce7830013
|
|||
|
746792cba2
|
|||
|
675649c646
|
|||
|
64275013c0
|
|||
|
54b153ba76
|
|||
|
bf7d616ea6
|
|||
|
9d235a427e
|
|||
|
2ffb74a408
|
|||
|
a4da5a6991
|
|||
|
aeea58ff84
|
|||
|
9a06c569f1
|
|||
|
40ab6fb578
|
|||
|
5b843d6e59
|
|||
|
18c60ce260
|
|||
|
11952e0621
|
|||
|
cb490632c4
|
|||
|
83fa76d4aa
|
|||
|
1813ae3774
|
|||
|
c4fc603d5b
|
|||
|
a9182d59f6
|
|||
|
db9dca9fa2
|
|||
|
cae8d68ecc
|
|||
|
9688142245
|
|||
|
f36de4a5b4
|
|||
|
5d00daf2ae
|
|||
|
175af760bc
|
|||
|
c60e138b27
|
|||
|
2d76fca675
|
|||
|
a44bd771d3
|
|||
|
1857d730e2
|
|||
|
b1243bdf97
|
|||
|
c8053082fd
|
|||
|
779c830111
|
|||
|
d6fdcacc9c
|
|||
|
3b89515b70
|
|||
|
97af826d5e
|
|||
|
584077e1c0
|
|||
|
c8791a9221
|
|||
|
b577201cc3
|
|||
|
eca769a7df
|
|||
|
b51049eb8e
|
|||
|
474b34afd3
|
|||
|
ca5cbbf323
|
|||
|
38a6fe4a2c
|
|||
|
b140f0e03e
|
|||
|
7060f945c1
|
|||
|
3e07d26cc6
|
|||
|
78f835f96e
|
|||
|
d3f9bec31c
|
|||
|
e682b6ac17
|
|||
|
3b1ab56d2c
|
|||
|
195b9a9c91
|
|||
|
fc4aa8d23f
|
|||
|
1b883619e7
|
|||
|
fc719ebfa9
|
|||
|
353d4cf7df
|
|||
|
66a2dd465e
|
|||
|
ef486ce7e5
|
|||
|
1cefc27d54
|
|||
|
7c0a3238a7
|
|||
|
242f0a0159
|
|||
|
11d1e529a9
|
|||
|
fd2357998b
|
|||
|
a5bcb4bb17
|
|||
|
4a985e1c81
|
|||
|
c60d4e1742
|
|||
|
0c4060fe5d
|
|||
|
f8d84b3585
|
|||
|
306d08ff87
|
|||
|
cd36d382bb
|
|||
|
0aca2331de
|
|||
|
77c1753d02
|
|||
|
ad30f41516
|
|||
|
7cba3e3531
|
|||
|
44aa77969f
|
|||
|
117959234e
|
|||
|
4bc332249c
|
|||
|
a536c4da96
|
|||
|
95835f1e15
|
|||
|
68c803550b
|
|||
|
9466395273
|
|||
|
181b73b04c
|
|||
|
7f678baa64
|
|||
|
1d711ea816
|
|||
|
9e66e27eae
|
|||
|
9a72da4e97
|
|||
|
fda63adb9c
|
|||
|
368d523f95
|
|||
|
e00c6e8900
|
|||
|
02f56b725f
|
|||
|
a475cc45a3
|
|||
|
5d64de95bc
|
|||
|
d313ae0b51
|
|||
|
edc59d362f
|
|||
|
eb90a815e8
|
|||
|
6f1793f2ac
|
|||
|
2a4d5e5b2e
|
|||
|
f7a7d1cff0
|
|||
|
40b3fb8ff7
|
|||
|
636c34cee5
|
|||
|
47ebdf7ed0
|
|||
|
61d9bf1510
|
|||
|
bd77170cf9
|
|||
|
49c6277efa
|
|||
|
d55f420c35
|
|||
|
af84d5292b
|
|||
|
53642d6115
|
|||
|
7fab4a183c
|
|||
|
c514634dd4
|
|||
|
32f1b05181
|
|||
|
1a2d1a3ae1
|
|||
|
5fcd2ebf42
|
|||
|
7168374797
|
|||
|
720eede478
|
|||
|
036fefdd3e
|
|||
|
2bcbdf8716
|
|||
|
ffecfcdc50
|
|||
|
a51e37b648
|
|||
|
0f8b894e40
|
|||
|
ec171888f7
|
|||
|
d046770aeb
|
|||
|
63502787c0
|
|||
|
a96af3ff06
|
|||
|
3c2c899403
|
|||
|
e966a899c7
|
|||
|
9b28418860
|
|||
|
40d81b51f9
|
|||
|
ac0560714b
|
|||
|
7f35d1ab38
|
|||
|
ec6e791b9d
|
|||
|
f35e3bff4f
|
|||
|
22d6c9a061
|
|||
|
e3206cc4be
|
|||
|
3e5ade4758
|
|||
|
3d79ff973f
|
|||
|
08653b1398
|
|||
|
440a393c67
|
|||
|
c1715f896f
|
|||
|
499bfe9c86
|
|||
|
6b397e27b1
|
|||
|
0da89626e6
|
|||
|
9c59edb3cb
|
|||
|
e0b1300538
|
|||
|
d5a3b6eca5
|
|||
|
fbc6f9e9a9
|
|||
|
bbc7fcfe56
|
|||
|
7d97dfd1b4
|
|||
|
76b3c4d49e
|
|||
|
8da33a5e38
|
|||
|
1330ed9cc9
|
|||
|
25361c66bf
|
|||
|
e52231a865
|
|||
|
5decedf83c
|
|||
|
003790123e
|
|||
|
2d3d8339de
|
|||
|
c774974171
|
|||
|
10204504ae
|
|||
|
00bd9ea193
|
|||
|
dc6f9b0d7b
|
|||
|
82b9f7395c
|
|||
|
5c16a5a097
|
|||
|
0ba66ee264
|
|||
|
f079c2fa48
|
|||
|
5aaeb98261
|
|||
|
250f4ba671
|
|||
|
b466852bca
|
|||
|
2dae84270a
|
|||
|
1872d761af
|
|||
|
d5f652b059
|
|||
|
ecdc4ec317
|
|||
|
ccaf53e6cd
|
|||
|
a84acdd685
|
|||
|
09c4125ed2
|
|||
|
4762db1926
|
|||
|
862e8e75bd
|
|||
|
661cbbdb32
|
|||
|
dd2c6e0546
|
|||
|
ab75649720
|
|||
|
c23a3708e8
|
|||
|
ac8d84eab0
|
|||
|
5686130913
|
|||
|
5b1ed48c23
|
|||
|
25b69d0434
|
|||
|
2cc84b008d
|
|||
|
553ca676c3
|
|||
|
cf77d21778
|
|||
|
b4ed802668
|
|||
|
f34c8c62d4
|
|||
|
90565fe3b6
|
|||
|
62c2c971bd
|
|||
|
f56d2d3215
|
|||
|
caf4164365
|
|||
|
66700a7518
|
|||
|
db5cefa913
|
|||
|
963318abd2
|
|||
|
549fda3560
|
|||
|
ad06d09847
|
|||
|
76281b4579
|
|||
|
0dbe1d2dbe
|
|||
|
cf6a3b32c0
|
|||
|
ba72633635
|
|||
|
d73efb3a89
|
|||
|
29b5abb594
|
|||
|
ad9a7be0c0
|
|||
|
4f990ff360
|
|||
|
f5df55c0d9
|
|||
|
78062fb361
|
|||
|
339220306c
|
|||
|
10220e2c0e
|
|||
|
58c76cb573
|
|||
|
2ebeb5dc35
|
|||
|
c36bc94cd6
|
|||
|
c3943a7a6c
|
|||
|
4ff33b1700
|
|||
|
5b727926d5
|
|||
|
6bd586d85d
|
|||
|
3e258fed6c
|
|||
|
9486dc970e
|
|||
|
97799cc705
|
|||
|
7b39974ce3
|
|||
|
9f79c96627
|
|||
|
3ee781bc2b
|
|||
|
10b17e059c
|
|||
|
dc7d8946a1
|
|||
|
45390ab73a
|
|||
|
c53fe4cf92
|
|||
|
527d9f6e48
|
|||
|
8fcc130464
|
|||
|
4ed5de03e8
|
|||
|
939766bcbb
|
|||
|
bc4ca368cd
|
|||
|
dbb8cc9967
|
|||
|
bcfa4b471d
|
|||
|
e2982840e0
|
|||
|
5af5b079c8
|
|||
|
dbce974409
|
|||
|
690dcccf98
|
|||
|
ec99539898
|
|||
|
df50b393ca
|
|||
|
527262c640
|
|||
|
42ea94595d
|
|||
|
79c7b090ac
|
|||
|
068ebb1065
|
|||
|
4ea400761d
|
|||
|
7d1e5d8523
|
|||
|
10101af2ee
|
|||
|
9b0b2db4d6
|
|||
|
3e7124c5b0
|
|||
|
e72ef95b86
|
|||
|
78644a6e2c
|
|||
|
d83e3da729
|
|||
|
cd13f2a6ca
|
|||
|
2661f89f11
|
|||
|
1500c5ca91
|
|||
|
c7a2e9bfa9
|
|||
|
8b9306f5e5
|
|||
|
992d593210
|
|||
|
43f86718a7
|
|||
|
d3242a7b5d
|
|||
|
f415c7aef5
|
|||
|
d1a643ef59
|
|||
|
9ceab388ea
|
|||
|
2bf021a9f1
|
|||
|
7389cf0509
|
|||
|
241b651f2f
|
|||
|
675817813b
|
|||
|
eb668f112c
|
|||
|
a0140a7b53
|
|||
|
c969ed6e88
|
|||
|
b36bf4fe5f
|
|||
|
fe3696c4e8
|
|||
|
05ba3be592
|
|||
|
834a924080
|
|||
|
4c552f2ecc
|
|||
|
553db82ad7
|
|||
|
960db79e56
|
|||
|
3b5ba919d2
|
|||
|
2f4ce03347
|
|||
|
1d095efce3
|
|||
|
f12abfef69
|
|||
|
67d443b695
|
|||
|
4445a0ae5c
|
|||
|
160fc4bc38
|
|||
|
ee8e2bce5c
|
|||
|
90e2fd48b8
|
|||
|
fd406a6628
|
|||
|
2c4a9c95c6
|
|||
|
898ed7d599
|
|||
|
07686fd15a
|
|||
|
5bd0c517a2
|
|||
|
f6f1d04a09
|
|||
|
8f3715ff74
|
|||
|
bf2252fd66
|
|||
|
976d95397c
|
|||
|
bfa2263198
|
|||
|
3c57dfcd08
|
|||
|
7a1f51e72e
|
|||
|
2d838a5b48
|
|||
|
a77e8e2204
|
|||
|
db1ce0cdbd
|
|||
|
dda53a41aa
|
|||
|
844981489a
|
|||
|
bcf924a4b7
|
|||
|
70329077a3
|
|||
|
2ad5087b1e
|
|||
|
2631b86196
|
|||
|
fd63ef798b
|
|||
|
98ceb5db1a
|
|||
|
4129d1ef2b
|
|||
|
f6a2c5ad49
|
|||
|
e8161fdc2d
|
|||
|
7b79ef1237
|
|||
|
9143b7800b
|
|||
|
0f10a9c271
|
|||
|
4f7131ca9c
|
|||
|
70d127dd4c
|
|||
|
d183dab1a3
|
|||
|
593faf92b8
|
|||
|
ff1a3390ec
|
|||
|
3177e1ff40
|
|||
|
e8e2fa0182
|
|||
|
dfd59577b2
|
|||
|
c2d0839cd2
|
|||
|
f047832cdc
|
|||
|
668ab7ce9d
|
|||
|
972749b607
|
|||
|
4b3918e58d
|
|||
|
55c27550c2
|
|||
|
dcb05605d6
|
|||
|
6ebf75a91b
|
|||
|
00c3853d4e
|
|||
|
1411be304d
|
|||
|
7459585d20
|
|||
|
df806d086f
|
|||
|
4b70ca7056
|
|||
|
44c3aef43d
|
|||
|
81f3a89ae5
|
|||
|
d0a38a82b8
|
|||
|
73d826ca2b
|
|||
|
87905d693c
|
|||
|
11e6b58f21
|
|||
|
27b59bad99
|
|||
|
a96d38fe46
|
|||
|
0cd9e75b68
|
|||
|
a5db5044f6
|
|||
|
5a4570ec46
|
|||
|
5e4bc99e5a
|
|||
|
e9b21a2b5b
|
|||
|
4bae828016
|
|||
|
67ebcfb388
|
|||
|
53e4f5e2e3
|
|||
|
adbf2d0dfd
|
|||
|
8fb023e43b
|
|||
|
1276b4fae7
|
|||
|
4b6c7cc2d8
|
|||
|
34dda8c8dd
|
|||
|
a5a5855507
|
|||
|
c3f4e0ba0a
|
|||
|
44c56be9d2
|
|||
|
9657a454c9
|
|||
|
577b7d16dd
|
|||
|
e4126f6995
|
|||
|
144d0ca2e9
|
|||
|
b8fe187cbf
|
|||
|
3cc26e2d2b
|
|||
|
43ec5f3493
|
|||
|
aa2f51b059
|
|||
|
ce632c3b3e
|
|||
|
2bfdf5fa42
|
|||
|
3700a1ad6c
|
|||
|
250b8ba0c6
|
|||
|
8d598d7d69
|
|||
|
c4b0e44d99
|
|||
|
4e76d9665a
|
|||
|
8a65565e5c
|
|||
|
a03d75879f
|
|||
|
29a5ff5c9e
|
|||
|
84f7014699
|
|||
|
6136da5631
|
|||
|
2e24d9d814
|
|||
|
a992311235
|
|||
|
8785b820af
|
|||
|
51745e8f82
|
|||
|
c04e89a3c1
|
|||
|
9aa98d1e46
|
|||
|
1c0cf0ce8c
|
|||
|
8d40f95c16
|
|||
|
8c05da4692
|
|||
|
dd4968c745
|
|||
|
aaf14e6204
|
|||
|
247b9af51b
|
|||
|
f40b1c6f2d
|
|||
|
742d0579d7
|
|||
|
3e5681cb90
|
|||
|
c21a25f938
|
|||
|
a5552f7079
|
|||
|
999fa7e11e
|
|||
|
7d8bab47ff
|
|||
|
6e33d74922
|
|||
|
b718b1e8c8
|
|||
|
c7d5407119
|
|||
|
2f25ad8e31
|
|||
|
ec5f343bfa
|
|||
|
22220bb3e0
|
|||
|
ad7a12ea92
|
|||
|
03f0b4df09
|
|||
|
0ef7fcb146
|
|||
|
ea2a7627e2
|
|||
|
b38e0c8476
|
|||
|
8409a8eb8a
|
|||
|
2b73132851
|
|||
|
1769e13708
|
|||
|
7eb8fb8754
|
|||
|
1fda52e948
|
|||
|
6d12da9566
|
|||
|
2b8deafabc
|
|||
|
3a8e624f57
|
|||
|
eac8f62459
|
|||
|
fadece63ca
|
|||
|
68eb879c8a
|
|||
|
64689d00b2
|
|||
|
7172b4fee9
|
|||
|
ec6066f620
|
|||
|
e164a039fa
|
|||
|
87b23a87a0
|
|||
|
4be9861403
|
|||
|
3913af49e3
|
|||
|
7aa82e060b
|
|||
|
9d40681c01
|
|||
|
c5ddadc93e
|
|||
|
77b73f8c5f
|
|||
|
da8cf0287d
|
|||
|
301513c07e
|
|||
|
31ece936c9
|
|||
|
a34dbb41da
|
|||
|
bc58199d11
|
|||
|
7d6a048f17
|
|||
|
c0ea15d1b5
|
|||
|
5345c44493
|
|||
|
3ce250c1f1
|
|||
|
52fecb8b6f
|
|||
|
5175c8245a
|
|||
|
680ce149d7
|
|||
|
a37ef3e143
|
|||
|
77fd128dbc
|
|||
|
70a97b02fa
|
|||
|
e42acb0bff
|
|||
|
e079067cb0
|
|||
|
766108d48d
|
|||
|
28d89d6693
|
|||
|
1282d40191
|
|||
|
7e065c9e5d
|
|||
|
4bbb4ead30
|
|||
|
73cd161efd
|
|||
|
a3862e3961
|
|||
|
9d1b80d648
|
|||
|
f0b02ed158
|
|||
|
8256633e5a
|
|||
|
dc5048fb49
|
|||
|
fec771291f
|
|||
|
9fb432ed59
|
|||
|
57cf13d25f
|
|||
|
1a5ae42516
|
|||
|
2ed84cac89
|
|||
|
87203e343f
|
|||
|
b4d3459f4a
|
|||
|
b3c74ef219
|
|||
|
c18f630760
|
|||
|
65c921b172
|
|||
|
a35c93e39e
|
|||
|
e59bbfd2ec
|
|||
|
ccae4a2cba
|
|||
|
187482e85d
|
|||
|
893fd8b1c2
|
|||
|
0dfda09473
|
|||
|
2e3c753483
|
|||
|
4552a101f5
|
|||
|
e3c959a6f7
|
|||
|
fd4bd7aa31
|
|||
|
f6d617ac5a
|
|||
|
ddd5aa3b49
|
|||
|
86068a6b7e
|
|||
|
31eb50342a
|
|||
|
6d2025eb40
|
|||
|
6b9b533b52
|
|||
|
a54f75d406
|
|||
|
d6115b90b5
|
|||
|
e6920e567a
|
|||
|
3ad1726770
|
|||
|
ac579fd862
|
|||
|
b34344ec52
|
|||
|
096f06ce8d
|
|||
|
88df9116cf
|
|||
|
ac0c4a113f
|
|||
|
e6187d42d4
|
|||
|
dddd3121b8
|
|||
|
6dde775de7
|
|||
|
972a55a0fd
|
|||
|
2c14afded0
|
|||
|
6a03ff4c11
|
|||
|
328c58335b
|
|||
|
e0530bbef4
|
|||
|
5eaeb97716
|
|||
|
174cc1da8d
|
|||
|
a568fae68d
|
|||
|
1a4a26c4af
|
|||
|
9fb636b87c
|
|||
|
a5219c6754
|
|||
|
96504a40fb
|
|||
|
661ae7cb7f
|
|||
|
813229d505
|
|||
|
1edb11ac9a
|
|||
|
a71cfe67b4
|
|||
|
78687ffa78
|
|||
|
3695b2d305
|
|||
|
25669a0253
|
|||
|
614284e025
|
|||
|
bf7254ecc3
|
|||
|
fcf27c1661
|
|||
|
8534849ec9
|
|||
|
4e3ac644f1
|
|||
|
0a4a2c4149
|
|||
|
c359695199
|
|||
|
c067ddbda5
|
|||
|
10786fdb9b
|
|||
|
834ea8798e
|
|||
|
4c5bc32cae
|
|||
|
43e333fa8b
|
|||
|
5e45fd1cf7
|
|||
|
f71bd4931b
|
|||
|
f6f2ad06e1
|
|||
|
4e6cf1973a
|
|||
|
a64b388193
|
|||
|
ec0ad7e43c
|
|||
|
5348b0c969
|
|||
|
efe189a3db
|
|||
|
88e489463d
|
|||
|
2d1d029a79
|
|||
|
595bc5b5db
|
|||
|
c3a67f3d41
|
|||
|
a0d6e1a29c
|
|||
|
645952ec90
|
|||
|
c0166be195
|
|||
|
81f6c797b1
|
|||
|
8c5d45515d
|
|||
|
d914111ebe
|
|||
|
5f1c26d6ff
|
|||
|
7e9bf2047b
|
|||
|
75b80cf71e
|
|||
|
6c0c6524ef
|
|||
|
7fadba9cc2
|
|||
|
291cbe267b
|
|||
|
5d331772b8
|
|||
|
db073e5b90
|
|||
|
87096d41fd
|
|||
|
d2b97771c4
|
|||
|
eb865fe402
|
|||
|
21c608b7d9
|
|||
|
f7fd74226f
|
|||
|
3210601f48
|
|||
|
274ed71e38
|
|||
|
e489cadff4
|
|||
|
671146bba6
|
|||
|
1cb4a9610b
|
|||
|
0854f6dfc3
|
|||
|
77ad158da0
|
|||
|
2632755c2c
|
|||
|
ef8fbbc0dc
|
|||
|
24454656a9
|
|||
|
39c7d4cfe3
|
|||
|
2a9c358c84
|
|||
|
1b955288ce
|
|||
|
a86bac8963
|
|||
|
8dc2bc97cd
|
|||
|
f4ab7e31aa
|
|||
|
d89d392f2b
|
|||
|
76c89ceb6e
|
|||
|
45892b2b30
|
|||
|
14654df207
|
|||
|
8262d183a8
|
|||
|
19c62fc004
|
|||
|
93e672b8e9
|
|||
|
419ec0d657
|
|||
|
fcfebca037
|
|||
|
6e2a6ef755
|
|||
|
44ba715e79
|
|||
|
20328492d5
|
|||
|
625eedffa8
|
|||
|
764c7ea85b
|
|||
|
d9fa7301fe
|
|||
|
06b08ed606
|
|||
|
4c8c2c9454
|
|||
|
6b05aeac7b
|
|||
|
404ed4926f
|
|||
|
7647c935c7
|
|||
|
81ce39943d
|
|||
|
025dc110a0
|
|||
|
be1af2bbfe
|
|||
|
cd65d2035f
|
|||
|
e6edc3c4fb
|
|||
|
9d76712941
|
|||
|
33c0515dbf
|
|||
|
ea76e9d5cb
|
|||
|
6e1cf484ee
|
|||
|
d7bc22b7ff
|
|||
|
4790e545ea
|
|||
|
f98086a67d
|
|||
|
e7d304e85b
|
|||
|
e3326bb442
|
|||
|
aadec811ef
|
|||
|
4663ab7fdd
|
|||
|
0eb36a4e28
|
|||
|
57be5ea4c8
|
|||
|
1993b9ec05
|
|||
|
fa562c0b15
|
|||
|
8e81a36d96
|
|||
|
d5efa52d1f
|
|||
|
5e06f31310
|
|||
|
c26eb3a798
|
|||
|
c2f934dd72
|
|||
|
589591dceb
|
|||
|
2541f0eaff
|
|||
|
ebc61630d0
|
|||
|
a38f23e34a
|
|||
|
5a2900fa71
|
|||
|
c425fe79e5
|
|||
|
939870edb7
|
|||
|
707b26064b
|
|||
|
60a920aa1e
|
|||
|
43dd6a49d5
|
|||
|
aaaf3da200
|
|||
|
ceff176d96
|
|||
|
9050c9123d
|
|||
|
cd76bb5aaf
|
|||
|
ca8fb28d7a
|
|||
|
a27e60913d
|
|||
|
204707fd91
|
|||
|
3dea6d015a
|
|||
|
cf2e2af026
|
|||
|
fdb172ff7c
|
|||
|
79d66d3995
|
|||
|
0118990cc7
|
|||
|
983fef800d
|
|||
|
897d308393
|
|||
|
bfb6135b20
|
|||
|
0fb2bdb31a
|
|||
|
260a058baf
|
|||
|
ebf6e8b01f
|
|||
|
3c53f59f1b
|
|||
|
675bf147cb
|
|||
|
7733103ac9
|
|||
|
efbcb45812
|
|||
|
dcb394277c
|
|||
|
158c49ddec
|
|||
|
d0a737e4c8
|
|||
|
e01205651e
|
|||
|
8e8749926e
|
|||
|
4e82a85ff0
|
|||
|
7b7ecdfc5e
|
|||
|
f50ee876ed
|
|||
|
e84bc83964
|
|||
|
64046d3aaa
|
|||
|
125e67e841
|
|||
|
41768c3c36
|
|||
|
0ee9157152
|
|||
|
3c6a83fdb0
|
|||
|
b322a73154
|
|||
|
77be71fd2a
|
|||
|
60e0bad88a
|
|||
|
5892d7884f
|
|||
|
299c85669a
|
|||
|
94310a27a8
|
|||
|
b19f07cfb6
|
|||
|
48740c7485
|
|||
|
715d5eded7
|
|||
|
cba95cca4f
|
|||
|
4e18615d46
|
|||
|
b25539f75c
|
|||
|
cc6b2c44c8
|
|||
|
87fd16b02d
|
|||
|
498606ba87
|
|||
|
ad6e721898
|
|||
|
a0de4ba074
|
|||
|
3ab12acc55
|
|||
|
bedb7fdca6
|
|||
|
da86233cad
|
|||
|
bcebd53470
|
|||
|
5a14d3014c
|
|||
|
22a2715e63
|
|||
|
5585c99ab4
|
|||
|
9509ae4e75
|
|||
|
2b0794e00f
|
|||
|
03f9ca44c6
|
|||
|
210d94492f
|
|||
|
0e2fe01b16
|
|||
|
aaabcf44e3
|
|||
|
ac3c5ed628
|
|||
|
eaa28163f7
|
|||
|
33cdeb3e2a
|
|||
|
05dbf04ef5
|
142
.archive/.0000_lib_usage.sh
Normal file
142
.archive/.0000_lib_usage.sh
Normal file
@@ -0,0 +1,142 @@
|
|||||||
|
#!/bin/bash
|
||||||
|
# SPDX-Version: 3.0
|
||||||
|
# SPDX-CreationInfo: 2025-05-05; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
|
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
||||||
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
|
# SPDX-FileType: SOURCE
|
||||||
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
|
# SPDX-PackageName: CISS.debian.live.builder
|
||||||
|
# SPDX-Security-Contact: security@coresecret.eu
|
||||||
|
|
||||||
|
#######################################
|
||||||
|
# Usage Wrapper CISS.debian.live.builder
|
||||||
|
# Globals:
|
||||||
|
# none
|
||||||
|
# Arguments:
|
||||||
|
# $0: Script name
|
||||||
|
#######################################
|
||||||
|
usage() {
|
||||||
|
clear
|
||||||
|
cat << EOF
|
||||||
|
$(echo -e "\e[92mCISS.debian.live.builder\e[0m")
|
||||||
|
$(echo -e "\e[92mMaster V8.13.142.2025.10.14\e[0m")
|
||||||
|
$(echo -e "\e[92mA lightweight Shell Wrapper for building a hardened Debian Live ISO Image.\e[0m")
|
||||||
|
|
||||||
|
$(echo -e "\e[97m(c) Marc S. Weidner, 2018 - 2025\e[0m")
|
||||||
|
$(echo -e "\e[97m(p) Centurion Press, 2024 - 2025\e[0m")
|
||||||
|
|
||||||
|
"${0} <option>", where <option> is one or more of:
|
||||||
|
|
||||||
|
$(echo -e "\e[97m --help, -h\e[0m")
|
||||||
|
What you're looking at.
|
||||||
|
|
||||||
|
$(echo -e "\e[97m --autobuild=*, -a=*\e[0m")
|
||||||
|
Headless mode. Skip the dialog wrapper, provider note screen and interactive kernel
|
||||||
|
selector dialog. Change '*' to your desired Linux kernel and trim the
|
||||||
|
'linux-image-' string to select a specific kernel, e.g. '--autobuild=6.12.30+bpo-amd64'.
|
||||||
|
|
||||||
|
$(echo -e "\e[97m --architecture <STRING> one of <amd64 | arm64>\e[0m")
|
||||||
|
A string reflecting the architecture of the Live System.
|
||||||
|
MUST be provided.
|
||||||
|
|
||||||
|
$(echo -e "\e[97m --build-directory </path/to/build_directory>\e[0m")
|
||||||
|
Where the Debian Live Build Image should be generated.
|
||||||
|
MUST be provided.
|
||||||
|
|
||||||
|
$(echo -e "\e[97m --change-splash <STRING> one of <club | hexagon>\e[0m")
|
||||||
|
A string reflecting the GRub Boot Screen Splash you want to use.
|
||||||
|
If omitted defaults to "./.archive/background/club.png".
|
||||||
|
|
||||||
|
$(echo -e "\e[97m --cdi (Experimental Feature)\e[0m")
|
||||||
|
This option generates a boot menu entry to start the forthcoming
|
||||||
|
'CISS.debian.installer', which will be executed after
|
||||||
|
the system has successfully booted up.
|
||||||
|
|
||||||
|
$(echo -e "\e[97m --contact, -c\e[0m")
|
||||||
|
Displays contact information of the author.
|
||||||
|
|
||||||
|
$(echo -e "\e[97m --control <INTEGER>\e[0m")
|
||||||
|
An integer that reflects the version of your Live ISO Image.
|
||||||
|
MUST be provided.
|
||||||
|
|
||||||
|
$(echo -e "\e[97m --debug\e[0m")
|
||||||
|
Enables debug logging for the main program routine. Detailed logging
|
||||||
|
information are written to "/tmp/ciss_live_builder_$$.log"
|
||||||
|
|
||||||
|
$(echo -e "\e[97m --dhcp-centurion\e[0m")
|
||||||
|
If a DHCP lease is provided, the provider's nameserver will be overridden,
|
||||||
|
and only the hardened, privacy-focused Centurion DNS servers will be used:
|
||||||
|
- https://dns01.eddns.eu/
|
||||||
|
- https://dns02.eddns.de/
|
||||||
|
- https://dns03.eddns.eu/
|
||||||
|
|
||||||
|
$(echo -e "\e[97m --jump-host <IP | IP | ... >\e[0m")
|
||||||
|
Provide up to 10 IPs for /etc/host.allow whitelisting of SSH access.
|
||||||
|
Could be either IPv4 and / or IPv6 addresses and / or CCDIR notation.
|
||||||
|
If provided, than it MUST be a <SPACE> separated list.
|
||||||
|
IPv6 addresses MUST be encapsulated with [], e.g., [1234::abcd]/64.
|
||||||
|
|
||||||
|
$(echo -e "\e[97m --log-statistics-only\e[0m")
|
||||||
|
Provides statistic only after successful building a
|
||||||
|
CISS.debian.live-ISO. While enabling "--log-statistics-only"
|
||||||
|
the argument "--build-directory" MUST be provided while
|
||||||
|
all further options MUST be omitted.
|
||||||
|
|
||||||
|
$(echo -e "\e[97m --provider-netcup-ipv6\e[0m")
|
||||||
|
Activates IPv6 support for Netcup Root Server. One unique
|
||||||
|
IPv6 address MUST be provided in this case and MUST be encapsulated
|
||||||
|
with [], e.g., [1234::abcd].
|
||||||
|
|
||||||
|
$(echo -e "\e[97m --renice-priority <PRIORITY>\e[0m")
|
||||||
|
Reset the nice priority value of the script and all its children
|
||||||
|
to the desired <PRIORITY>. MUST be an integer (between "-19" and 19).
|
||||||
|
Negative (higher) values MUST be enclosed in double quotes '"'.
|
||||||
|
|
||||||
|
$(echo -e "\e[97m --reionice-priority <CLASS> <PRIORITY>\e[0m")
|
||||||
|
Reset the ionice priority value of the script and all its children
|
||||||
|
to the desired <CLASS>. MUST be an integer:
|
||||||
|
1: realtime
|
||||||
|
2: best-effort
|
||||||
|
3: idle
|
||||||
|
Defaults to '2'.
|
||||||
|
Whereas <PRIORITY> MUST be an integer as well between:
|
||||||
|
0: highest priority and
|
||||||
|
7: lowest priority.
|
||||||
|
Defaults to '4'.
|
||||||
|
A real-time I/O process can significantly slow down other processes
|
||||||
|
or even cause them to starve if it continuously requests I/O.
|
||||||
|
|
||||||
|
$(echo -e "\e[97m --root-password-file </path/to/password.txt>\e[0m")
|
||||||
|
Password file for 'root', if given, MUST be a string of 20 to 64 characters,
|
||||||
|
and MUST NOT contain the special character '"'.
|
||||||
|
If the argument is omitted, no further login authentication is required for
|
||||||
|
the local console. The root password is hashed with an 16 Byte '/dev/random'
|
||||||
|
generated SALT and SHA512 Hashing function and 8,388,608 rounds. Immediately
|
||||||
|
after Hash generation all Variables containing plain password fragments are
|
||||||
|
deleted. Password file SHOULD be '0400' and 'root:root' and is deleted without
|
||||||
|
further prompt after password hash has been successfully generated via:
|
||||||
|
'shred -vfzu 5 -f'.
|
||||||
|
No tracing of any plain text password fragment in any debug log.
|
||||||
|
|
||||||
|
$(echo -e "\e[97m --ssh-port <INTEGER>\e[0m")
|
||||||
|
The desired Port SSH should listen to.
|
||||||
|
If not provided defaults to Port 22.
|
||||||
|
|
||||||
|
$(echo -e "\e[97m --ssh-pubkey </path/to/.ssh/>\e[0m")
|
||||||
|
Imports the SSH Public Key(s) from the FILE 'authorized_keys' of the
|
||||||
|
specified PATH into the Live ISO. MUST be provided.
|
||||||
|
|
||||||
|
$(echo -e "\e[97m --version, -v\e[0m")
|
||||||
|
Displays version of ${0}.
|
||||||
|
|
||||||
|
$(echo -e "\e[93m💡 Notes:\e[0m")
|
||||||
|
🔵 You MUST be 'root' to run this script.
|
||||||
|
|
||||||
|
$(echo -e "\e[95m💷 Please consider donating to my work at:\e[0m")
|
||||||
|
$(echo -e "\e[95m🌐 https://coresecret.eu/spenden/ \e[0m")
|
||||||
|
|
||||||
|
EOF
|
||||||
|
}
|
||||||
|
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=sh
|
||||||
37
.archive/0003_install_backports.chroot
Normal file
37
.archive/0003_install_backports.chroot
Normal file
@@ -0,0 +1,37 @@
|
|||||||
|
#!/bin/bash
|
||||||
|
# SPDX-Version: 3.0
|
||||||
|
# SPDX-CreationInfo: 2025-05-05; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
|
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
||||||
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
|
# SPDX-FileType: SOURCE
|
||||||
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
|
# SPDX-PackageName: CISS.debian.live.builder
|
||||||
|
# SPDX-Security-Contact: security@coresecret.eu
|
||||||
|
set -Ceuo pipefail
|
||||||
|
|
||||||
|
printf "\e[95m++++ ++++ ++++ ++++ ++++ ++++ ++ 🧪 '%s' starting ... \e[0m\n" "${0}"
|
||||||
|
|
||||||
|
DEBIAN_FRONTEND=noninteractive \
|
||||||
|
apt-get update && \
|
||||||
|
DEBIAN_FRONTEND=noninteractive \
|
||||||
|
apt-get install -y --no-install-recommends \
|
||||||
|
-o Dpkg::Options::="--force-confdef" \
|
||||||
|
-o Dpkg::Options::="--force-confold" \
|
||||||
|
-t bookworm-backports \
|
||||||
|
btrfs-progs \
|
||||||
|
curl \
|
||||||
|
debootstrap \
|
||||||
|
iproute2 \
|
||||||
|
ncat \
|
||||||
|
nmap \
|
||||||
|
ssh \
|
||||||
|
systemd \
|
||||||
|
systemd-sysv \
|
||||||
|
whois
|
||||||
|
|
||||||
|
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ '%s' applied successfully. \e[0m\n" "${0}"
|
||||||
|
|
||||||
|
exit 0
|
||||||
|
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=sh
|
||||||
72
.archive/0005_tmpfile_dublette.chroot
Normal file
72
.archive/0005_tmpfile_dublette.chroot
Normal file
@@ -0,0 +1,72 @@
|
|||||||
|
#!/bin/bash
|
||||||
|
# SPDX-Version: 3.0
|
||||||
|
# SPDX-CreationInfo: 2025-10-11; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
|
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
||||||
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
|
# SPDX-FileType: SOURCE
|
||||||
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
|
# SPDX-PackageName: CISS.debian.live.builder
|
||||||
|
# SPDX-Security-Contact: security@coresecret.eu
|
||||||
|
set -Ceuo pipefail
|
||||||
|
|
||||||
|
printf "\e[95m++++ ++++ ++++ ++++ ++++ ++++ ++ 🧪 '%s' starting ... \e[0m\n" "${0}"
|
||||||
|
|
||||||
|
# Purpose: Copy vendor 'legacy.conf' to '/etc/tmpfiles.d' and drop duplicate '/run/lock' lines.
|
||||||
|
|
||||||
|
#######################################
|
||||||
|
# Simple error terminal logger.
|
||||||
|
# Arguments:
|
||||||
|
# None
|
||||||
|
#######################################
|
||||||
|
log() { printf '[tmpfiles-fix] %s\n' "$*" >&2; }
|
||||||
|
|
||||||
|
### Locate vendor 'legacy.conf' (The path can vary).
|
||||||
|
declare vendor=""
|
||||||
|
|
||||||
|
for p in /usr/lib/tmpfiles.d/legacy.conf /lib/tmpfiles.d/legacy.conf; do
|
||||||
|
|
||||||
|
if [[ -f "${p}" ]]; then vendor="${p}"; break; fi
|
||||||
|
|
||||||
|
done
|
||||||
|
|
||||||
|
if [[ -z "${vendor}" ]]; then
|
||||||
|
log "WARN: vendor legacy.conf not found; creating a minimal override"
|
||||||
|
install -D -m 0644 /dev/null /etc/tmpfiles.d/legacy.conf
|
||||||
|
|
||||||
|
else
|
||||||
|
|
||||||
|
install -D -m 0644 "${vendor}" /etc/tmpfiles.d/legacy.conf
|
||||||
|
|
||||||
|
fi
|
||||||
|
|
||||||
|
### Deduplicate: keep only the FIRST 'd /run/lock ' definition, drop subsequent ones.
|
||||||
|
# shellcheck disable=SC2155
|
||||||
|
declare tmpdir="$(mktemp -d)"
|
||||||
|
declare out="${tmpdir}/legacy.conf"
|
||||||
|
|
||||||
|
awk '
|
||||||
|
BEGIN{seen=0}
|
||||||
|
{
|
||||||
|
# Preserve everything by default
|
||||||
|
keep=1
|
||||||
|
# Match tmpfiles "d /run/lock ..." (allowing variable spacing and case of directive)
|
||||||
|
if ($1 ~ /^[dD]$/ && $2 == "/run/lock") {
|
||||||
|
if (seen==1) { keep=0 } else { seen=1 }
|
||||||
|
}
|
||||||
|
if (keep) print
|
||||||
|
}' /etc/tmpfiles.d/legacy.conf >| "${out}"
|
||||||
|
|
||||||
|
### Install the sanitized file atomically.
|
||||||
|
install -m 0644 -o root -g root "${out}" /etc/tmpfiles.d/legacy.conf
|
||||||
|
rm -rf -- "${tmpdir}"
|
||||||
|
|
||||||
|
log "Deduplicated /etc/tmpfiles.d/legacy.conf (kept only first /run/lock entry)."
|
||||||
|
|
||||||
|
command -v systemd-tmpfiles >/dev/null 2>&1 && systemd-tmpfiles --create --prefix /run/lock || true
|
||||||
|
|
||||||
|
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ '%s' applied successfully. \e[0m\n" "${0}"
|
||||||
|
|
||||||
|
exit 0
|
||||||
|
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=sh
|
||||||
@@ -2,41 +2,54 @@
|
|||||||
# SPDX-CreationInfo: 2025-05-05; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-CreationInfo: 2025-05-05; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
||||||
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
# SPDX-FileCopyrightText: 2024–2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-FileType: SOURCE
|
# SPDX-FileType: SOURCE
|
||||||
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
# SPDX-LicenseComment: This file is part of the CISS.hardened.installer framework.
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
# SPDX-PackageName: CISS.debian.live.builder
|
# SPDX-PackageName: CISS.debian.live.builder
|
||||||
# SPDX-Security-Contact: security@coresecret.eu
|
# SPDX-Security-Contact: security@coresecret.eu
|
||||||
✅
|
✅
|
||||||
🔧
|
❌
|
||||||
|
⚠️
|
||||||
|
🚫
|
||||||
|
🔐
|
||||||
|
🔒
|
||||||
🔑
|
🔑
|
||||||
|
✍️
|
||||||
🖥️
|
🖥️
|
||||||
|
🔄
|
||||||
|
🔁
|
||||||
|
🌌
|
||||||
|
🔵
|
||||||
|
💙
|
||||||
|
🔍
|
||||||
|
💡
|
||||||
|
🔧
|
||||||
🛠️
|
🛠️
|
||||||
|
🏗
|
||||||
|
⚙️
|
||||||
|
📐
|
||||||
|
🧪
|
||||||
|
📩
|
||||||
📥
|
📥
|
||||||
📦
|
📦
|
||||||
📑
|
📑
|
||||||
📂
|
📂
|
||||||
🔒
|
📀
|
||||||
🔐
|
|
||||||
⚙️
|
|
||||||
❌
|
|
||||||
🌌
|
|
||||||
🎉
|
🎉
|
||||||
🖥️
|
|
||||||
🔑
|
|
||||||
📂
|
|
||||||
📩
|
|
||||||
🔵
|
|
||||||
😺
|
😺
|
||||||
🧪
|
📉
|
||||||
📊
|
📊
|
||||||
🧾
|
🧾
|
||||||
📀
|
📋
|
||||||
📉
|
🕑
|
||||||
⏱
|
|
||||||
🧠
|
🧠
|
||||||
📅
|
📅
|
||||||
💙
|
🎯
|
||||||
🚫
|
🌐
|
||||||
|
🔗
|
||||||
|
💬
|
||||||
|
☢️
|
||||||
|
☣️
|
||||||
|
•
|
||||||
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=sh
|
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=sh
|
||||||
@@ -2,7 +2,7 @@
|
|||||||
# SPDX-CreationInfo: 2025-05-05; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-CreationInfo: 2025-05-05; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
||||||
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
# SPDX-FileCopyrightText: 2024–2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-FileType: SOURCE
|
# SPDX-FileType: SOURCE
|
||||||
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
@@ -25,6 +25,10 @@ charset = utf-8
|
|||||||
insert_final_newline = true
|
insert_final_newline = true
|
||||||
trim_trailing_whitespace = true
|
trim_trailing_whitespace = true
|
||||||
|
|
||||||
|
[{makefile,*.mk}]
|
||||||
|
indent_style = tab
|
||||||
|
tab_width = 8
|
||||||
|
|
||||||
[*.md]
|
[*.md]
|
||||||
end_of_line = lf
|
end_of_line = lf
|
||||||
# Markdown benefits from a final newline for POSIX tools
|
# Markdown benefits from a final newline for POSIX tools
|
||||||
|
|||||||
@@ -2,7 +2,7 @@
|
|||||||
# SPDX-CreationInfo: 2025-05-05; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-CreationInfo: 2025-05-05; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
||||||
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
# SPDX-FileCopyrightText: 2024–2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-FileType: SOURCE
|
# SPDX-FileType: SOURCE
|
||||||
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
@@ -12,9 +12,7 @@
|
|||||||
name: "Bug Report"
|
name: "Bug Report"
|
||||||
about: "Create a report to help us improve"
|
about: "Create a report to help us improve"
|
||||||
title: "[BUG | possible BUG]: "
|
title: "[BUG | possible BUG]: "
|
||||||
labels: "bug:to be reproduced,bug:needs triage/confirmation"
|
assignees: "MSW"
|
||||||
assignees: ""
|
|
||||||
---
|
|
||||||
body:
|
body:
|
||||||
# Instructions for the reporter
|
# Instructions for the reporter
|
||||||
- type: markdown
|
- type: markdown
|
||||||
@@ -27,7 +25,7 @@ body:
|
|||||||
attributes:
|
attributes:
|
||||||
label: "Version"
|
label: "Version"
|
||||||
description: "Which version are you running? Use `./ciss_live_builder.sh -v`."
|
description: "Which version are you running? Use `./ciss_live_builder.sh -v`."
|
||||||
placeholder: "e.g., Master V8.02.080.2025.05.19"
|
placeholder: "e.g., Master V8.13.142.2025.10.14"
|
||||||
validations:
|
validations:
|
||||||
required: true
|
required: true
|
||||||
|
|
||||||
|
|||||||
@@ -2,7 +2,7 @@
|
|||||||
# SPDX-CreationInfo: 2025-05-05; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-CreationInfo: 2025-05-05; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
||||||
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
# SPDX-FileCopyrightText: 2024–2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-FileType: SOURCE
|
# SPDX-FileType: SOURCE
|
||||||
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
@@ -12,7 +12,7 @@
|
|||||||
name: "Standard-PR"
|
name: "Standard-PR"
|
||||||
about: "Please answer the following questions before submitting the PR."
|
about: "Please answer the following questions before submitting the PR."
|
||||||
title: "[PR]: "
|
title: "[PR]: "
|
||||||
ref: "master"
|
assignees: "MSW"
|
||||||
body:
|
body:
|
||||||
- type: markdown
|
- type: markdown
|
||||||
attributes:
|
attributes:
|
||||||
@@ -48,8 +48,8 @@ body:
|
|||||||
options:
|
options:
|
||||||
- label: "My edits contain no tabs, use two-space indentation, and no trailing whitespace"
|
- label: "My edits contain no tabs, use two-space indentation, and no trailing whitespace"
|
||||||
- label: "I have read ~/docs/CONTRIBUTING.md and ~/docs/CODING_CONVENTION.md"
|
- label: "I have read ~/docs/CONTRIBUTING.md and ~/docs/CODING_CONVENTION.md"
|
||||||
- label: "I have tested this fix or improvement on ≥2 VMs without issues"
|
- label: "I have tested this fix or improvement on >=2 VMs without issues"
|
||||||
- label: "I have tested this new feature on ≥2 VMs with and without it to avoid side effects"
|
- label: "I have tested this new feature on >=2 VMs with and without it to avoid side effects"
|
||||||
- label: "Documentation and/or 'usage()' and/or 'arg_parser' have been updated for the new feature"
|
- label: "Documentation and/or 'usage()' and/or 'arg_parser' have been updated for the new feature"
|
||||||
- label: "I added myself to ~/docs/CREDITS.md (alphabetical) and updated ~/docs/CHANGELOG.md"
|
- label: "I added myself to ~/docs/CREDITS.md (alphabetical) and updated ~/docs/CHANGELOG.md"
|
||||||
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=yaml
|
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=yaml
|
||||||
|
|||||||
69
.gitea/TODO/dockerfile
Normal file
69
.gitea/TODO/dockerfile
Normal file
@@ -0,0 +1,69 @@
|
|||||||
|
# SPDX-Version: 3.0
|
||||||
|
# SPDX-CreationInfo: 2025-05-05; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
|
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
||||||
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
|
# SPDX-FileType: SOURCE
|
||||||
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
|
# SPDX-PackageName: CISS.debian.live.builder
|
||||||
|
# SPDX-Security-Contact: security@coresecret.eu
|
||||||
|
|
||||||
|
# Version Master V8.13.142.2025.10.14
|
||||||
|
|
||||||
|
FROM debian:bookworm
|
||||||
|
|
||||||
|
ENV DEBIAN_FRONTEND=noninteractive
|
||||||
|
|
||||||
|
RUN apt-get update -y \
|
||||||
|
&& apt-get upgrade -y \
|
||||||
|
&& apt-get install -y \
|
||||||
|
apt-transport-https \
|
||||||
|
apt-utils \
|
||||||
|
bash \
|
||||||
|
ca-certificates \
|
||||||
|
gnupg \
|
||||||
|
openssl \
|
||||||
|
sudo \
|
||||||
|
&& apt-get update -y \
|
||||||
|
&& apt-get upgrade -y \
|
||||||
|
&& apt-get clean \
|
||||||
|
&& apt-get autoremove --purge -y \
|
||||||
|
&& rm -rf /var/lib/apt/lists/*
|
||||||
|
|
||||||
|
RUN mkdir -p /etc/apt/sources.list.d && touch /etc/apt/sources.list.d/bookworm-backports.list \
|
||||||
|
&& echo 'deb https://deb.debian.org/debian bookworm-backports main' >| /etc/apt/sources.list.d/bookworm-backports.list \
|
||||||
|
&& apt-get update -y \
|
||||||
|
&& apt-get upgrade -y \
|
||||||
|
&& apt-get install -y --no-install-recommends \
|
||||||
|
autoconf \
|
||||||
|
automake \
|
||||||
|
build-essential \
|
||||||
|
cryptsetup \
|
||||||
|
curl \
|
||||||
|
debootstrap \
|
||||||
|
dosfstools \
|
||||||
|
efibootmgr \
|
||||||
|
gettext \
|
||||||
|
git \
|
||||||
|
haveged \
|
||||||
|
libtool \
|
||||||
|
live-build \
|
||||||
|
parted \
|
||||||
|
pkg-config \
|
||||||
|
ssh \
|
||||||
|
ssl-cert \
|
||||||
|
texinfo \
|
||||||
|
wget \
|
||||||
|
whois \
|
||||||
|
&& apt-get clean \
|
||||||
|
&& apt-get autoremove --purge -y \
|
||||||
|
&& rm -rf /var/lib/apt/lists/*
|
||||||
|
|
||||||
|
RUN useradd --create-home --shell /bin/bash runner
|
||||||
|
|
||||||
|
WORKDIR /home/runner
|
||||||
|
|
||||||
|
USER runner
|
||||||
|
|
||||||
|
ENTRYPOINT ["bash"]
|
||||||
@@ -1,169 +0,0 @@
|
|||||||
# SPDX-Version: 3.0
|
|
||||||
# SPDX-CreationInfo: 2025-05-05; WEIDNER, Marc S.; <msw@coresecret.dev>
|
|
||||||
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
|
||||||
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
|
||||||
# SPDX-FileCopyrightText: 2024–2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
|
||||||
# SPDX-FileType: SOURCE
|
|
||||||
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
|
||||||
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
|
||||||
# SPDX-PackageName: CISS.debian.live.builder
|
|
||||||
# SPDX-Security-Contact: security@coresecret.eu
|
|
||||||
|
|
||||||
name: Generating private Live ISO.
|
|
||||||
|
|
||||||
permissions:
|
|
||||||
contents: write
|
|
||||||
|
|
||||||
on:
|
|
||||||
push:
|
|
||||||
branches:
|
|
||||||
- master
|
|
||||||
paths:
|
|
||||||
- '.gitea/autobuild.yaml'
|
|
||||||
|
|
||||||
jobs:
|
|
||||||
generating-ciss-debian-live-iso:
|
|
||||||
runs-on: ubuntu-latest
|
|
||||||
|
|
||||||
### Run all steps inside Debian Bookworm
|
|
||||||
container:
|
|
||||||
image: debian:bookworm
|
|
||||||
options: --user root
|
|
||||||
|
|
||||||
steps:
|
|
||||||
- name: Preparing SSH Setup, SSH Deploy Key, Known Hosts, .config.
|
|
||||||
run: |
|
|
||||||
rm -rf ~/.ssh && mkdir -m700 ~/.ssh
|
|
||||||
|
|
||||||
### Private Key
|
|
||||||
echo "${{ secrets.SSH_MSW_DEPLOY_CORESECRET_DEV }}" >| ~/.ssh/id_ed25519
|
|
||||||
chmod 600 ~/.ssh/id_ed25519
|
|
||||||
|
|
||||||
### Scan git.coresecret.dev to fill ~/.ssh/known_hosts
|
|
||||||
ssh-keyscan -p 42842 git.coresecret.dev >| ~/.ssh/known_hosts
|
|
||||||
chmod 600 ~/.ssh/known_hosts
|
|
||||||
|
|
||||||
### Generate SSH Config for git.coresecret.dev Custom-Port
|
|
||||||
cat <<EOF >| ~/.ssh/config
|
|
||||||
Host git.coresecret.dev
|
|
||||||
HostName git.coresecret.dev
|
|
||||||
Port 42842
|
|
||||||
IdentityFile ~/.ssh/id_ed25519
|
|
||||||
StrictHostKeyChecking yes
|
|
||||||
UserKnownHostsFile ~/.ssh/known_hosts
|
|
||||||
EOF
|
|
||||||
chmod 600 ~/.ssh/config
|
|
||||||
|
|
||||||
### https://github.com/actions/checkout/issues/1843
|
|
||||||
- name: Using manual clone via SSH to circumvent Gitea SHA-256 object issues.
|
|
||||||
run: |
|
|
||||||
git clone --branch "${GITHUB_REF_NAME}" ssh://git@git.coresecret.dev:42842/msw/CISS.debian.live.builder.git .
|
|
||||||
git fetch --unshallow || echo "Nothing to fetch - already full clone."
|
|
||||||
env:
|
|
||||||
### GITHUB_REF_NAME contains the branch name from the push event.
|
|
||||||
GITHUB_REF_NAME: ${{ github.ref_name }}
|
|
||||||
|
|
||||||
- name: Cleaning workspace.
|
|
||||||
run: |
|
|
||||||
git reset --hard
|
|
||||||
git clean -fd
|
|
||||||
|
|
||||||
- name: Installing Debian Live-Build and Tools.
|
|
||||||
run: |
|
|
||||||
apt-get update
|
|
||||||
apt-get install -y live-build gnupg curl whois
|
|
||||||
|
|
||||||
- name: Importing "CI PGP DEPLOY ONLY" Key.
|
|
||||||
run: |
|
|
||||||
### GPG-Home relative to the Runner Workspace to avoid changing global files.
|
|
||||||
export GNUPGHOME="$(pwd)/.gnupg"
|
|
||||||
mkdir -m700 "${GNUPGHOME}"
|
|
||||||
echo "${{ secrets.PGP_MSW_DEPLOY_CORESECRET_DEV }}" >| ci-bot.sec.asc
|
|
||||||
gpg --batch --import ci-bot.sec.asc
|
|
||||||
### Trust the key automatically
|
|
||||||
KEY_ID=$(gpg --list-keys --with-colons | awk -F: '/^pub:/ {print $5}')
|
|
||||||
echo "trust-model always" >| "${GNUPGHOME}/gpg.conf"
|
|
||||||
|
|
||||||
- name: Configuring Git for signed CI DEPLOY commits.
|
|
||||||
run: |
|
|
||||||
export GNUPGHOME="$(pwd)/.gnupg"
|
|
||||||
git config user.name "Marc S. Weidner BOT"
|
|
||||||
git config user.email "msw+bot@coresecret.dev"
|
|
||||||
git config commit.gpgsign true
|
|
||||||
git config gpg.program gpg
|
|
||||||
git config gpg.format openpgp
|
|
||||||
|
|
||||||
- name: Preparing Build Environment.
|
|
||||||
run: |
|
|
||||||
rm -rf /opt/{config,livebuild}
|
|
||||||
mkdir -p /opt/{config,livebuild}
|
|
||||||
echo "${{ secrets.CISS_DLB_ROOT_PWD }}" >| /opt/config/password.txt
|
|
||||||
echo "${{ secrets.CISS_DLB_ROOT_SSH_PUBKEY }}" >| /opt/config/authorized_keys
|
|
||||||
chmod 0600 /opt/config/authorized_keys
|
|
||||||
|
|
||||||
- name: Starting CISS.debian.live.builder.
|
|
||||||
run: |
|
|
||||||
timestamp=$(date -u +"%Y_%m_%d_%H_%M_Z")
|
|
||||||
### Change "--autobuild=" to the specific kernel version you need: 6.12.22+bpo-amd64.
|
|
||||||
./ciss_live_builder.sh \
|
|
||||||
--autobuild=6.12.22+bpo-amd64 \
|
|
||||||
--architecture amd64 \
|
|
||||||
--build-directory /opt/livebuild \
|
|
||||||
--control "${timestamp}" \
|
|
||||||
--debug \
|
|
||||||
--dhcp-centurion \
|
|
||||||
--jump-host "${{ secrets.CISS_DLB_JUMP_HOSTS }}" \
|
|
||||||
--provider-netcup-ipv6 "${{ secrets.CISS_DLB_NETCUP_IPV6 }}" \
|
|
||||||
--renice-priority "-19" \
|
|
||||||
--reionice-priority 1 2 \
|
|
||||||
--root-password-file /opt/config/password.txt \
|
|
||||||
--ssh-port 4242 \
|
|
||||||
--ssh-pubkey /opt/config
|
|
||||||
|
|
||||||
- name: Uploading ISO to CenturionCloud "cloud.e2ee.li" via WebDAV
|
|
||||||
env:
|
|
||||||
WEBDAV_URL: "https://cloud.e2ee.li/remote.php/dav/files/runner/PUBLIC/CISS-live/NAME.iso"
|
|
||||||
WEBDAV_USER: ${{ secrets.NC_USER }}
|
|
||||||
WEBDAV_PASS: ${{ secrets.NC_PASS }}
|
|
||||||
run: |
|
|
||||||
### Remove old ISO if exists
|
|
||||||
curl -u "${WEBDAV_USER}:${WEBDAV_PASS}" -X DELETE "${WEBDAV_URL}" || true
|
|
||||||
### Upload new ISO
|
|
||||||
curl -u "${WEBDAV_USER}:${WEBDAV_PASS}" -T NAME.iso "${WEBDAV_URL}"
|
|
||||||
### Verify upload
|
|
||||||
HTTP_CODE=$(curl -o /dev/null -s -w "%{http_code}" -u "${WEBDAV_USER}:${WEBDAV_PASS}" "${WEBDAV_URL}")
|
|
||||||
if [ "$HTTP_CODE" -ne 200 ]; then
|
|
||||||
echo "Upload failed with HTTP status ${HTTP_CODE}"
|
|
||||||
exit 1
|
|
||||||
fi
|
|
||||||
echo "ISO successfully uploaded and verified."
|
|
||||||
|
|
||||||
- name: Generating Hash and Signing with Private Key
|
|
||||||
run: |
|
|
||||||
:
|
|
||||||
### TODO: Implement this function
|
|
||||||
|
|
||||||
- name: Generating Success Message to Push back into Repo
|
|
||||||
run: |
|
|
||||||
:
|
|
||||||
### TODO: Implement this function
|
|
||||||
|
|
||||||
- name: Stage generated files.
|
|
||||||
run: |
|
|
||||||
git add !!!!!!!!!!!!!
|
|
||||||
env:
|
|
||||||
GIT_SSH_COMMAND: "ssh -p 42842"
|
|
||||||
|
|
||||||
- name: Commit and Sign changes.
|
|
||||||
run: |
|
|
||||||
export GNUPGHOME="$(pwd)/.gnupg"
|
|
||||||
git commit -S -m "DEPLOY BOT: Auto-Generate LIVE ISO [skip ci]" || echo "No Changes, nothing to Sign or to Commit."
|
|
||||||
env:
|
|
||||||
GIT_SSH_COMMAND: "ssh -p 42842"
|
|
||||||
|
|
||||||
- name: Push back to Repository.
|
|
||||||
run: |
|
|
||||||
git push origin HEAD:${GITHUB_REF_NAME}
|
|
||||||
env:
|
|
||||||
GIT_SSH_COMMAND: "ssh -p 42842"
|
|
||||||
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=yaml
|
|
||||||
241
.gitea/TODO/render-md-to-html.yaml
Normal file
241
.gitea/TODO/render-md-to-html.yaml
Normal file
@@ -0,0 +1,241 @@
|
|||||||
|
# SPDX-Version: 3.0
|
||||||
|
# SPDX-CreationInfo: 2025-05-05; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
|
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
||||||
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
|
# SPDX-FileType: SOURCE
|
||||||
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
|
# SPDX-PackageName: CISS.debian.live.builder
|
||||||
|
# SPDX-Security-Contact: security@coresecret.eu
|
||||||
|
|
||||||
|
# Version Master V8.13.142.2025.10.14
|
||||||
|
|
||||||
|
name: 🔁 Render README.md to README.html.
|
||||||
|
|
||||||
|
permissions:
|
||||||
|
contents: write
|
||||||
|
|
||||||
|
on:
|
||||||
|
push:
|
||||||
|
branches:
|
||||||
|
- master
|
||||||
|
paths:
|
||||||
|
- "README.md"
|
||||||
|
- '.gitea/properties/lua/linkfix.lua'
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
render-md-to-html:
|
||||||
|
name: 🔁 Render README.md to README.html.
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
|
||||||
|
steps:
|
||||||
|
- name: ⚙️ Preparing SSH Setup, SSH Deploy Key, Known Hosts, .config.
|
||||||
|
shell: bash
|
||||||
|
run: |
|
||||||
|
set -euo pipefail
|
||||||
|
rm -rf ~/.ssh && mkdir -m700 ~/.ssh
|
||||||
|
|
||||||
|
### Private Key
|
||||||
|
echo "${{ secrets.SSH_MSW_DEPLOY_CORESECRET_DEV }}" >| ~/.ssh/id_ed25519
|
||||||
|
chmod 600 ~/.ssh/id_ed25519
|
||||||
|
|
||||||
|
### Scan git.coresecret.dev to fill ~/.ssh/known_hosts
|
||||||
|
ssh-keyscan -p 42842 git.coresecret.dev >| ~/.ssh/known_hosts
|
||||||
|
chmod 600 ~/.ssh/known_hosts
|
||||||
|
|
||||||
|
### Generate SSH Config for git.coresecret.dev Custom-Port
|
||||||
|
cat <<EOF >| ~/.ssh/config
|
||||||
|
Host git.coresecret.dev
|
||||||
|
HostName git.coresecret.dev
|
||||||
|
Port 42842
|
||||||
|
IdentityFile ~/.ssh/id_ed25519
|
||||||
|
StrictHostKeyChecking yes
|
||||||
|
UserKnownHostsFile ~/.ssh/known_hosts
|
||||||
|
EOF
|
||||||
|
chmod 600 ~/.ssh/config
|
||||||
|
|
||||||
|
### https://github.com/actions/checkout/issues/1843
|
||||||
|
- name: 🛠️ Using manual clone via SSH to circumvent Gitea SHA-256 object issues.
|
||||||
|
shell: bash
|
||||||
|
env:
|
||||||
|
### GITHUB_REF_NAME contains the branch name from the push event.
|
||||||
|
GITHUB_REF_NAME: ${{ github.ref_name }}
|
||||||
|
run: |
|
||||||
|
set -euo pipefail
|
||||||
|
git clone --branch "${GITHUB_REF_NAME}" ssh://git@git.coresecret.dev:42842/msw/CISS.debian.live.builder.git .
|
||||||
|
git fetch --unshallow || echo "Nothing to fetch - already full clone."
|
||||||
|
|
||||||
|
- name: 🛠️ Cleaning the workspace.
|
||||||
|
shell: bash
|
||||||
|
run: |
|
||||||
|
set -euo pipefail
|
||||||
|
git reset --hard
|
||||||
|
git clean -fd
|
||||||
|
|
||||||
|
- name: ⚙️ Importing the 'CI PGP DEPLOY ONLY' key.
|
||||||
|
shell: bash
|
||||||
|
run: |
|
||||||
|
set -euo pipefail
|
||||||
|
### GPG-Home relative to the Runner Workspace to avoid changing global files.
|
||||||
|
export GNUPGHOME="$(pwd)/.gnupg"
|
||||||
|
mkdir -m 700 "${GNUPGHOME}"
|
||||||
|
echo "${{ secrets.PGP_MSW_DEPLOY_CORESECRET_DEV }}" >| ci-bot.sec.asc
|
||||||
|
gpg --batch --import ci-bot.sec.asc
|
||||||
|
### Trust the key automatically
|
||||||
|
KEY_ID=$(gpg --list-keys --with-colons | awk -F: '/^pub:/ {print $5}')
|
||||||
|
echo "trust-model always" >| "${GNUPGHOME}/gpg.conf"
|
||||||
|
|
||||||
|
- name: ⚙️ Configuring Git for signed CI/DEPLOY commits.
|
||||||
|
shell: bash
|
||||||
|
run: |
|
||||||
|
set -euo pipefail
|
||||||
|
export GNUPGHOME="$(pwd)/.gnupg"
|
||||||
|
git config user.name "Marc S. Weidner BOT"
|
||||||
|
git config user.email "msw+bot@coresecret.dev"
|
||||||
|
git config commit.gpgsign true
|
||||||
|
git config gpg.program gpg
|
||||||
|
git config gpg.format openpgp
|
||||||
|
|
||||||
|
- name: ⚙️ Convert APT sources to HTTPS.
|
||||||
|
shell: bash
|
||||||
|
run: |
|
||||||
|
set -euo pipefail
|
||||||
|
sed -i 's|http://\(archive\.ubuntu\.com\|security\.ubuntu\.com\)|https://\1|g' /etc/apt/sources.list
|
||||||
|
sed -i 's|http://\(archive\.ubuntu\.com\|security\.ubuntu\.com\)|https://\1|g' /etc/apt/sources.list.d/*.list || true
|
||||||
|
|
||||||
|
- name: 🛠️ Install Pandoc & Dependencies.
|
||||||
|
shell: bash
|
||||||
|
run: |
|
||||||
|
set -euo pipefail
|
||||||
|
sudo apt-get update
|
||||||
|
sudo apt-get install -y pandoc
|
||||||
|
|
||||||
|
- name: ⚙️ Ensure .html/ directory exists.
|
||||||
|
shell: bash
|
||||||
|
run:
|
||||||
|
mkdir -p .html
|
||||||
|
|
||||||
|
- name: 🛠️ Render *.md to full standalone HTML.
|
||||||
|
shell: bash
|
||||||
|
run: |
|
||||||
|
set -euo pipefail
|
||||||
|
find . \( -path "*/.*" -prune \) -o -type f -name "*.md" -print | while read file; do
|
||||||
|
out=$(basename "${file%.md}.html")
|
||||||
|
pandoc -s "${file}" \
|
||||||
|
--metadata title="${file}" \
|
||||||
|
--metadata lang=en \
|
||||||
|
-f gfm+footnotes \
|
||||||
|
-t html5 \
|
||||||
|
--no-highlight \
|
||||||
|
--strip-comments \
|
||||||
|
--wrap=none \
|
||||||
|
--lua-filter=.gitea/properties/lua/linkfix.lua \
|
||||||
|
-o .html/"${out}"
|
||||||
|
done
|
||||||
|
|
||||||
|
- name: 🛠️ Extract HTML fragment for Gitea for *.md.
|
||||||
|
shell: bash
|
||||||
|
run: |
|
||||||
|
set -euo pipefail
|
||||||
|
find . \( -path "*/.*" -prune \) -o -type f -name "README.md" -print | while read file; do
|
||||||
|
out="${file%.md}.html"
|
||||||
|
pandoc "${file}" \
|
||||||
|
-f gfm+footnotes \
|
||||||
|
-t html5 \
|
||||||
|
--no-highlight \
|
||||||
|
--strip-comments \
|
||||||
|
--wrap=none \
|
||||||
|
--lua-filter=.gitea/properties/lua/linkfix.lua \
|
||||||
|
-o "${out}"
|
||||||
|
done
|
||||||
|
|
||||||
|
- name: 🚧 Stash local changes (including untracked).
|
||||||
|
shell: bash
|
||||||
|
env:
|
||||||
|
GIT_SSH_COMMAND: "ssh -p 42842"
|
||||||
|
run: |
|
||||||
|
set -euo pipefail
|
||||||
|
### Temporarily store any local modifications or untracked files.
|
||||||
|
git stash push --include-untracked -m "ci-temp" || echo "✔️ Nothing to stash."
|
||||||
|
|
||||||
|
- name: 🔄 Sync with remote before commit using merge strategy.
|
||||||
|
shell: bash
|
||||||
|
env:
|
||||||
|
GIT_SSH_COMMAND: "ssh -p 42842"
|
||||||
|
run: |
|
||||||
|
set -euo pipefail
|
||||||
|
export GNUPGHOME="$(pwd)/.gnupg"
|
||||||
|
|
||||||
|
echo "🔄 Fetching origin/master ..."
|
||||||
|
git fetch origin master
|
||||||
|
|
||||||
|
echo "🔁 Merging origin/master into current branch ..."
|
||||||
|
git merge --no-edit origin/master || echo "✔️ Already up to date or fast-forward."
|
||||||
|
|
||||||
|
echo "📋 Post-merge status :"
|
||||||
|
git status
|
||||||
|
git log --oneline -n 5
|
||||||
|
|
||||||
|
- name: 🛠️ Restore stashed changes.
|
||||||
|
shell: bash
|
||||||
|
env:
|
||||||
|
GIT_SSH_COMMAND: "ssh -p 42842"
|
||||||
|
run: |
|
||||||
|
set -euo pipefail
|
||||||
|
### Apply previously stashed changes.
|
||||||
|
git stash pop || echo "✔️ Nothing to pop."
|
||||||
|
|
||||||
|
- name: 📦 Stage generated files.
|
||||||
|
shell: bash
|
||||||
|
env:
|
||||||
|
GIT_SSH_COMMAND: "ssh -p 42842"
|
||||||
|
run: |
|
||||||
|
set -euo pipefail
|
||||||
|
git add *.html || echo "✔️ Nothing to add."
|
||||||
|
|
||||||
|
- name: 🔑 Commit and sign changes with CI metadata.
|
||||||
|
shell: bash
|
||||||
|
env:
|
||||||
|
GIT_SSH_COMMAND: "ssh -p 42842"
|
||||||
|
run: |
|
||||||
|
set -euo pipefail
|
||||||
|
export GNUPGHOME="$(pwd)/.gnupg"
|
||||||
|
|
||||||
|
if git diff --cached --quiet; then
|
||||||
|
echo "✔️ No staged changes to commit."
|
||||||
|
else
|
||||||
|
echo "📝 Committing changes with GPG signature ..."
|
||||||
|
|
||||||
|
### CI Metadata
|
||||||
|
TIMESTAMP_UTC="$(date -u +'%Y-%m-%dT%H:%M:%SZ')"
|
||||||
|
HOSTNAME="$(hostname -f || hostname)"
|
||||||
|
GIT_SHA="$(git rev-parse --short HEAD)"
|
||||||
|
GIT_REF="$(git symbolic-ref --short HEAD || echo detached)"
|
||||||
|
WORKFLOW_ID="${GITHUB_WORKFLOW:-render-md-to-html.yaml}"
|
||||||
|
CI_HEADER="X-CI-Metadata: ${GIT_REF}@${GIT_SHA} at ${TIMESTAMP_UTC} on ${HOSTNAME}"
|
||||||
|
|
||||||
|
COMMIT_MSG="DEPLOY BOT : 🔁 Auto-Generate *.html from *.md [skip ci]
|
||||||
|
|
||||||
|
${CI_HEADER}
|
||||||
|
|
||||||
|
Generated at : ${TIMESTAMP_UTC}
|
||||||
|
Runner Host : ${HOSTNAME}
|
||||||
|
Workflow ID : ${WORKFLOW_ID}
|
||||||
|
Git Commit : ${GIT_SHA} HEAD -> ${GIT_REF}
|
||||||
|
"
|
||||||
|
|
||||||
|
echo "🔏 Commit message :"
|
||||||
|
echo "${COMMIT_MSG}"
|
||||||
|
git commit -S -m "${COMMIT_MSG}"
|
||||||
|
fi
|
||||||
|
|
||||||
|
- name: 🔁 Push back to repository.
|
||||||
|
shell: bash
|
||||||
|
env:
|
||||||
|
GIT_SSH_COMMAND: "ssh -p 42842"
|
||||||
|
run: |
|
||||||
|
set -euo pipefail
|
||||||
|
echo "📤 Pushing changes to ${GITHUB_REF_NAME} ..."
|
||||||
|
git push origin HEAD:${GITHUB_REF_NAME}
|
||||||
|
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=yaml
|
||||||
@@ -1,12 +0,0 @@
|
|||||||
{
|
|
||||||
"$schema": "http://json-schema.org/draft-07/schema#",
|
|
||||||
"allOf": [
|
|
||||||
{ "$ref": "https://json.schemastore.org/github-workflow.json" },
|
|
||||||
{
|
|
||||||
"properties": {
|
|
||||||
"kind": { "type": "string", "enum": ["pipeline"] },
|
|
||||||
"type": { "type": "string", "enum": ["docker"] }
|
|
||||||
}
|
|
||||||
}
|
|
||||||
]
|
|
||||||
}
|
|
||||||
15
.gitea/trigger/t_generate_PRIVATE_trixie_0.yaml
Normal file
15
.gitea/trigger/t_generate_PRIVATE_trixie_0.yaml
Normal file
@@ -0,0 +1,15 @@
|
|||||||
|
# SPDX-Version: 3.0
|
||||||
|
# SPDX-CreationInfo: 2025-08-22; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
|
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
||||||
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
|
# SPDX-FileType: SOURCE
|
||||||
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
|
# SPDX-PackageName: CISS.debian.live.builder
|
||||||
|
# SPDX-Security-Contact: security@coresecret.eu
|
||||||
|
|
||||||
|
build:
|
||||||
|
counter: 1023
|
||||||
|
version: V8.13.142.2025.10.14
|
||||||
|
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=yaml
|
||||||
15
.gitea/trigger/t_generate_PRIVATE_trixie_1.yaml
Normal file
15
.gitea/trigger/t_generate_PRIVATE_trixie_1.yaml
Normal file
@@ -0,0 +1,15 @@
|
|||||||
|
# SPDX-Version: 3.0
|
||||||
|
# SPDX-CreationInfo: 2025-08-22; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
|
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
||||||
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
|
# SPDX-FileType: SOURCE
|
||||||
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
|
# SPDX-PackageName: CISS.debian.live.builder
|
||||||
|
# SPDX-Security-Contact: security@coresecret.eu
|
||||||
|
|
||||||
|
build:
|
||||||
|
counter: 1023
|
||||||
|
version: V8.13.142.2025.10.14
|
||||||
|
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=yaml
|
||||||
@@ -2,7 +2,7 @@
|
|||||||
# SPDX-CreationInfo: 2025-05-05; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-CreationInfo: 2025-05-05; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
||||||
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
# SPDX-FileCopyrightText: 2024–2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-FileType: SOURCE
|
# SPDX-FileType: SOURCE
|
||||||
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
@@ -10,6 +10,6 @@
|
|||||||
# SPDX-Security-Contact: security@coresecret.eu
|
# SPDX-Security-Contact: security@coresecret.eu
|
||||||
|
|
||||||
build:
|
build:
|
||||||
counter: 1024
|
counter: 1023
|
||||||
version: V8.02.644.2025.05.31
|
version: V8.13.142.2025.10.14
|
||||||
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=yaml
|
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=yaml
|
||||||
15
.gitea/trigger/t_generate_dns.yaml
Normal file
15
.gitea/trigger/t_generate_dns.yaml
Normal file
@@ -0,0 +1,15 @@
|
|||||||
|
# SPDX-Version: 3.0
|
||||||
|
# SPDX-CreationInfo: 2025-05-05; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
|
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
||||||
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
|
# SPDX-FileType: SOURCE
|
||||||
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
|
# SPDX-PackageName: CISS.debian.live.builder
|
||||||
|
# SPDX-Security-Contact: security@coresecret.eu
|
||||||
|
|
||||||
|
build:
|
||||||
|
counter: 1023
|
||||||
|
version: V8.13.142.2025.10.14
|
||||||
|
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=yaml
|
||||||
447
.gitea/workflows/generate_PRIVATE_trixie_0.yaml
Normal file
447
.gitea/workflows/generate_PRIVATE_trixie_0.yaml
Normal file
@@ -0,0 +1,447 @@
|
|||||||
|
# SPDX-Version: 3.0
|
||||||
|
# SPDX-CreationInfo: 2025-08-22; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
|
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
||||||
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
|
# SPDX-FileType: SOURCE
|
||||||
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
|
# SPDX-PackageName: CISS.debian.live.builder
|
||||||
|
# SPDX-Security-Contact: security@coresecret.eu
|
||||||
|
|
||||||
|
# Version Master V8.13.142.2025.10.14
|
||||||
|
|
||||||
|
name: 🔐 Generating a Private Live ISO TRIXIE.
|
||||||
|
|
||||||
|
defaults:
|
||||||
|
run:
|
||||||
|
shell: bash
|
||||||
|
|
||||||
|
permissions:
|
||||||
|
contents: write
|
||||||
|
|
||||||
|
on:
|
||||||
|
push:
|
||||||
|
branches:
|
||||||
|
- master
|
||||||
|
paths:
|
||||||
|
- '.gitea/trigger/t_generate_PRIVATE_trixie_0.yaml'
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
generate-private-cdlb-trixie:
|
||||||
|
name: 🔐 Generating a Private Live ISO TRIXIE.
|
||||||
|
runs-on: cdlb.trixie
|
||||||
|
|
||||||
|
container:
|
||||||
|
image: debian:trixie
|
||||||
|
|
||||||
|
steps:
|
||||||
|
- name: 🛠️ Basic Image Setup.
|
||||||
|
shell: bash
|
||||||
|
run: |
|
||||||
|
export DEBIAN_FRONTEND=noninteractive
|
||||||
|
apt-get update
|
||||||
|
apt-get upgrade -y
|
||||||
|
apt-get install -y --no-install-recommends \
|
||||||
|
apt-utils \
|
||||||
|
bash \
|
||||||
|
ca-certificates \
|
||||||
|
curl \
|
||||||
|
git \
|
||||||
|
gnupg \
|
||||||
|
openssh-client \
|
||||||
|
openssl \
|
||||||
|
perl \
|
||||||
|
sudo \
|
||||||
|
util-linux
|
||||||
|
|
||||||
|
- name: ⚙️ Check GnuPG Version.
|
||||||
|
shell: bash
|
||||||
|
run: |
|
||||||
|
gpg --version
|
||||||
|
|
||||||
|
- name: ⚙️ Preparing SSH Setup, SSH Deploy Key, Known Hosts, .config.
|
||||||
|
shell: bash
|
||||||
|
run: |
|
||||||
|
set -euo pipefail
|
||||||
|
var_wait=$(( RANDOM % 33 ))
|
||||||
|
printf "⏳ Waiting %s seconds to desynchronize parallel workflows...\n" "${var_wait}"
|
||||||
|
sleep "${var_wait}"
|
||||||
|
|
||||||
|
rm -rf ~/.ssh && mkdir -m700 ~/.ssh
|
||||||
|
|
||||||
|
### Private Key
|
||||||
|
echo "${{ secrets.SSH_MSW_DEPLOY_CORESECRET_DEV }}" >| ~/.ssh/id_ed25519
|
||||||
|
chmod 600 ~/.ssh/id_ed25519
|
||||||
|
|
||||||
|
### Scan git.coresecret.dev to fill ~/.ssh/known_hosts
|
||||||
|
ssh-keyscan -p 42842 git.coresecret.dev >| ~/.ssh/known_hosts
|
||||||
|
chmod 600 ~/.ssh/known_hosts
|
||||||
|
|
||||||
|
### Generate SSH Config for git.coresecret.dev Custom-Port
|
||||||
|
cat <<EOF >| ~/.ssh/config
|
||||||
|
Host git.coresecret.dev
|
||||||
|
HostName git.coresecret.dev
|
||||||
|
Port 42842
|
||||||
|
IdentityFile ~/.ssh/id_ed25519
|
||||||
|
StrictHostKeyChecking yes
|
||||||
|
UserKnownHostsFile ~/.ssh/known_hosts
|
||||||
|
EOF
|
||||||
|
chmod 600 ~/.ssh/config
|
||||||
|
|
||||||
|
### https://github.com/actions/checkout/issues/1843
|
||||||
|
- name: 🛠️ Using manual clone via SSH to circumvent Gitea SHA-256 object issues.
|
||||||
|
shell: bash
|
||||||
|
env:
|
||||||
|
### GITHUB_REF_NAME contains the branch name from the push event.
|
||||||
|
GITHUB_REF_NAME: ${{ github.ref_name }}
|
||||||
|
run: |
|
||||||
|
git clone --branch "${GITHUB_REF_NAME}" ssh://git@git.coresecret.dev:42842/msw/CISS.debian.live.builder.git .
|
||||||
|
git fetch --unshallow || echo "Nothing to fetch - already full clone."
|
||||||
|
|
||||||
|
- name: 🛠️ Cleaning the workspace.
|
||||||
|
shell: bash
|
||||||
|
run: |
|
||||||
|
git reset --hard
|
||||||
|
git clean -fd
|
||||||
|
|
||||||
|
- name: ⚙️ Importing the 'CI PGP DEPLOY ONLY' key.
|
||||||
|
shell: bash
|
||||||
|
run: |
|
||||||
|
set -euo pipefail
|
||||||
|
### GPG-Home relative to the Runner Workspace to avoid changing global files.
|
||||||
|
export GNUPGHOME="$(pwd)/.gnupg"
|
||||||
|
mkdir -m 700 "${GNUPGHOME}"
|
||||||
|
echo "${{ secrets.PGP_PUBKEY_CENTURION_ROOT_2025_X448 }}" >| centurion-root.PUB.asc
|
||||||
|
gpg --batch --import centurion-root.PUB.asc
|
||||||
|
echo "${{ secrets.PGP_MSW_DEPLOY_CORESECRET_DEV }}" >| ci-bot.sec.asc
|
||||||
|
gpg --batch --import ci-bot.sec.asc
|
||||||
|
### Trust the key automatically
|
||||||
|
KEY_ID=$(gpg --list-keys --with-colons | awk -F: '/^pub:/ {print $5}')
|
||||||
|
echo "trust-model always" >| "${GNUPGHOME}/gpg.conf"
|
||||||
|
|
||||||
|
- name: ⚙️ Configuring Git for signed CI/DEPLOY commits.
|
||||||
|
shell: bash
|
||||||
|
run: |
|
||||||
|
set -euo pipefail
|
||||||
|
export GNUPGHOME="$(pwd)/.gnupg"
|
||||||
|
git config user.name "Marc S. Weidner BOT"
|
||||||
|
git config user.email "msw+bot@coresecret.dev"
|
||||||
|
git config commit.gpgsign true
|
||||||
|
git config gpg.program gpg
|
||||||
|
git config gpg.format openpgp
|
||||||
|
|
||||||
|
- name: ⚙️ Preparing the build environment.
|
||||||
|
shell: bash
|
||||||
|
run: |
|
||||||
|
set -euo pipefail
|
||||||
|
mkdir -p /opt/config
|
||||||
|
mkdir -p /opt/livebuild
|
||||||
|
touch /opt/config/password.txt && chmod 0600 /opt/config/password.txt
|
||||||
|
touch /opt/config/authorized_keys && chmod 0600 /opt/config/authorized_keys
|
||||||
|
echo "${{ secrets.CISS_DLB_ROOT_PWD }}" >| /opt/config/password.txt
|
||||||
|
echo "${{ secrets.CISS_DLB_ROOT_SSH_PUBKEY }}" >| /opt/config/authorized_keys
|
||||||
|
|
||||||
|
- name: 🔧 Render live hook with secrets.
|
||||||
|
shell: bash
|
||||||
|
working-directory: ${{ github.workspace }}
|
||||||
|
env:
|
||||||
|
ED25519_PRIV: ${{ secrets.CISS_DLB_SSH_HOST_ED25519_KEY }}
|
||||||
|
ED25519_PUB: ${{ secrets.CISS_DLB_SSH_HOST_ED25519_KEY_PUB }}
|
||||||
|
RSA_PRIV: ${{ secrets.CISS_DLB_SSH_HOST_RSA_KEY }}
|
||||||
|
RSA_PUB: ${{ secrets.CISS_DLB_SSH_HOST_RSA_KEY_PUB }}
|
||||||
|
CISS_PRIMORDIAL: ${{ secrets.CISS_PRIMORDIAL_PRIVATE }}
|
||||||
|
CISS_PRIMORDIAL_PUB: ${{ secrets.CISS_PRIMORDIAL_PUBLIC }}
|
||||||
|
run: |
|
||||||
|
set -Ceuo pipefail
|
||||||
|
umask 077
|
||||||
|
|
||||||
|
REPO_ROOT="$(git rev-parse --show-toplevel 2>/dev/null || pwd -P)"
|
||||||
|
|
||||||
|
TPL="${REPO_ROOT}/config/hooks/live/9935_hardening_ssh.chroot.tmpl"
|
||||||
|
OUT="${REPO_ROOT}/config/hooks/live/9935_hardening_ssh.chroot"
|
||||||
|
ID_OUT="${REPO_ROOT}/config/includes.chroot/root/.ssh/id_2025_ed25519_ciss_primordial"
|
||||||
|
ID_OUT_PUB="${REPO_ROOT}/config/includes.chroot/root/.ssh/id_2025_ed25519_ciss_primordial.pub"
|
||||||
|
|
||||||
|
if [[ ! -f "${TPL}" ]]; then
|
||||||
|
echo "Template not found: ${TPL}"
|
||||||
|
echo "::group::Tree of config/hooks/live"
|
||||||
|
ls -la "${REPO_ROOT}/config/hooks/live" || true
|
||||||
|
echo "::endgroup::"
|
||||||
|
exit 2
|
||||||
|
fi
|
||||||
|
|
||||||
|
export ED25519_PRIV="${ED25519_PRIV//$'\r'/}"
|
||||||
|
export ED25519_PUB="${ED25519_PUB//$'\r'/}"
|
||||||
|
export RSA_PRIV="${RSA_PRIV//$'\r'/}"
|
||||||
|
export RSA_PUB="${RSA_PUB//$'\r'/}"
|
||||||
|
export CISS_PRIMORDIAL="${CISS_PRIMORDIAL//$'\r'/}"
|
||||||
|
export CISS_PRIMORDIAL_PUB="${CISS_PRIMORDIAL_PUB//$'\r'/}"
|
||||||
|
|
||||||
|
(
|
||||||
|
cat << EOF >| "${ID_OUT}"
|
||||||
|
${CISS_PRIMORDIAL}
|
||||||
|
EOF
|
||||||
|
) && chmod 0600 "${ID_OUT}"
|
||||||
|
if [[ -f "${ID_OUT}" ]]; then
|
||||||
|
echo "Written: ${ID_OUT}"
|
||||||
|
else
|
||||||
|
echo "Error: ${ID_OUT} not written."
|
||||||
|
fi
|
||||||
|
|
||||||
|
(
|
||||||
|
cat << EOF >| "${ID_OUT_PUB}"
|
||||||
|
${CISS_PRIMORDIAL_PUB}
|
||||||
|
EOF
|
||||||
|
) && chmod 0600 "${ID_OUT_PUB}"
|
||||||
|
if [[ -f "${ID_OUT_PUB}" ]]; then
|
||||||
|
echo "Written: ${ID_OUT_PUB}"
|
||||||
|
else
|
||||||
|
echo "Error: ${ID_OUT_PUB} not written."
|
||||||
|
fi
|
||||||
|
|
||||||
|
perl -0777 -pe '
|
||||||
|
BEGIN{
|
||||||
|
$ed=$ENV{ED25519_PRIV}; $edpub=$ENV{ED25519_PUB};
|
||||||
|
$rsa=$ENV{RSA_PRIV}; $rsapub=$ENV{RSA_PUB};
|
||||||
|
}
|
||||||
|
s/\{\{\s*secrets\.CISS_DLB_SSH_HOST_ED25519_KEY\s*\}\}/$ed/g;
|
||||||
|
s/\{\{\s*secrets\.CISS_DLB_SSH_HOST_ED25519_KEY_PUB\s*\}\}/$edpub/g;
|
||||||
|
s/\{\{\s*secrets\.CISS_DLB_SSH_HOST_RSA_KEY\s*\}\}/$rsa/g;
|
||||||
|
s/\{\{\s*secrets\.CISS_DLB_SSH_HOST_RSA_KEY_PUB\s*\}\}/$rsapub/g;
|
||||||
|
' "${TPL}" > "${OUT}"
|
||||||
|
|
||||||
|
chmod 0755 "${OUT}"
|
||||||
|
echo "Hook rendered: ${OUT}"
|
||||||
|
|
||||||
|
- name: 🛠️ Starting CISS.debian.live.builder. This may take a while ...
|
||||||
|
shell: bash
|
||||||
|
working-directory: ${{ github.workspace }}
|
||||||
|
run: |
|
||||||
|
set -euo pipefail
|
||||||
|
chmod 0755 ciss_live_builder.sh
|
||||||
|
timestamp=$(date -u +"%Y_%m_%dT%H_%M_%SZ")
|
||||||
|
### Change "--autobuild=" to the specific kernel version you need: '6.16.3+deb13-amd64'.
|
||||||
|
./ciss_live_builder.sh \
|
||||||
|
--autobuild=6.16.3+deb13-amd64 \
|
||||||
|
--architecture amd64 \
|
||||||
|
--build-directory /opt/livebuild \
|
||||||
|
--cdi \
|
||||||
|
--control "${timestamp}" \
|
||||||
|
--debug \
|
||||||
|
--dhcp-centurion \
|
||||||
|
--jump-host ${{ secrets.CISS_DLB_JUMP_HOSTS }} \
|
||||||
|
--provider-netcup-ipv6 ${{ secrets.CISS_DLB_NETCUP_IPV6 }} \
|
||||||
|
--root-password-file /opt/config/password.txt \
|
||||||
|
--ssh-port ${{ secrets.CISS_DLB_SSH_PORT }} \
|
||||||
|
--ssh-pubkey /opt/config \
|
||||||
|
--sshfp \
|
||||||
|
--trixie
|
||||||
|
|
||||||
|
REPO_ROOT="$(git rev-parse --show-toplevel 2>/dev/null || pwd -P)"
|
||||||
|
OUT="$REPO_ROOT/config/hooks/live/9935_hardening_ssh.chroot"
|
||||||
|
rm -f "$OUT"
|
||||||
|
echo "Hook removed: $OUT"
|
||||||
|
|
||||||
|
- name: 📥 Checking Centurion Cloud for existing LIVE ISOs.
|
||||||
|
shell: bash
|
||||||
|
env:
|
||||||
|
NC_BASE: "https://cloud.e2ee.li"
|
||||||
|
SHARE_TOKEN: "${{ secrets.CENTURION_CLOUD_UL_USER }}"
|
||||||
|
SHARE_PASS: "${{ secrets.CENTURION_CLOUD_UL_PASSWD }}"
|
||||||
|
run: |
|
||||||
|
set -euo pipefail
|
||||||
|
SHARE_SUBDIR=""
|
||||||
|
|
||||||
|
echo "📥 Get directory listing via PROPFIND ..."
|
||||||
|
curl -s \
|
||||||
|
--user "${SHARE_TOKEN}:${SHARE_PASS}" \
|
||||||
|
-X PROPFIND \
|
||||||
|
-H "Depth: 1" \
|
||||||
|
"${NC_BASE}/public.php/webdav/${SHARE_SUBDIR}" \
|
||||||
|
-o propfind_public.xml
|
||||||
|
|
||||||
|
echo "📥 Filter .iso files from the PROPFIND response ..."
|
||||||
|
grep -oP '(?<=<d:href>)[^<]+\.iso(?=</d:href>)' propfind_public.xml >| public_iso_list.txt || true
|
||||||
|
|
||||||
|
if [[ -f public_iso_list.txt && -s public_iso_list.txt ]]; then
|
||||||
|
echo "💡 Old ISO files found and deleted :"
|
||||||
|
while IFS= read -r href; do
|
||||||
|
FILE_URL="${NC_BASE}${href}"
|
||||||
|
echo " Delete: ${FILE_URL}"
|
||||||
|
if curl -s \
|
||||||
|
--user "${SHARE_TOKEN}:${SHARE_PASS}" \
|
||||||
|
-X DELETE "${FILE_URL}"; then
|
||||||
|
echo " ✅ Successfully deleted: $(basename "${href}")"
|
||||||
|
else
|
||||||
|
echo " ❌ Error: $(basename "${href}") could not be deleted"
|
||||||
|
fi
|
||||||
|
done < public_iso_list.txt
|
||||||
|
else
|
||||||
|
echo "💡 No old ISO files found to delete."
|
||||||
|
fi
|
||||||
|
|
||||||
|
- name: 🛠️ Upload the ISO file to the Centurion Cloud (cloud.e2ee.li) via WebDAV.
|
||||||
|
shell: bash
|
||||||
|
env:
|
||||||
|
NC_BASE: "https://cloud.e2ee.li"
|
||||||
|
SHARE_TOKEN: "${{ secrets.CENTURION_CLOUD_UL_USER }}"
|
||||||
|
SHARE_PASS: "${{ secrets.CENTURION_CLOUD_UL_PASSWD }}"
|
||||||
|
run: |
|
||||||
|
set -euo pipefail
|
||||||
|
if [[ $(ls /opt/livebuild/*.iso 2>/dev/null | wc -l) -ne 1 ]]; then
|
||||||
|
echo "❌ There must be exactly one .iso file in the directory!"
|
||||||
|
exit 1
|
||||||
|
else
|
||||||
|
VAR_ISO_FILE_PATH=$(ls /opt/livebuild/*.iso)
|
||||||
|
VAR_ISO_FILE_NAME=$(basename "${VAR_ISO_FILE_PATH}")
|
||||||
|
echo "✅ ISO file found: ${VAR_ISO_FILE_NAME}"
|
||||||
|
fi
|
||||||
|
|
||||||
|
AUTH="${SHARE_TOKEN}:${SHARE_PASS}"
|
||||||
|
if curl --retry 2 "${NC_BASE}"/public.php/webdav/"${VAR_ISO_FILE_NAME}" \
|
||||||
|
--upload-file "${VAR_ISO_FILE_PATH}" --user "${AUTH}" > /dev/null 2>&1; then
|
||||||
|
echo "✅ New ISO successfully uploaded."
|
||||||
|
else
|
||||||
|
echo "❌ Uploading the new ISO failed."
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
|
- name: 🔑 Generating a sha512 Hash of ISO, signing with the 'CI PGP DEPLOY ONLY' key, generate a success message file.
|
||||||
|
shell: bash
|
||||||
|
run: |
|
||||||
|
if [[ $(ls /opt/livebuild/*.iso 2>/dev/null | wc -l) -ne 1 ]]; then
|
||||||
|
echo "❌ There must be exactly one .iso file in the directory!"
|
||||||
|
exit 1
|
||||||
|
else
|
||||||
|
VAR_ISO_FILE_PATH=$(ls /opt/livebuild/*.iso)
|
||||||
|
VAR_ISO_FILE_NAME=$(basename "${VAR_ISO_FILE_PATH}")
|
||||||
|
echo "✅ ISO file found: ${VAR_ISO_FILE_NAME}"
|
||||||
|
fi
|
||||||
|
|
||||||
|
VAR_ISO_FILE_SHA512="${VAR_ISO_FILE_NAME}.sha512"
|
||||||
|
touch "${VAR_ISO_FILE_SHA512}"
|
||||||
|
sha512sum "${VAR_ISO_FILE_PATH}" | awk '{print $1}' >| "${VAR_ISO_FILE_SHA512}"
|
||||||
|
SIGNATURE_FILE="${VAR_ISO_FILE_SHA512}.sign"
|
||||||
|
touch "${SIGNATURE_FILE}"
|
||||||
|
export GNUPGHOME="$(pwd)/.gnupg"
|
||||||
|
gpg --batch --yes --armor --detach-sign --output "${SIGNATURE_FILE}" "${VAR_ISO_FILE_SHA512}"
|
||||||
|
|
||||||
|
timestamp=$(date -u +"%Y-%m-%dT%H:%M:%SZ")
|
||||||
|
VAR_DATE="$(date +%F)"
|
||||||
|
PRIVATE_FILE="LIVE_ISO_TRIXIE_0.private"
|
||||||
|
touch "${PRIVATE_FILE}"
|
||||||
|
cat << EOF >| "${PRIVATE_FILE}"
|
||||||
|
# SPDX-Version: 3.0
|
||||||
|
# SPDX-CreationInfo: ${VAR_DATE}; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
|
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
||||||
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
|
# SPDX-FileType: SOURCE
|
||||||
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
|
# SPDX-PackageName: CISS.debian.live.builder
|
||||||
|
# SPDX-Security-Contact: security@coresecret.eu
|
||||||
|
|
||||||
|
This file was automatically generated by the DEPLOY BOT on: "${timestamp}"
|
||||||
|
|
||||||
|
CISS.debian.live.builder ISO :
|
||||||
|
"${VAR_ISO_FILE_NAME}"
|
||||||
|
CISS.debian.live.builder ISO sha512 :
|
||||||
|
$(< "${VAR_ISO_FILE_SHA512}")
|
||||||
|
CISS.debian.live.builder ISO sha512 sign :
|
||||||
|
$(< "${SIGNATURE_FILE}")
|
||||||
|
|
||||||
|
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=text
|
||||||
|
EOF
|
||||||
|
|
||||||
|
- name: 🚧 Stash local changes (including untracked).
|
||||||
|
shell: bash
|
||||||
|
env:
|
||||||
|
GIT_SSH_COMMAND: "ssh -p 42842"
|
||||||
|
run: |
|
||||||
|
set -euo pipefail
|
||||||
|
### Temporarily store any local modifications or untracked files.
|
||||||
|
git stash push --include-untracked -m "ci-temp" || echo "✔️ Nothing to stash."
|
||||||
|
|
||||||
|
- name: 🔄 Sync with remote before commit using merge strategy.
|
||||||
|
shell: bash
|
||||||
|
env:
|
||||||
|
GIT_SSH_COMMAND: "ssh -p 42842"
|
||||||
|
run: |
|
||||||
|
set -euo pipefail
|
||||||
|
export GNUPGHOME="$(pwd)/.gnupg"
|
||||||
|
|
||||||
|
echo "🔄 Fetching origin/master ..."
|
||||||
|
git fetch origin master
|
||||||
|
|
||||||
|
echo "🔁 Merging origin/master into current branch ..."
|
||||||
|
git merge --no-edit origin/master || echo "✔️ Already up to date or fast-forward."
|
||||||
|
|
||||||
|
echo "📋 Post-merge status :"
|
||||||
|
git status
|
||||||
|
git log --oneline -n 5
|
||||||
|
|
||||||
|
- name: 🛠️ Restore stashed changes.
|
||||||
|
shell: bash
|
||||||
|
env:
|
||||||
|
GIT_SSH_COMMAND: "ssh -p 42842"
|
||||||
|
run: |
|
||||||
|
set -euo pipefail
|
||||||
|
### Apply previously stashed changes.
|
||||||
|
git stash pop || echo "✔️ Nothing to pop."
|
||||||
|
|
||||||
|
- name: 📦 Stage generated files.
|
||||||
|
shell: bash
|
||||||
|
env:
|
||||||
|
GIT_SSH_COMMAND: "ssh -p 42842"
|
||||||
|
run: |
|
||||||
|
set -euo pipefail
|
||||||
|
PRIVATE_FILE="LIVE_ISO_TRIXIE_0.private"
|
||||||
|
git add "${PRIVATE_FILE}" || echo "✔️ Nothing to add."
|
||||||
|
|
||||||
|
- name: 🔑 Commit and sign changes with CI metadata.
|
||||||
|
shell: bash
|
||||||
|
env:
|
||||||
|
GIT_SSH_COMMAND: "ssh -p 42842"
|
||||||
|
run: |
|
||||||
|
set -euo pipefail
|
||||||
|
export GNUPGHOME="$(pwd)/.gnupg"
|
||||||
|
|
||||||
|
if git diff --cached --quiet; then
|
||||||
|
echo "✔️ No staged changes to commit."
|
||||||
|
else
|
||||||
|
echo "📝 Committing changes with GPG signature ..."
|
||||||
|
|
||||||
|
### CI Metadata
|
||||||
|
TIMESTAMP_UTC="$(date -u +'%Y-%m-%dT%H:%M:%SZ')"
|
||||||
|
HOSTNAME="$(hostname -f || hostname)"
|
||||||
|
GIT_SHA="$(git rev-parse --short HEAD)"
|
||||||
|
GIT_REF="$(git symbolic-ref --short HEAD || echo detached)"
|
||||||
|
WORKFLOW_ID="${GITHUB_WORKFLOW:-render-md-to-html.yaml}"
|
||||||
|
CI_HEADER="X-CI-Metadata: ${GIT_REF}@${GIT_SHA} at ${TIMESTAMP_UTC} on ${HOSTNAME}"
|
||||||
|
|
||||||
|
COMMIT_MSG="DEPLOY BOT : 🔐 Auto-Generate PRIVATE LIVE ISO TRIXIE 0 [skip ci]
|
||||||
|
|
||||||
|
${CI_HEADER}
|
||||||
|
|
||||||
|
Generated at : ${TIMESTAMP_UTC}
|
||||||
|
Runner Host : ${HOSTNAME}
|
||||||
|
Workflow ID : ${WORKFLOW_ID}
|
||||||
|
Git Commit : ${GIT_SHA} HEAD -> ${GIT_REF}
|
||||||
|
"
|
||||||
|
|
||||||
|
echo "🔏 Commit message :"
|
||||||
|
echo "${COMMIT_MSG}"
|
||||||
|
git commit -S -m "${COMMIT_MSG}"
|
||||||
|
fi
|
||||||
|
|
||||||
|
- name: 🔁 Push back to repository.
|
||||||
|
shell: bash
|
||||||
|
env:
|
||||||
|
GIT_SSH_COMMAND: "ssh -p 42842"
|
||||||
|
run: |
|
||||||
|
set -euo pipefail
|
||||||
|
echo "📤 Pushing changes to ${GITHUB_REF_NAME} ..."
|
||||||
|
git push origin HEAD:${GITHUB_REF_NAME}
|
||||||
|
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=yaml
|
||||||
444
.gitea/workflows/generate_PRIVATE_trixie_1.yaml
Normal file
444
.gitea/workflows/generate_PRIVATE_trixie_1.yaml
Normal file
@@ -0,0 +1,444 @@
|
|||||||
|
# SPDX-Version: 3.0
|
||||||
|
# SPDX-CreationInfo: 2025-08-22; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
|
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
||||||
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
|
# SPDX-FileType: SOURCE
|
||||||
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
|
# SPDX-PackageName: CISS.debian.live.builder
|
||||||
|
# SPDX-Security-Contact: security@coresecret.eu
|
||||||
|
|
||||||
|
# Version Master V8.13.142.2025.10.14
|
||||||
|
|
||||||
|
name: 🔐 Generating a Private Live ISO TRIXIE.
|
||||||
|
|
||||||
|
defaults:
|
||||||
|
run:
|
||||||
|
shell: bash
|
||||||
|
|
||||||
|
permissions:
|
||||||
|
contents: write
|
||||||
|
|
||||||
|
on:
|
||||||
|
push:
|
||||||
|
branches:
|
||||||
|
- master
|
||||||
|
paths:
|
||||||
|
- '.gitea/trigger/t_generate_PRIVATE_trixie_1.yaml'
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
generate-private-cdlb-trixie:
|
||||||
|
name: 🔐 Generating a Private Live ISO TRIXIE.
|
||||||
|
runs-on: cdlb.trixie
|
||||||
|
|
||||||
|
container:
|
||||||
|
image: debian:trixie
|
||||||
|
|
||||||
|
steps:
|
||||||
|
- name: 🛠️ Basic Image Setup.
|
||||||
|
shell: bash
|
||||||
|
run: |
|
||||||
|
export DEBIAN_FRONTEND=noninteractive
|
||||||
|
apt-get update
|
||||||
|
apt-get upgrade -y
|
||||||
|
apt-get install -y --no-install-recommends \
|
||||||
|
apt-utils \
|
||||||
|
bash \
|
||||||
|
ca-certificates \
|
||||||
|
curl \
|
||||||
|
git \
|
||||||
|
gnupg \
|
||||||
|
openssh-client \
|
||||||
|
openssl \
|
||||||
|
perl \
|
||||||
|
sudo \
|
||||||
|
util-linux
|
||||||
|
|
||||||
|
- name: ⚙️ Check GnuPG Version.
|
||||||
|
shell: bash
|
||||||
|
run: |
|
||||||
|
gpg --version
|
||||||
|
|
||||||
|
- name: ⚙️ Preparing SSH Setup, SSH Deploy Key, Known Hosts, .config.
|
||||||
|
shell: bash
|
||||||
|
run: |
|
||||||
|
set -euo pipefail
|
||||||
|
var_wait=$(( RANDOM % 33 ))
|
||||||
|
printf "⏳ Waiting %s seconds to desynchronize parallel workflows...\n" "${var_wait}"
|
||||||
|
sleep "${var_wait}"
|
||||||
|
|
||||||
|
rm -rf ~/.ssh && mkdir -m700 ~/.ssh
|
||||||
|
|
||||||
|
### Private Key
|
||||||
|
echo "${{ secrets.SSH_MSW_DEPLOY_CORESECRET_DEV }}" >| ~/.ssh/id_ed25519
|
||||||
|
chmod 600 ~/.ssh/id_ed25519
|
||||||
|
|
||||||
|
### Scan git.coresecret.dev to fill ~/.ssh/known_hosts
|
||||||
|
ssh-keyscan -p 42842 git.coresecret.dev >| ~/.ssh/known_hosts
|
||||||
|
chmod 600 ~/.ssh/known_hosts
|
||||||
|
|
||||||
|
### Generate SSH Config for git.coresecret.dev Custom-Port
|
||||||
|
cat <<EOF >| ~/.ssh/config
|
||||||
|
Host git.coresecret.dev
|
||||||
|
HostName git.coresecret.dev
|
||||||
|
Port 42842
|
||||||
|
IdentityFile ~/.ssh/id_ed25519
|
||||||
|
StrictHostKeyChecking yes
|
||||||
|
UserKnownHostsFile ~/.ssh/known_hosts
|
||||||
|
EOF
|
||||||
|
chmod 600 ~/.ssh/config
|
||||||
|
|
||||||
|
### https://github.com/actions/checkout/issues/1843
|
||||||
|
- name: 🛠️ Using manual clone via SSH to circumvent Gitea SHA-256 object issues.
|
||||||
|
shell: bash
|
||||||
|
env:
|
||||||
|
### GITHUB_REF_NAME contains the branch name from the push event.
|
||||||
|
GITHUB_REF_NAME: ${{ github.ref_name }}
|
||||||
|
run: |
|
||||||
|
git clone --branch "${GITHUB_REF_NAME}" ssh://git@git.coresecret.dev:42842/msw/CISS.debian.live.builder.git .
|
||||||
|
git fetch --unshallow || echo "Nothing to fetch - already full clone."
|
||||||
|
|
||||||
|
- name: 🛠️ Cleaning the workspace.
|
||||||
|
shell: bash
|
||||||
|
run: |
|
||||||
|
git reset --hard
|
||||||
|
git clean -fd
|
||||||
|
|
||||||
|
- name: ⚙️ Importing the 'CI PGP DEPLOY ONLY' key.
|
||||||
|
shell: bash
|
||||||
|
run: |
|
||||||
|
set -euo pipefail
|
||||||
|
### GPG-Home relative to the Runner Workspace to avoid changing global files.
|
||||||
|
export GNUPGHOME="$(pwd)/.gnupg"
|
||||||
|
mkdir -m 700 "${GNUPGHOME}"
|
||||||
|
echo "${{ secrets.PGP_PUBKEY_CENTURION_ROOT_2025_X448 }}" >| centurion-root.PUB.asc
|
||||||
|
gpg --batch --import centurion-root.PUB.asc
|
||||||
|
echo "${{ secrets.PGP_MSW_DEPLOY_CORESECRET_DEV }}" >| ci-bot.sec.asc
|
||||||
|
gpg --batch --import ci-bot.sec.asc
|
||||||
|
### Trust the key automatically
|
||||||
|
KEY_ID=$(gpg --list-keys --with-colons | awk -F: '/^pub:/ {print $5}')
|
||||||
|
echo "trust-model always" >| "${GNUPGHOME}/gpg.conf"
|
||||||
|
|
||||||
|
- name: ⚙️ Configuring Git for signed CI/DEPLOY commits.
|
||||||
|
shell: bash
|
||||||
|
run: |
|
||||||
|
set -euo pipefail
|
||||||
|
export GNUPGHOME="$(pwd)/.gnupg"
|
||||||
|
git config user.name "Marc S. Weidner BOT"
|
||||||
|
git config user.email "msw+bot@coresecret.dev"
|
||||||
|
git config commit.gpgsign true
|
||||||
|
git config gpg.program gpg
|
||||||
|
git config gpg.format openpgp
|
||||||
|
|
||||||
|
- name: ⚙️ Preparing the build environment.
|
||||||
|
shell: bash
|
||||||
|
run: |
|
||||||
|
set -euo pipefail
|
||||||
|
mkdir -p /opt/config
|
||||||
|
mkdir -p /opt/livebuild
|
||||||
|
touch /opt/config/password.txt && chmod 0600 /opt/config/password.txt
|
||||||
|
touch /opt/config/authorized_keys && chmod 0600 /opt/config/authorized_keys
|
||||||
|
echo "${{ secrets.CISS_DLB_ROOT_PWD_1 }}" >| /opt/config/password.txt
|
||||||
|
echo "${{ secrets.CISS_DLB_ROOT_SSH_PUBKEY_1 }}" >| /opt/config/authorized_keys
|
||||||
|
|
||||||
|
- name: 🔧 Render live hook with secrets.
|
||||||
|
shell: bash
|
||||||
|
working-directory: ${{ github.workspace }}
|
||||||
|
env:
|
||||||
|
ED25519_PRIV: ${{ secrets.CISS_DLB_SSH_HOST_ED25519_KEY }}
|
||||||
|
ED25519_PUB: ${{ secrets.CISS_DLB_SSH_HOST_ED25519_KEY_PUB }}
|
||||||
|
RSA_PRIV: ${{ secrets.CISS_DLB_SSH_HOST_RSA_KEY }}
|
||||||
|
RSA_PUB: ${{ secrets.CISS_DLB_SSH_HOST_RSA_KEY_PUB }}
|
||||||
|
CISS_PRIMORDIAL: ${{ secrets.CISS_PRIMORDIAL_PRIVATE }}
|
||||||
|
CISS_PRIMORDIAL_PUB: ${{ secrets.CISS_PRIMORDIAL_PUBLIC }}
|
||||||
|
run: |
|
||||||
|
set -Ceuo pipefail
|
||||||
|
umask 077
|
||||||
|
|
||||||
|
REPO_ROOT="$(git rev-parse --show-toplevel 2>/dev/null || pwd -P)"
|
||||||
|
|
||||||
|
TPL="${REPO_ROOT}/config/hooks/live/9935_hardening_ssh.chroot.tmpl"
|
||||||
|
OUT="${REPO_ROOT}/config/hooks/live/9935_hardening_ssh.chroot"
|
||||||
|
ID_OUT="${REPO_ROOT}/config/includes.chroot/root/.ssh/id_2025_ed25519_ciss_primordial"
|
||||||
|
ID_OUT_PUB="${REPO_ROOT}/config/includes.chroot/root/.ssh/id_2025_ed25519_ciss_primordial.pub"
|
||||||
|
|
||||||
|
if [[ ! -f "${TPL}" ]]; then
|
||||||
|
echo "Template not found: ${TPL}"
|
||||||
|
echo "::group::Tree of config/hooks/live"
|
||||||
|
ls -la "${REPO_ROOT}/config/hooks/live" || true
|
||||||
|
echo "::endgroup::"
|
||||||
|
exit 2
|
||||||
|
fi
|
||||||
|
|
||||||
|
export ED25519_PRIV="${ED25519_PRIV//$'\r'/}"
|
||||||
|
export ED25519_PUB="${ED25519_PUB//$'\r'/}"
|
||||||
|
export RSA_PRIV="${RSA_PRIV//$'\r'/}"
|
||||||
|
export RSA_PUB="${RSA_PUB//$'\r'/}"
|
||||||
|
export CISS_PRIMORDIAL="${CISS_PRIMORDIAL//$'\r'/}"
|
||||||
|
export CISS_PRIMORDIAL_PUB="${CISS_PRIMORDIAL_PUB//$'\r'/}"
|
||||||
|
|
||||||
|
(
|
||||||
|
cat << EOF >| "${ID_OUT}"
|
||||||
|
${CISS_PRIMORDIAL}
|
||||||
|
EOF
|
||||||
|
) && chmod 0600 "${ID_OUT}"
|
||||||
|
if [[ -f "${ID_OUT}" ]]; then
|
||||||
|
echo "Written: ${ID_OUT}"
|
||||||
|
else
|
||||||
|
echo "Error: ${ID_OUT} not written."
|
||||||
|
fi
|
||||||
|
|
||||||
|
(
|
||||||
|
cat << EOF >| "${ID_OUT_PUB}"
|
||||||
|
${CISS_PRIMORDIAL_PUB}
|
||||||
|
EOF
|
||||||
|
) && chmod 0600 "${ID_OUT_PUB}"
|
||||||
|
if [[ -f "${ID_OUT_PUB}" ]]; then
|
||||||
|
echo "Written: ${ID_OUT_PUB}"
|
||||||
|
else
|
||||||
|
echo "Error: ${ID_OUT_PUB} not written."
|
||||||
|
fi
|
||||||
|
|
||||||
|
perl -0777 -pe '
|
||||||
|
BEGIN{
|
||||||
|
$ed=$ENV{ED25519_PRIV}; $edpub=$ENV{ED25519_PUB};
|
||||||
|
$rsa=$ENV{RSA_PRIV}; $rsapub=$ENV{RSA_PUB};
|
||||||
|
}
|
||||||
|
s/\{\{\s*secrets\.CISS_DLB_SSH_HOST_ED25519_KEY\s*\}\}/$ed/g;
|
||||||
|
s/\{\{\s*secrets\.CISS_DLB_SSH_HOST_ED25519_KEY_PUB\s*\}\}/$edpub/g;
|
||||||
|
s/\{\{\s*secrets\.CISS_DLB_SSH_HOST_RSA_KEY\s*\}\}/$rsa/g;
|
||||||
|
s/\{\{\s*secrets\.CISS_DLB_SSH_HOST_RSA_KEY_PUB\s*\}\}/$rsapub/g;
|
||||||
|
' "${TPL}" > "${OUT}"
|
||||||
|
|
||||||
|
chmod 0755 "${OUT}"
|
||||||
|
echo "Hook rendered: ${OUT}"
|
||||||
|
|
||||||
|
- name: 🛠️ Starting CISS.debian.live.builder. This may take a while ...
|
||||||
|
shell: bash
|
||||||
|
working-directory: ${{ github.workspace }}
|
||||||
|
run: |
|
||||||
|
set -euo pipefail
|
||||||
|
chmod 0755 ciss_live_builder.sh
|
||||||
|
timestamp=$(date -u +"%Y_%m_%dT%H_%M_%SZ")
|
||||||
|
### Change "--autobuild=" to the specific kernel version you need: '6.16.3+deb13-amd64'.
|
||||||
|
./ciss_live_builder.sh \
|
||||||
|
--autobuild=6.16.3+deb13-amd64 \
|
||||||
|
--architecture amd64 \
|
||||||
|
--build-directory /opt/livebuild \
|
||||||
|
--cdi \
|
||||||
|
--control "${timestamp}" \
|
||||||
|
--jump-host ${{ secrets.CISS_DLB_JUMP_HOSTS_1 }} \
|
||||||
|
--root-password-file /opt/config/password.txt \
|
||||||
|
--ssh-port ${{ secrets.CISS_DLB_SSH_PORT_1 }} \
|
||||||
|
--ssh-pubkey /opt/config \
|
||||||
|
--sshfp \
|
||||||
|
--trixie
|
||||||
|
|
||||||
|
REPO_ROOT="$(git rev-parse --show-toplevel 2>/dev/null || pwd -P)"
|
||||||
|
OUT="$REPO_ROOT/config/hooks/live/9935_hardening_ssh.chroot"
|
||||||
|
rm -f "$OUT"
|
||||||
|
echo "Hook removed: $OUT"
|
||||||
|
|
||||||
|
- name: 📥 Checking Centurion Cloud for existing LIVE ISOs.
|
||||||
|
shell: bash
|
||||||
|
env:
|
||||||
|
NC_BASE: "https://cloud.e2ee.li"
|
||||||
|
SHARE_TOKEN: "${{ secrets.CENTURION_CLOUD_UL_USER_1 }}"
|
||||||
|
SHARE_PASS: "${{ secrets.CENTURION_CLOUD_UL_PASSWD_1 }}"
|
||||||
|
run: |
|
||||||
|
set -euo pipefail
|
||||||
|
SHARE_SUBDIR=""
|
||||||
|
|
||||||
|
echo "📥 Get directory listing via PROPFIND ..."
|
||||||
|
curl -s \
|
||||||
|
--user "${SHARE_TOKEN}:${SHARE_PASS}" \
|
||||||
|
-X PROPFIND \
|
||||||
|
-H "Depth: 1" \
|
||||||
|
"${NC_BASE}/public.php/webdav/${SHARE_SUBDIR}" \
|
||||||
|
-o propfind_public.xml
|
||||||
|
|
||||||
|
echo "📥 Filter .iso files from the PROPFIND response ..."
|
||||||
|
grep -oP '(?<=<d:href>)[^<]+\.iso(?=</d:href>)' propfind_public.xml >| public_iso_list.txt || true
|
||||||
|
|
||||||
|
if [[ -f public_iso_list.txt && -s public_iso_list.txt ]]; then
|
||||||
|
echo "💡 Old ISO files found and deleted :"
|
||||||
|
while IFS= read -r href; do
|
||||||
|
FILE_URL="${NC_BASE}${href}"
|
||||||
|
echo " Delete: ${FILE_URL}"
|
||||||
|
if curl -s \
|
||||||
|
--user "${SHARE_TOKEN}:${SHARE_PASS}" \
|
||||||
|
-X DELETE "${FILE_URL}"; then
|
||||||
|
echo " ✅ Successfully deleted: $(basename "${href}")"
|
||||||
|
else
|
||||||
|
echo " ❌ Error: $(basename "${href}") could not be deleted"
|
||||||
|
fi
|
||||||
|
done < public_iso_list.txt
|
||||||
|
else
|
||||||
|
echo "💡 No old ISO files found to delete."
|
||||||
|
fi
|
||||||
|
|
||||||
|
- name: 🛠️ Upload the ISO file to the Centurion Cloud (cloud.e2ee.li) via WebDAV.
|
||||||
|
shell: bash
|
||||||
|
env:
|
||||||
|
NC_BASE: "https://cloud.e2ee.li"
|
||||||
|
SHARE_TOKEN: "${{ secrets.CENTURION_CLOUD_UL_USER_1 }}"
|
||||||
|
SHARE_PASS: "${{ secrets.CENTURION_CLOUD_UL_PASSWD_1 }}"
|
||||||
|
run: |
|
||||||
|
set -euo pipefail
|
||||||
|
if [[ $(ls /opt/livebuild/*.iso 2>/dev/null | wc -l) -ne 1 ]]; then
|
||||||
|
echo "❌ There must be exactly one .iso file in the directory!"
|
||||||
|
exit 1
|
||||||
|
else
|
||||||
|
VAR_ISO_FILE_PATH=$(ls /opt/livebuild/*.iso)
|
||||||
|
VAR_ISO_FILE_NAME=$(basename "${VAR_ISO_FILE_PATH}")
|
||||||
|
echo "✅ ISO file found: ${VAR_ISO_FILE_NAME}"
|
||||||
|
fi
|
||||||
|
|
||||||
|
AUTH="${SHARE_TOKEN}:${SHARE_PASS}"
|
||||||
|
if curl --retry 2 "${NC_BASE}"/public.php/webdav/"${VAR_ISO_FILE_NAME}" \
|
||||||
|
--upload-file "${VAR_ISO_FILE_PATH}" --user "${AUTH}" > /dev/null 2>&1; then
|
||||||
|
echo "✅ New ISO successfully uploaded."
|
||||||
|
else
|
||||||
|
echo "❌ Uploading the new ISO failed."
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
|
- name: 🔑 Generating a sha512 Hash of ISO, signing with the 'CI PGP DEPLOY ONLY' key, generate a success message file.
|
||||||
|
shell: bash
|
||||||
|
run: |
|
||||||
|
if [[ $(ls /opt/livebuild/*.iso 2>/dev/null | wc -l) -ne 1 ]]; then
|
||||||
|
echo "❌ There must be exactly one .iso file in the directory!"
|
||||||
|
exit 1
|
||||||
|
else
|
||||||
|
VAR_ISO_FILE_PATH=$(ls /opt/livebuild/*.iso)
|
||||||
|
VAR_ISO_FILE_NAME=$(basename "${VAR_ISO_FILE_PATH}")
|
||||||
|
echo "✅ ISO file found: ${VAR_ISO_FILE_NAME}"
|
||||||
|
fi
|
||||||
|
|
||||||
|
VAR_ISO_FILE_SHA512="${VAR_ISO_FILE_NAME}.sha512"
|
||||||
|
touch "${VAR_ISO_FILE_SHA512}"
|
||||||
|
sha512sum "${VAR_ISO_FILE_PATH}" | awk '{print $1}' >| "${VAR_ISO_FILE_SHA512}"
|
||||||
|
SIGNATURE_FILE="${VAR_ISO_FILE_SHA512}.sign"
|
||||||
|
touch "${SIGNATURE_FILE}"
|
||||||
|
export GNUPGHOME="$(pwd)/.gnupg"
|
||||||
|
gpg --batch --yes --armor --detach-sign --output "${SIGNATURE_FILE}" "${VAR_ISO_FILE_SHA512}"
|
||||||
|
|
||||||
|
timestamp=$(date -u +"%Y-%m-%dT%H:%M:%SZ")
|
||||||
|
VAR_DATE="$(date +%F)"
|
||||||
|
PRIVATE_FILE="LIVE_ISO_TRIXIE_1.private"
|
||||||
|
touch "${PRIVATE_FILE}"
|
||||||
|
cat << EOF >| "${PRIVATE_FILE}"
|
||||||
|
# SPDX-Version: 3.0
|
||||||
|
# SPDX-CreationInfo: ${VAR_DATE}; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
|
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
||||||
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
|
# SPDX-FileType: SOURCE
|
||||||
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
|
# SPDX-PackageName: CISS.debian.live.builder
|
||||||
|
# SPDX-Security-Contact: security@coresecret.eu
|
||||||
|
|
||||||
|
This file was automatically generated by the DEPLOY BOT on: "${timestamp}"
|
||||||
|
|
||||||
|
CISS.debian.live.builder ISO :
|
||||||
|
"${VAR_ISO_FILE_NAME}"
|
||||||
|
CISS.debian.live.builder ISO sha512 :
|
||||||
|
$(< "${VAR_ISO_FILE_SHA512}")
|
||||||
|
CISS.debian.live.builder ISO sha512 sign :
|
||||||
|
$(< "${SIGNATURE_FILE}")
|
||||||
|
|
||||||
|
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=text
|
||||||
|
EOF
|
||||||
|
|
||||||
|
- name: 🚧 Stash local changes (including untracked).
|
||||||
|
shell: bash
|
||||||
|
env:
|
||||||
|
GIT_SSH_COMMAND: "ssh -p 42842"
|
||||||
|
run: |
|
||||||
|
set -euo pipefail
|
||||||
|
### Temporarily store any local modifications or untracked files.
|
||||||
|
git stash push --include-untracked -m "ci-temp" || echo "✔️ Nothing to stash."
|
||||||
|
|
||||||
|
- name: 🔄 Sync with remote before commit using merge strategy.
|
||||||
|
shell: bash
|
||||||
|
env:
|
||||||
|
GIT_SSH_COMMAND: "ssh -p 42842"
|
||||||
|
run: |
|
||||||
|
set -euo pipefail
|
||||||
|
export GNUPGHOME="$(pwd)/.gnupg"
|
||||||
|
|
||||||
|
echo "🔄 Fetching origin/master ..."
|
||||||
|
git fetch origin master
|
||||||
|
|
||||||
|
echo "🔁 Merging origin/master into current branch ..."
|
||||||
|
git merge --no-edit origin/master || echo "✔️ Already up to date or fast-forward."
|
||||||
|
|
||||||
|
echo "📋 Post-merge status :"
|
||||||
|
git status
|
||||||
|
git log --oneline -n 5
|
||||||
|
|
||||||
|
- name: 🛠️ Restore stashed changes.
|
||||||
|
shell: bash
|
||||||
|
env:
|
||||||
|
GIT_SSH_COMMAND: "ssh -p 42842"
|
||||||
|
run: |
|
||||||
|
set -euo pipefail
|
||||||
|
### Apply previously stashed changes.
|
||||||
|
git stash pop || echo "✔️ Nothing to pop."
|
||||||
|
|
||||||
|
- name: 📦 Stage generated files.
|
||||||
|
shell: bash
|
||||||
|
env:
|
||||||
|
GIT_SSH_COMMAND: "ssh -p 42842"
|
||||||
|
run: |
|
||||||
|
set -euo pipefail
|
||||||
|
PRIVATE_FILE="LIVE_ISO_TRIXIE_1.private"
|
||||||
|
git add "${PRIVATE_FILE}" || echo "✔️ Nothing to add."
|
||||||
|
|
||||||
|
- name: 🔑 Commit and sign changes with CI metadata.
|
||||||
|
shell: bash
|
||||||
|
env:
|
||||||
|
GIT_SSH_COMMAND: "ssh -p 42842"
|
||||||
|
run: |
|
||||||
|
set -euo pipefail
|
||||||
|
export GNUPGHOME="$(pwd)/.gnupg"
|
||||||
|
|
||||||
|
if git diff --cached --quiet; then
|
||||||
|
echo "✔️ No staged changes to commit."
|
||||||
|
else
|
||||||
|
echo "📝 Committing changes with GPG signature ..."
|
||||||
|
|
||||||
|
### CI Metadata
|
||||||
|
TIMESTAMP_UTC="$(date -u +'%Y-%m-%dT%H:%M:%SZ')"
|
||||||
|
HOSTNAME="$(hostname -f || hostname)"
|
||||||
|
GIT_SHA="$(git rev-parse --short HEAD)"
|
||||||
|
GIT_REF="$(git symbolic-ref --short HEAD || echo detached)"
|
||||||
|
WORKFLOW_ID="${GITHUB_WORKFLOW:-render-md-to-html.yaml}"
|
||||||
|
CI_HEADER="X-CI-Metadata: ${GIT_REF}@${GIT_SHA} at ${TIMESTAMP_UTC} on ${HOSTNAME}"
|
||||||
|
|
||||||
|
COMMIT_MSG="DEPLOY BOT : 🔐 Auto-Generate PRIVATE LIVE ISO TRIXIE 1 [skip ci]
|
||||||
|
|
||||||
|
${CI_HEADER}
|
||||||
|
|
||||||
|
Generated at : ${TIMESTAMP_UTC}
|
||||||
|
Runner Host : ${HOSTNAME}
|
||||||
|
Workflow ID : ${WORKFLOW_ID}
|
||||||
|
Git Commit : ${GIT_SHA} HEAD -> ${GIT_REF}
|
||||||
|
"
|
||||||
|
|
||||||
|
echo "🔏 Commit message :"
|
||||||
|
echo "${COMMIT_MSG}"
|
||||||
|
git commit -S -m "${COMMIT_MSG}"
|
||||||
|
fi
|
||||||
|
|
||||||
|
- name: 🔁 Push back to repository.
|
||||||
|
shell: bash
|
||||||
|
env:
|
||||||
|
GIT_SSH_COMMAND: "ssh -p 42842"
|
||||||
|
run: |
|
||||||
|
set -euo pipefail
|
||||||
|
echo "📤 Pushing changes to ${GITHUB_REF_NAME} ..."
|
||||||
|
git push origin HEAD:${GITHUB_REF_NAME}
|
||||||
|
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=yaml
|
||||||
366
.gitea/workflows/generate_PUBLIC_iso.yaml
Normal file
366
.gitea/workflows/generate_PUBLIC_iso.yaml
Normal file
@@ -0,0 +1,366 @@
|
|||||||
|
# SPDX-Version: 3.0
|
||||||
|
# SPDX-CreationInfo: 2025-05-05; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
|
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
||||||
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
|
# SPDX-FileType: SOURCE
|
||||||
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
|
# SPDX-PackageName: CISS.debian.live.builder
|
||||||
|
# SPDX-Security-Contact: security@coresecret.eu
|
||||||
|
|
||||||
|
# Version Master V8.13.142.2025.10.14
|
||||||
|
|
||||||
|
name: 💙 Generating a PUBLIC Live ISO.
|
||||||
|
|
||||||
|
defaults:
|
||||||
|
run:
|
||||||
|
shell: bash
|
||||||
|
|
||||||
|
permissions:
|
||||||
|
contents: write
|
||||||
|
|
||||||
|
on:
|
||||||
|
push:
|
||||||
|
branches:
|
||||||
|
- master
|
||||||
|
paths:
|
||||||
|
- '.gitea/trigger/t_generate_PUBLIC.yaml'
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
generate-public-cdlb-trixie:
|
||||||
|
name: 💙 Generating a PUBLIC Live ISO.
|
||||||
|
runs-on: cdlb.trixie
|
||||||
|
|
||||||
|
container:
|
||||||
|
image: debian:trixie
|
||||||
|
|
||||||
|
steps:
|
||||||
|
- name: 🛠️ Basic Image Setup.
|
||||||
|
shell: bash
|
||||||
|
run: |
|
||||||
|
export DEBIAN_FRONTEND=noninteractive
|
||||||
|
apt-get update
|
||||||
|
apt-get upgrade -y
|
||||||
|
apt-get install -y --no-install-recommends \
|
||||||
|
apt-utils \
|
||||||
|
bash \
|
||||||
|
ca-certificates \
|
||||||
|
curl \
|
||||||
|
git \
|
||||||
|
gnupg \
|
||||||
|
openssh-client \
|
||||||
|
openssl \
|
||||||
|
perl \
|
||||||
|
sudo \
|
||||||
|
util-linux
|
||||||
|
|
||||||
|
- name: ⚙️ Check GnuPG Version.
|
||||||
|
shell: bash
|
||||||
|
run: |
|
||||||
|
gpg --version
|
||||||
|
|
||||||
|
- name: ⚙️ Preparing SSH Setup, SSH Deploy Key, Known Hosts, .config.
|
||||||
|
shell: bash
|
||||||
|
run: |
|
||||||
|
set -euo pipefail
|
||||||
|
var_wait=$(( RANDOM % 33 ))
|
||||||
|
printf "⏳ Waiting %s seconds to desynchronize parallel workflows...\n" "${var_wait}"
|
||||||
|
sleep "${var_wait}"
|
||||||
|
|
||||||
|
rm -rf ~/.ssh && mkdir -m700 ~/.ssh
|
||||||
|
|
||||||
|
### Private Key
|
||||||
|
echo "${{ secrets.SSH_MSW_DEPLOY_CORESECRET_DEV }}" >| ~/.ssh/id_ed25519
|
||||||
|
chmod 600 ~/.ssh/id_ed25519
|
||||||
|
|
||||||
|
### Scan git.coresecret.dev to fill ~/.ssh/known_hosts
|
||||||
|
ssh-keyscan -p 42842 git.coresecret.dev >| ~/.ssh/known_hosts
|
||||||
|
chmod 600 ~/.ssh/known_hosts
|
||||||
|
|
||||||
|
### Generate SSH Config for git.coresecret.dev Custom-Port
|
||||||
|
cat <<EOF >| ~/.ssh/config
|
||||||
|
Host git.coresecret.dev
|
||||||
|
HostName git.coresecret.dev
|
||||||
|
Port 42842
|
||||||
|
IdentityFile ~/.ssh/id_ed25519
|
||||||
|
StrictHostKeyChecking yes
|
||||||
|
UserKnownHostsFile ~/.ssh/known_hosts
|
||||||
|
EOF
|
||||||
|
chmod 600 ~/.ssh/config
|
||||||
|
|
||||||
|
### https://github.com/actions/checkout/issues/1843
|
||||||
|
- name: 🛠️ Using manual clone via SSH to circumvent Gitea SHA-256 object issues.
|
||||||
|
shell: bash
|
||||||
|
env:
|
||||||
|
### GITHUB_REF_NAME contains the branch name from the push event.
|
||||||
|
GITHUB_REF_NAME: ${{ github.ref_name }}
|
||||||
|
run: |
|
||||||
|
git clone --branch "${GITHUB_REF_NAME}" ssh://git@git.coresecret.dev:42842/msw/CISS.debian.live.builder.git .
|
||||||
|
git fetch --unshallow || echo "Nothing to fetch - already full clone."
|
||||||
|
|
||||||
|
- name: 🛠️ Cleaning the workspace.
|
||||||
|
shell: bash
|
||||||
|
run: |
|
||||||
|
git reset --hard
|
||||||
|
git clean -fd
|
||||||
|
|
||||||
|
- name: ⚙️ Importing the 'CI PGP DEPLOY ONLY' key.
|
||||||
|
shell: bash
|
||||||
|
run: |
|
||||||
|
set -euo pipefail
|
||||||
|
### GPG-Home relative to the Runner Workspace to avoid changing global files.
|
||||||
|
export GNUPGHOME="$(pwd)/.gnupg"
|
||||||
|
mkdir -m 700 "${GNUPGHOME}"
|
||||||
|
echo "${{ secrets.PGP_PUBKEY_CENTURION_ROOT_2025_X448 }}" >| centurion-root.PUB.asc
|
||||||
|
gpg --batch --import centurion-root.PUB.asc
|
||||||
|
echo "${{ secrets.PGP_MSW_DEPLOY_CORESECRET_DEV }}" >| ci-bot.sec.asc
|
||||||
|
gpg --batch --import ci-bot.sec.asc
|
||||||
|
### Trust the key automatically
|
||||||
|
KEY_ID=$(gpg --list-keys --with-colons | awk -F: '/^pub:/ {print $5}')
|
||||||
|
echo "trust-model always" >| "${GNUPGHOME}/gpg.conf"
|
||||||
|
|
||||||
|
- name: ⚙️ Configuring Git for signed CI/DEPLOY commits.
|
||||||
|
shell: bash
|
||||||
|
run: |
|
||||||
|
set -euo pipefail
|
||||||
|
export GNUPGHOME="$(pwd)/.gnupg"
|
||||||
|
git config user.name "Marc S. Weidner BOT"
|
||||||
|
git config user.email "msw+bot@coresecret.dev"
|
||||||
|
git config commit.gpgsign true
|
||||||
|
git config gpg.program gpg
|
||||||
|
git config gpg.format openpgp
|
||||||
|
|
||||||
|
- name: ⚙️ Preparing the build environment.
|
||||||
|
shell: bash
|
||||||
|
run: |
|
||||||
|
set -euo pipefail
|
||||||
|
mkdir -p /opt/config
|
||||||
|
mkdir -p /opt/livebuild
|
||||||
|
touch /opt/config/password.txt && chmod 0600 /opt/config/password.txt
|
||||||
|
touch /opt/config/authorized_keys && chmod 0600 /opt/config/authorized_keys
|
||||||
|
echo 'Mvnz#zENbf2vsAYEAbfPcnbDcmct7XefPXfRJxSQQH' >| /opt/config/password.txt
|
||||||
|
echo 'ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAINAYZDAqVZUk3LwJsqeVHKvLn8UKkFx642VBbiSS8uSY 2025_ciss.debian.live.ISO_PUBLIC_ONLY' >| /opt/config/authorized_keys
|
||||||
|
|
||||||
|
- name: 🛠️ Starting CISS.debian.live.builder. This may take a while ...
|
||||||
|
shell: bash
|
||||||
|
run: |
|
||||||
|
set -euo pipefail
|
||||||
|
sed -i '/^hardening_ssh.*/d' ciss_live_builder.sh
|
||||||
|
chmod 0755 ciss_live_builder.sh
|
||||||
|
timestamp=$(date -u +"%Y_%m_%dT%H_%M_%SZ")
|
||||||
|
### Change "--autobuild=" to the specific kernel version you need: '6.16.3+deb13-amd64'.
|
||||||
|
./ciss_live_builder.sh \
|
||||||
|
--autobuild=6.16.3+deb13-amd64 \
|
||||||
|
--architecture amd64 \
|
||||||
|
--build-directory /opt/livebuild \
|
||||||
|
--cdi \
|
||||||
|
--control "${timestamp}" \
|
||||||
|
--debug \
|
||||||
|
--root-password-file /opt/config/password.txt \
|
||||||
|
--ssh-port 42137 \
|
||||||
|
--ssh-pubkey /opt/config \
|
||||||
|
--trixie
|
||||||
|
|
||||||
|
- name: 📥 Checking Centurion Cloud for existing LIVE ISOs.
|
||||||
|
shell: bash
|
||||||
|
env:
|
||||||
|
NC_BASE: "https://cloud.e2ee.li"
|
||||||
|
SHARE_TOKEN: "${{ secrets.CENTURION_CLOUD_UL_USER_PUBLIC }}"
|
||||||
|
SHARE_PASS: "${{ secrets.CENTURION_CLOUD_UL_PASSWD_PUBLIC }}"
|
||||||
|
run: |
|
||||||
|
set -euo pipefail
|
||||||
|
SHARE_SUBDIR=""
|
||||||
|
|
||||||
|
echo "📥 Get directory listing via PROPFIND ..."
|
||||||
|
curl -s \
|
||||||
|
--user "${SHARE_TOKEN}:${SHARE_PASS}" \
|
||||||
|
-X PROPFIND \
|
||||||
|
-H "Depth: 1" \
|
||||||
|
"${NC_BASE}/public.php/webdav/${SHARE_SUBDIR}" \
|
||||||
|
-o propfind_public.xml
|
||||||
|
|
||||||
|
echo "📥 Filter .iso files from the PROPFIND response ..."
|
||||||
|
grep -oP '(?<=<d:href>)[^<]+\.iso(?=</d:href>)' propfind_public.xml >| public_iso_list.txt || true
|
||||||
|
|
||||||
|
if [[ -f public_iso_list.txt && -s public_iso_list.txt ]]; then
|
||||||
|
echo "💡 Old ISO files found and deleted :"
|
||||||
|
while IFS= read -r href; do
|
||||||
|
FILE_URL="${NC_BASE}${href}"
|
||||||
|
echo " Delete: ${FILE_URL}"
|
||||||
|
if curl -s \
|
||||||
|
--user "${SHARE_TOKEN}:${SHARE_PASS}" \
|
||||||
|
-X DELETE "${FILE_URL}"; then
|
||||||
|
echo " ✅ Successfully deleted: $(basename "${href}")"
|
||||||
|
else
|
||||||
|
echo " ❌ Error: $(basename "${href}") could not be deleted"
|
||||||
|
fi
|
||||||
|
done < public_iso_list.txt
|
||||||
|
else
|
||||||
|
echo "💡 No old ISO files found to delete."
|
||||||
|
fi
|
||||||
|
|
||||||
|
- name: 🛠️ Upload the ISO file to the Centurion Cloud (cloud.e2ee.li) via WebDAV.
|
||||||
|
shell: bash
|
||||||
|
env:
|
||||||
|
NC_BASE: "https://cloud.e2ee.li"
|
||||||
|
SHARE_TOKEN: "${{ secrets.CENTURION_CLOUD_UL_USER_PUBLIC }}"
|
||||||
|
SHARE_PASS: "${{ secrets.CENTURION_CLOUD_UL_PASSWD_PUBLIC }}"
|
||||||
|
run: |
|
||||||
|
set -euo pipefail
|
||||||
|
if [[ $(ls /opt/livebuild/*.iso 2>/dev/null | wc -l) -ne 1 ]]; then
|
||||||
|
echo "❌ There must be exactly one .iso file in the directory!"
|
||||||
|
exit 1
|
||||||
|
else
|
||||||
|
VAR_ISO_FILE_PATH=$(ls /opt/livebuild/*.iso)
|
||||||
|
VAR_ISO_FILE_NAME=$(basename "${VAR_ISO_FILE_PATH}")
|
||||||
|
echo "✅ ISO file found: ${VAR_ISO_FILE_NAME}"
|
||||||
|
fi
|
||||||
|
|
||||||
|
AUTH="${SHARE_TOKEN}:${SHARE_PASS}"
|
||||||
|
if curl --retry 2 "${NC_BASE}"/public.php/webdav/"${VAR_ISO_FILE_NAME}" \
|
||||||
|
--upload-file "${VAR_ISO_FILE_PATH}" --user "${AUTH}" > /dev/null 2>&1; then
|
||||||
|
echo "✅ New ISO successfully uploaded."
|
||||||
|
else
|
||||||
|
echo "❌ Uploading the new ISO failed."
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
|
- name: 🔑 Generating a sha512 Hash of ISO, signing with the 'CI PGP DEPLOY ONLY' key, generate a success message file.
|
||||||
|
shell: bash
|
||||||
|
run: |
|
||||||
|
if [[ $(ls /opt/livebuild/*.iso 2>/dev/null | wc -l) -ne 1 ]]; then
|
||||||
|
echo "❌ There must be exactly one .iso file in the directory!"
|
||||||
|
exit 1
|
||||||
|
else
|
||||||
|
VAR_ISO_FILE_PATH=$(ls /opt/livebuild/*.iso)
|
||||||
|
VAR_ISO_FILE_NAME=$(basename "${VAR_ISO_FILE_PATH}")
|
||||||
|
echo "✅ ISO file found: ${VAR_ISO_FILE_NAME}"
|
||||||
|
fi
|
||||||
|
|
||||||
|
VAR_ISO_FILE_SHA512="${VAR_ISO_FILE_NAME}.sha512"
|
||||||
|
touch "${VAR_ISO_FILE_SHA512}"
|
||||||
|
sha512sum "${VAR_ISO_FILE_PATH}" | awk '{print $1}' >| "${VAR_ISO_FILE_SHA512}"
|
||||||
|
SIGNATURE_FILE="${VAR_ISO_FILE_SHA512}.sign"
|
||||||
|
touch "${SIGNATURE_FILE}"
|
||||||
|
export GNUPGHOME="$(pwd)/.gnupg"
|
||||||
|
gpg --batch --yes --armor --detach-sign --output "${SIGNATURE_FILE}" "${VAR_ISO_FILE_SHA512}"
|
||||||
|
|
||||||
|
timestamp=$(date -u +"%Y-%m-%dT%H:%M:%SZ")
|
||||||
|
VAR_DATE="$(date +%F)"
|
||||||
|
PRIVATE_FILE="LIVE_ISO.public"
|
||||||
|
touch "${PRIVATE_FILE}"
|
||||||
|
cat << EOF >| "${PRIVATE_FILE}"
|
||||||
|
# SPDX-Version: 3.0
|
||||||
|
# SPDX-CreationInfo: ${VAR_DATE}; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
|
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
||||||
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
|
# SPDX-FileType: SOURCE
|
||||||
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
|
# SPDX-PackageName: CISS.debian.live.builder
|
||||||
|
# SPDX-Security-Contact: security@coresecret.eu
|
||||||
|
|
||||||
|
This file was automatically generated by the DEPLOY BOT on: "${timestamp}"
|
||||||
|
|
||||||
|
CISS.debian.live.builder ISO :
|
||||||
|
"${VAR_ISO_FILE_NAME}"
|
||||||
|
CISS.debian.live.builder ISO sha512 :
|
||||||
|
$(< "${VAR_ISO_FILE_SHA512}")
|
||||||
|
CISS.debian.live.builder ISO sha512 sign :
|
||||||
|
$(< "${SIGNATURE_FILE}")
|
||||||
|
|
||||||
|
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=text
|
||||||
|
EOF
|
||||||
|
|
||||||
|
- name: 🚧 Stash local changes (including untracked).
|
||||||
|
shell: bash
|
||||||
|
env:
|
||||||
|
GIT_SSH_COMMAND: "ssh -p 42842"
|
||||||
|
run: |
|
||||||
|
set -euo pipefail
|
||||||
|
### Temporarily store any local modifications or untracked files.
|
||||||
|
git stash push --include-untracked -m "ci-temp" || echo "✔️ Nothing to stash."
|
||||||
|
|
||||||
|
- name: 🔄 Sync with remote before commit using merge strategy.
|
||||||
|
shell: bash
|
||||||
|
env:
|
||||||
|
GIT_SSH_COMMAND: "ssh -p 42842"
|
||||||
|
run: |
|
||||||
|
set -euo pipefail
|
||||||
|
export GNUPGHOME="$(pwd)/.gnupg"
|
||||||
|
|
||||||
|
echo "🔄 Fetching origin/master ..."
|
||||||
|
git fetch origin master
|
||||||
|
|
||||||
|
echo "🔁 Merging origin/master into current branch ..."
|
||||||
|
git merge --no-edit origin/master || echo "✔️ Already up to date or fast-forward."
|
||||||
|
|
||||||
|
echo "📋 Post-merge status :"
|
||||||
|
git status
|
||||||
|
git log --oneline -n 5
|
||||||
|
|
||||||
|
- name: 🛠️ Restore stashed changes.
|
||||||
|
shell: bash
|
||||||
|
env:
|
||||||
|
GIT_SSH_COMMAND: "ssh -p 42842"
|
||||||
|
run: |
|
||||||
|
set -euo pipefail
|
||||||
|
### Apply previously stashed changes.
|
||||||
|
git stash pop || echo "✔️ Nothing to pop."
|
||||||
|
|
||||||
|
- name: 📦 Stage generated files.
|
||||||
|
shell: bash
|
||||||
|
env:
|
||||||
|
GIT_SSH_COMMAND: "ssh -p 42842"
|
||||||
|
run: |
|
||||||
|
set -euo pipefail
|
||||||
|
PRIVATE_FILE="LIVE_ISO.public"
|
||||||
|
git add "${PRIVATE_FILE}" || echo "✔️ Nothing to add."
|
||||||
|
|
||||||
|
- name: 🔑 Commit and sign changes with CI metadata.
|
||||||
|
shell: bash
|
||||||
|
env:
|
||||||
|
GIT_SSH_COMMAND: "ssh -p 42842"
|
||||||
|
run: |
|
||||||
|
set -euo pipefail
|
||||||
|
export GNUPGHOME="$(pwd)/.gnupg"
|
||||||
|
|
||||||
|
if git diff --cached --quiet; then
|
||||||
|
echo "✔️ No staged changes to commit."
|
||||||
|
else
|
||||||
|
echo "📝 Committing changes with GPG signature ..."
|
||||||
|
|
||||||
|
### CI Metadata
|
||||||
|
TIMESTAMP_UTC="$(date -u +'%Y-%m-%dT%H:%M:%SZ')"
|
||||||
|
HOSTNAME="$(hostname -f || hostname)"
|
||||||
|
GIT_SHA="$(git rev-parse --short HEAD)"
|
||||||
|
GIT_REF="$(git symbolic-ref --short HEAD || echo detached)"
|
||||||
|
WORKFLOW_ID="${GITHUB_WORKFLOW:-render-md-to-html.yaml}"
|
||||||
|
CI_HEADER="X-CI-Metadata: ${GIT_REF}@${GIT_SHA} at ${TIMESTAMP_UTC} on ${HOSTNAME}"
|
||||||
|
|
||||||
|
COMMIT_MSG="DEPLOY BOT : 💙 Auto-Generate PUBLIC LIVE ISO [skip ci]
|
||||||
|
|
||||||
|
${CI_HEADER}
|
||||||
|
|
||||||
|
Generated at : ${TIMESTAMP_UTC}
|
||||||
|
Runner Host : ${HOSTNAME}
|
||||||
|
Workflow ID : ${WORKFLOW_ID}
|
||||||
|
Git Commit : ${GIT_SHA} HEAD -> ${GIT_REF}
|
||||||
|
"
|
||||||
|
|
||||||
|
echo "🔏 Commit message :"
|
||||||
|
echo "${COMMIT_MSG}"
|
||||||
|
git commit -S -m "${COMMIT_MSG}"
|
||||||
|
fi
|
||||||
|
|
||||||
|
- name: 🔁 Push back to repository.
|
||||||
|
shell: bash
|
||||||
|
env:
|
||||||
|
GIT_SSH_COMMAND: "ssh -p 42842"
|
||||||
|
run: |
|
||||||
|
set -euo pipefail
|
||||||
|
echo "📤 Pushing changes to ${GITHUB_REF_NAME} ..."
|
||||||
|
git push origin HEAD:${GITHUB_REF_NAME}
|
||||||
|
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=yaml
|
||||||
345
.gitea/workflows/linter_char_scripts.yaml
Normal file
345
.gitea/workflows/linter_char_scripts.yaml
Normal file
@@ -0,0 +1,345 @@
|
|||||||
|
# SPDX-Version: 3.0
|
||||||
|
# SPDX-CreationInfo: 2025-05-05; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
|
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
||||||
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
|
# SPDX-FileType: SOURCE
|
||||||
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
|
# SPDX-PackageName: CISS.debian.live.builder
|
||||||
|
# SPDX-Security-Contact: security@coresecret.eu
|
||||||
|
|
||||||
|
# Version Master V8.13.142.2025.10.14
|
||||||
|
|
||||||
|
# Gitea Workflow: Shell-Script Linting
|
||||||
|
#
|
||||||
|
# This workflow scans all '*.sh', '*.zsh', '*.chroot' and all files with Shebang (#!) for:
|
||||||
|
# 1. Windows CRLF line endings
|
||||||
|
# 2. unauthorized control characters (C0 control characters except \t, \n)
|
||||||
|
# 3. non-ASCII (ambiguous UTF) characters
|
||||||
|
#
|
||||||
|
# Findings are collected and at the end of the run with file, line number,
|
||||||
|
# and the respective character in the Runner output.
|
||||||
|
|
||||||
|
name: 🛡️ Shell Script Linting
|
||||||
|
|
||||||
|
on:
|
||||||
|
push:
|
||||||
|
branches:
|
||||||
|
- master
|
||||||
|
pull_request:
|
||||||
|
branches:
|
||||||
|
- master
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
shell-script-linter:
|
||||||
|
name: 🛡️ Shell Script Linting
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
|
||||||
|
steps:
|
||||||
|
- name: ⚙️ Preparing SSH Setup, SSH Deploy Key, Known Hosts, .config.
|
||||||
|
shell: bash
|
||||||
|
run: |
|
||||||
|
set -euo pipefail
|
||||||
|
var_wait=$(( RANDOM % 33 ))
|
||||||
|
printf "⏳ Waiting %s seconds to desynchronize parallel workflows...\n" "${var_wait}"
|
||||||
|
sleep "${var_wait}"
|
||||||
|
|
||||||
|
rm -rf ~/.ssh && mkdir -m700 ~/.ssh
|
||||||
|
|
||||||
|
### Private Key
|
||||||
|
echo "${{ secrets.SSH_MSW_DEPLOY_CORESECRET_DEV }}" >| ~/.ssh/id_ed25519
|
||||||
|
chmod 600 ~/.ssh/id_ed25519
|
||||||
|
|
||||||
|
### Scan git.coresecret.dev to fill ~/.ssh/known_hosts
|
||||||
|
ssh-keyscan -p 42842 git.coresecret.dev >| ~/.ssh/known_hosts
|
||||||
|
chmod 600 ~/.ssh/known_hosts
|
||||||
|
|
||||||
|
### Generate SSH Config for git.coresecret.dev Custom-Port
|
||||||
|
cat <<EOF >| ~/.ssh/config
|
||||||
|
Host git.coresecret.dev
|
||||||
|
HostName git.coresecret.dev
|
||||||
|
Port 42842
|
||||||
|
IdentityFile ~/.ssh/id_ed25519
|
||||||
|
StrictHostKeyChecking yes
|
||||||
|
UserKnownHostsFile ~/.ssh/known_hosts
|
||||||
|
EOF
|
||||||
|
chmod 600 ~/.ssh/config
|
||||||
|
|
||||||
|
### https://github.com/actions/checkout/issues/1843
|
||||||
|
- name: 🛠️ Using manual clone via SSH to circumvent Gitea SHA-256 object issues.
|
||||||
|
shell: bash
|
||||||
|
env:
|
||||||
|
### GITHUB_REF_NAME contains the branch name from the push event.
|
||||||
|
GITHUB_REF_NAME: ${{ github.ref_name }}
|
||||||
|
run: |
|
||||||
|
set -euo pipefail
|
||||||
|
git clone --branch "${GITHUB_REF_NAME}" ssh://git@git.coresecret.dev:42842/msw/CISS.debian.live.builder.git .
|
||||||
|
git fetch --unshallow || echo "Nothing to fetch - already full clone."
|
||||||
|
|
||||||
|
- name: 🛠️ Cleaning the workspace.
|
||||||
|
shell: bash
|
||||||
|
run: |
|
||||||
|
set -euo pipefail
|
||||||
|
git reset --hard
|
||||||
|
git clean -fd
|
||||||
|
|
||||||
|
- name: ⚙️ Importing the 'CI PGP DEPLOY ONLY' key.
|
||||||
|
shell: bash
|
||||||
|
run: |
|
||||||
|
set -euo pipefail
|
||||||
|
### GPG-Home relative to the Runner Workspace to avoid changing global files.
|
||||||
|
export GNUPGHOME="$(pwd)/.gnupg"
|
||||||
|
mkdir -m 700 "${GNUPGHOME}"
|
||||||
|
echo "${{ secrets.PGP_MSW_DEPLOY_CORESECRET_DEV }}" >| ci-bot.sec.asc
|
||||||
|
gpg --batch --import ci-bot.sec.asc
|
||||||
|
### Trust the key automatically
|
||||||
|
KEY_ID=$(gpg --list-keys --with-colons | awk -F: '/^pub:/ {print $5}')
|
||||||
|
echo "trust-model always" >| "${GNUPGHOME}/gpg.conf"
|
||||||
|
|
||||||
|
- name: ⚙️ Configuring Git for signed CI/DEPLOY commits.
|
||||||
|
shell: bash
|
||||||
|
run: |
|
||||||
|
set -euo pipefail
|
||||||
|
export GNUPGHOME="$(pwd)/.gnupg"
|
||||||
|
git config user.name "Marc S. Weidner BOT"
|
||||||
|
git config user.email "msw+bot@coresecret.dev"
|
||||||
|
git config commit.gpgsign true
|
||||||
|
git config gpg.program gpg
|
||||||
|
git config gpg.format openpgp
|
||||||
|
|
||||||
|
- name: ⚙️ Convert APT sources to HTTPS.
|
||||||
|
shell: bash
|
||||||
|
run: |
|
||||||
|
set -euo pipefail
|
||||||
|
sed -i 's|http://\(archive\.ubuntu\.com\|security\.ubuntu\.com\)|https://\1|g' /etc/apt/sources.list
|
||||||
|
sed -i 's|http://\(archive\.ubuntu\.com\|security\.ubuntu\.com\)|https://\1|g' /etc/apt/sources.list.d/*.list || true
|
||||||
|
|
||||||
|
- name: 🛠️ Install dependencies.
|
||||||
|
shell: bash
|
||||||
|
run: |
|
||||||
|
### Install grep with Perl-regex support, falls noch nicht vorhanden
|
||||||
|
apt-get update
|
||||||
|
apt-get upgrade -y
|
||||||
|
apt-get install -y grep
|
||||||
|
|
||||||
|
- name: 🔍 Lint shell scripts
|
||||||
|
shell: bash
|
||||||
|
run: |
|
||||||
|
# -------------------------------
|
||||||
|
# STEP 1: Find target files.
|
||||||
|
#
|
||||||
|
# We capture:
|
||||||
|
# - All files '*.sh', '*.zsh', '*.chroot'
|
||||||
|
# - All files whose first line begins with "#!" (shebang)
|
||||||
|
# -------------------------------
|
||||||
|
mapfile -t files_to_check < <(
|
||||||
|
find . \
|
||||||
|
-path './.git' -prune -o \
|
||||||
|
-type f \( \
|
||||||
|
-iname '*.sh' -o \
|
||||||
|
-iname '*.zsh' -o \
|
||||||
|
-iname '*.chroot' -o \
|
||||||
|
-exec grep -Iq '^#!' {} \; \
|
||||||
|
\) -print
|
||||||
|
)
|
||||||
|
|
||||||
|
# -------------------------------
|
||||||
|
# STEP 2: Regex definitions
|
||||||
|
#
|
||||||
|
# - CRLF_REGEX Carriage Return (\r) for Windows CRLF
|
||||||
|
# - CTRL_REGEX C0 control characters except Tab (\x09) and Newline (\x0A)
|
||||||
|
# - Range: [\x00-\x08\x0B-\x0C\x0E-\x1F\x7F]
|
||||||
|
# - NON_ASCII_REGEX All bytes -> 0x7F, except emoji characters in defined ranges
|
||||||
|
#
|
||||||
|
# Emoji ranges that we exclude:
|
||||||
|
# - \x{1F300}-\x{1F5FF} Misc Symbols & Pictographs
|
||||||
|
# - \x{1F600}-\x{1F64F} Emoticons
|
||||||
|
# - \x{1F680}-\x{1F6FF} Transport & Map Symbols
|
||||||
|
# - \x{1F900}-\x{1F9FF} Supplemental Symbols & Pictographs
|
||||||
|
# - \x{2600}-\x{26FF} Miscellaneous Symbols
|
||||||
|
# - \x{2700}-\x{27BF} Dingbats
|
||||||
|
# -------------------------------
|
||||||
|
|
||||||
|
CRLF_REGEX=$'\r'
|
||||||
|
CTRL_REGEX='[\x00-\x08\x0B-\x0C\x0E-\x1F\x7F]'
|
||||||
|
NON_ASCII_REGEX='(?![\x{1F300}-\x{1F5FF}\x{1F600}-\x{1F64F}\x{1F680}-\x{1F6FF}\x{1F900}-\x{1F9FF}\x{2600}-\x{26FF}\x{2700}-\x{27BF}])[^\x00-\x7F]'
|
||||||
|
|
||||||
|
# -------------------------------
|
||||||
|
# STEP 3: Accumulator for findings
|
||||||
|
# -------------------------------
|
||||||
|
findings=""
|
||||||
|
|
||||||
|
# -------------------------------
|
||||||
|
# STEP 4: Perform all checks for each file
|
||||||
|
# -------------------------------
|
||||||
|
for file in "${files_to_check[@]}"; do
|
||||||
|
#
|
||||||
|
# 4.1: CRLF detection
|
||||||
|
# grep -nP returns "lineno:<line with CR>"
|
||||||
|
# -------------------------------
|
||||||
|
while IFS=: read -r lineno _rest; do
|
||||||
|
findings+="${file}: CRLF-found at line ${lineno}: <CR>"$'\n'
|
||||||
|
done < <(grep -nP "${CRLF_REGEX}" "${file}" || true)
|
||||||
|
|
||||||
|
#
|
||||||
|
# 4.2: Unallowed control characters
|
||||||
|
# grep -nP -o returns "lineno:<matched-char>"
|
||||||
|
# -------------------------------
|
||||||
|
while IFS=: read -r lineno char; do
|
||||||
|
findings+="${file}: control-char at line ${lineno}: ${char}"$'\n'
|
||||||
|
done < <(grep -nP -o "${CTRL_REGEX}" "${file}" || true)
|
||||||
|
|
||||||
|
#
|
||||||
|
# 4.3: Non-ASCII characters with emoji exception
|
||||||
|
# grep -nP -o returns "lineno:<matched-char>"
|
||||||
|
# -------------------------------
|
||||||
|
while IFS=: read -r lineno char; do
|
||||||
|
findings+="${file}: non-ascii at line ${lineno}: ${char}"$'\n'
|
||||||
|
done < <(grep -nP -o "${NON_ASCII_REGEX}" "${file}" || true)
|
||||||
|
done
|
||||||
|
|
||||||
|
# -------------------------------
|
||||||
|
# STEP 5: Output results
|
||||||
|
# -------------------------------
|
||||||
|
if [[ -n "${findings}" ]]; then
|
||||||
|
echo -e "⚠️ Linting issues detected:\n"
|
||||||
|
echo -e "${findings}"
|
||||||
|
timestamp=$(date -u +"%Y-%m-%dT%H:%M:%SZ")
|
||||||
|
VAR_DATE="$(date +%F)"
|
||||||
|
PRIVATE_FILE="LINTER_RESULTS.txt"
|
||||||
|
touch "${PRIVATE_FILE}"
|
||||||
|
cat << EOF >| "${PRIVATE_FILE}"
|
||||||
|
# SPDX-Version: 3.0
|
||||||
|
# SPDX-CreationInfo: ${VAR_DATE}; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
|
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
||||||
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
|
# SPDX-FileType: SOURCE
|
||||||
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
|
# SPDX-PackageName: CISS.debian.live.builder
|
||||||
|
# SPDX-Security-Contact: security@coresecret.eu
|
||||||
|
|
||||||
|
This file was automatically generated by the DEPLOY BOT on: "${timestamp}"
|
||||||
|
|
||||||
|
⚠️ The last linter check was NOT successful. ⚠️
|
||||||
|
|
||||||
|
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=text
|
||||||
|
EOF
|
||||||
|
else
|
||||||
|
echo "✅ No issues found in shell scripts."
|
||||||
|
timestamp=$(date -u +"%Y-%m-%dT%H:%M:%SZ")
|
||||||
|
VAR_DATE="$(date +%F)"
|
||||||
|
PRIVATE_FILE="LINTER_RESULTS.txt"
|
||||||
|
touch "${PRIVATE_FILE}"
|
||||||
|
cat << EOF >| "${PRIVATE_FILE}"
|
||||||
|
# SPDX-Version: 3.0
|
||||||
|
# SPDX-CreationInfo: ${VAR_DATE}; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
|
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
||||||
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
|
# SPDX-FileType: SOURCE
|
||||||
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
|
# SPDX-PackageName: CISS.debian.live.builder
|
||||||
|
# SPDX-Security-Contact: security@coresecret.eu
|
||||||
|
|
||||||
|
This file was automatically generated by the DEPLOY BOT on: "${timestamp}"
|
||||||
|
|
||||||
|
✅ The last linter check was successful. ✅
|
||||||
|
|
||||||
|
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=text
|
||||||
|
EOF
|
||||||
|
fi
|
||||||
|
|
||||||
|
- name: 🚧 Stash local changes (including untracked).
|
||||||
|
shell: bash
|
||||||
|
env:
|
||||||
|
GIT_SSH_COMMAND: "ssh -p 42842"
|
||||||
|
run: |
|
||||||
|
set -euo pipefail
|
||||||
|
### Temporarily store any local modifications or untracked files.
|
||||||
|
git stash push --include-untracked -m "ci-temp" || echo "✔️ Nothing to stash."
|
||||||
|
|
||||||
|
- name: 🔄 Sync with remote before commit using merge strategy.
|
||||||
|
shell: bash
|
||||||
|
env:
|
||||||
|
GIT_SSH_COMMAND: "ssh -p 42842"
|
||||||
|
run: |
|
||||||
|
set -euo pipefail
|
||||||
|
export GNUPGHOME="$(pwd)/.gnupg"
|
||||||
|
|
||||||
|
echo "🔄 Fetching origin/master ..."
|
||||||
|
git fetch origin master
|
||||||
|
|
||||||
|
echo "🔁 Merging origin/master into current branch ..."
|
||||||
|
git merge --no-edit origin/master || echo "✔️ Already up to date or fast-forward."
|
||||||
|
|
||||||
|
echo "📋 Post-merge status :"
|
||||||
|
git status
|
||||||
|
git log --oneline -n 5
|
||||||
|
|
||||||
|
- name: 🛠️ Restore stashed changes.
|
||||||
|
shell: bash
|
||||||
|
env:
|
||||||
|
GIT_SSH_COMMAND: "ssh -p 42842"
|
||||||
|
run: |
|
||||||
|
set -euo pipefail
|
||||||
|
### Apply previously stashed changes.
|
||||||
|
git stash pop || echo "✔️ Nothing to pop."
|
||||||
|
|
||||||
|
- name: 📦 Stage generated files.
|
||||||
|
shell: bash
|
||||||
|
env:
|
||||||
|
GIT_SSH_COMMAND: "ssh -p 42842"
|
||||||
|
run: |
|
||||||
|
set -euo pipefail
|
||||||
|
PRIVATE_FILE="LINTER_RESULTS.txt"
|
||||||
|
git add "${PRIVATE_FILE}" || echo "✔️ Nothing to add."
|
||||||
|
|
||||||
|
- name: 🔑 Commit and sign changes with CI metadata.
|
||||||
|
shell: bash
|
||||||
|
env:
|
||||||
|
GIT_SSH_COMMAND: "ssh -p 42842"
|
||||||
|
run: |
|
||||||
|
set -euo pipefail
|
||||||
|
export GNUPGHOME="$(pwd)/.gnupg"
|
||||||
|
|
||||||
|
if git diff --cached --quiet; then
|
||||||
|
echo "✔️ No staged changes to commit."
|
||||||
|
else
|
||||||
|
echo "📝 Committing changes with GPG signature ..."
|
||||||
|
|
||||||
|
### CI Metadata
|
||||||
|
TIMESTAMP_UTC="$(date -u +'%Y-%m-%dT%H:%M:%SZ')"
|
||||||
|
HOSTNAME="$(hostname -f || hostname)"
|
||||||
|
GIT_SHA="$(git rev-parse --short HEAD)"
|
||||||
|
GIT_REF="$(git symbolic-ref --short HEAD || echo detached)"
|
||||||
|
WORKFLOW_ID="${GITHUB_WORKFLOW:-render-md-to-html.yaml}"
|
||||||
|
CI_HEADER="X-CI-Metadata: ${GIT_REF}@${GIT_SHA} at ${TIMESTAMP_UTC} on ${HOSTNAME}"
|
||||||
|
|
||||||
|
COMMIT_MSG="DEPLOY BOT : 🛡️ Shell Script Linting [skip ci]
|
||||||
|
|
||||||
|
${CI_HEADER}
|
||||||
|
|
||||||
|
Generated at : ${TIMESTAMP_UTC}
|
||||||
|
Runner Host : ${HOSTNAME}
|
||||||
|
Workflow ID : ${WORKFLOW_ID}
|
||||||
|
Git Commit : ${GIT_SHA} HEAD -> ${GIT_REF}
|
||||||
|
"
|
||||||
|
|
||||||
|
echo "🔏 Commit message :"
|
||||||
|
echo "${COMMIT_MSG}"
|
||||||
|
git commit -S -m "${COMMIT_MSG}"
|
||||||
|
fi
|
||||||
|
|
||||||
|
- name: 🔁 Push back to repository.
|
||||||
|
shell: bash
|
||||||
|
env:
|
||||||
|
GIT_SSH_COMMAND: "ssh -p 42842"
|
||||||
|
run: |
|
||||||
|
set -euo pipefail
|
||||||
|
echo "📤 Pushing changes to ${GITHUB_REF_NAME} ..."
|
||||||
|
git push origin HEAD:${GITHUB_REF_NAME}
|
||||||
|
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=yaml
|
||||||
@@ -2,16 +2,16 @@
|
|||||||
# SPDX-CreationInfo: 2025-05-05; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-CreationInfo: 2025-05-05; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
||||||
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
# SPDX-FileCopyrightText: 2024–2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-FileType: SOURCE
|
# SPDX-FileType: SOURCE
|
||||||
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
# SPDX-PackageName: CISS.debian.live.builder
|
# SPDX-PackageName: CISS.debian.live.builder
|
||||||
# SPDX-Security-Contact: security@coresecret.eu
|
# SPDX-Security-Contact: security@coresecret.eu
|
||||||
|
|
||||||
name: Retrieve the DNSSEC status at the time of updating the repository.
|
# Version Master V8.13.142.2025.10.14
|
||||||
kind: pipeline
|
|
||||||
type: docker
|
name: 🛡️ Retrieve DNSSEC status of coresecret.dev.
|
||||||
|
|
||||||
permissions:
|
permissions:
|
||||||
contents: write
|
contents: write
|
||||||
@@ -20,15 +20,24 @@ on:
|
|||||||
push:
|
push:
|
||||||
branches:
|
branches:
|
||||||
- master
|
- master
|
||||||
|
paths:
|
||||||
|
- '.gitea/trigger/t_generate_dns.yaml'
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
build-dnssec-diagram:
|
build-dnssec-diagram:
|
||||||
|
name: 🛡️ Retrieve DNSSEC status of coresecret.dev.
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
|
|
||||||
steps:
|
steps:
|
||||||
- name: Prepare SSH Setup, SSH Deploy Key, Known Hosts, config.
|
- name: ⚙️ Preparing SSH Setup, SSH Deploy Key, Known Hosts, .config.
|
||||||
|
shell: bash
|
||||||
run: |
|
run: |
|
||||||
rm -rf ~/.ssh
|
set -euo pipefail
|
||||||
mkdir -p ~/.ssh
|
var_wait=$(( RANDOM % 33 ))
|
||||||
|
printf "⏳ Waiting %s seconds to desynchronize parallel workflows...\n" "${var_wait}"
|
||||||
|
sleep "${var_wait}"
|
||||||
|
|
||||||
|
rm -rf ~/.ssh && mkdir -m700 ~/.ssh
|
||||||
|
|
||||||
### Private Key
|
### Private Key
|
||||||
echo "${{ secrets.SSH_MSW_DEPLOY_CORESECRET_DEV }}" >| ~/.ssh/id_ed25519
|
echo "${{ secrets.SSH_MSW_DEPLOY_CORESECRET_DEV }}" >| ~/.ssh/id_ed25519
|
||||||
@@ -50,31 +59,27 @@ jobs:
|
|||||||
chmod 600 ~/.ssh/config
|
chmod 600 ~/.ssh/config
|
||||||
|
|
||||||
### https://github.com/actions/checkout/issues/1843
|
### https://github.com/actions/checkout/issues/1843
|
||||||
- name: Use manual clone via SSH to circumvent Gitea SHA-256 object issues.
|
- name: 🛠️ Using manual clone via SSH to circumvent Gitea SHA-256 object issues.
|
||||||
run: |
|
shell: bash
|
||||||
git clone --branch "${GITHUB_REF_NAME}" ssh://git@git.coresecret.dev:42842/msw/CISS.debian.live.builder.git .
|
|
||||||
git fetch --unshallow || echo "Nothing to fetch - already full clone."
|
|
||||||
env:
|
env:
|
||||||
### GITHUB_REF_NAME contains the branch name from the push event.
|
### GITHUB_REF_NAME contains the branch name from the push event.
|
||||||
GITHUB_REF_NAME: ${{ github.ref_name }}
|
GITHUB_REF_NAME: ${{ github.ref_name }}
|
||||||
|
|
||||||
- name: Clean workspace.
|
|
||||||
run: |
|
run: |
|
||||||
|
set -euo pipefail
|
||||||
|
git clone --branch "${GITHUB_REF_NAME}" ssh://git@git.coresecret.dev:42842/msw/CISS.debian.live.builder.git .
|
||||||
|
git fetch --unshallow || echo "Nothing to fetch - already full clone."
|
||||||
|
|
||||||
|
- name: 🛠️ Cleaning the workspace.
|
||||||
|
shell: bash
|
||||||
|
run: |
|
||||||
|
set -euo pipefail
|
||||||
git reset --hard
|
git reset --hard
|
||||||
git clean -fd
|
git clean -fd
|
||||||
|
|
||||||
- name: Convert APT sources to HTTPS.
|
- name: ⚙️ Importing the 'CI PGP DEPLOY ONLY' key.
|
||||||
run: |
|
shell: bash
|
||||||
sed -i 's|http://\(archive\.ubuntu\.com\|security\.ubuntu\.com\)|https://\1|g' /etc/apt/sources.list
|
|
||||||
sed -i 's|http://\(archive\.ubuntu\.com\|security\.ubuntu\.com\)|https://\1|g' /etc/apt/sources.list.d/*.list || true
|
|
||||||
|
|
||||||
- name: Install DNSViz.
|
|
||||||
run: |
|
|
||||||
sudo apt-get update
|
|
||||||
sudo apt-get install -y dnsviz
|
|
||||||
|
|
||||||
- name: Import CI PGP DEPLOY ONLY Key.
|
|
||||||
run: |
|
run: |
|
||||||
|
set -euo pipefail
|
||||||
### GPG-Home relative to the Runner Workspace to avoid changing global files.
|
### GPG-Home relative to the Runner Workspace to avoid changing global files.
|
||||||
export GNUPGHOME="$(pwd)/.gnupg"
|
export GNUPGHOME="$(pwd)/.gnupg"
|
||||||
mkdir -m 700 "${GNUPGHOME}"
|
mkdir -m 700 "${GNUPGHOME}"
|
||||||
@@ -83,10 +88,11 @@ jobs:
|
|||||||
### Trust the key automatically
|
### Trust the key automatically
|
||||||
KEY_ID=$(gpg --list-keys --with-colons | awk -F: '/^pub:/ {print $5}')
|
KEY_ID=$(gpg --list-keys --with-colons | awk -F: '/^pub:/ {print $5}')
|
||||||
echo "trust-model always" >| "${GNUPGHOME}/gpg.conf"
|
echo "trust-model always" >| "${GNUPGHOME}/gpg.conf"
|
||||||
shell: bash
|
|
||||||
|
|
||||||
- name: Configure Git for signed CI DEPLOY commits.
|
- name: ⚙️ Configuring Git for signed CI/DEPLOY commits.
|
||||||
|
shell: bash
|
||||||
run: |
|
run: |
|
||||||
|
set -euo pipefail
|
||||||
export GNUPGHOME="$(pwd)/.gnupg"
|
export GNUPGHOME="$(pwd)/.gnupg"
|
||||||
git config user.name "Marc S. Weidner BOT"
|
git config user.name "Marc S. Weidner BOT"
|
||||||
git config user.email "msw+bot@coresecret.dev"
|
git config user.email "msw+bot@coresecret.dev"
|
||||||
@@ -94,37 +100,123 @@ jobs:
|
|||||||
git config gpg.program gpg
|
git config gpg.program gpg
|
||||||
git config gpg.format openpgp
|
git config gpg.format openpgp
|
||||||
|
|
||||||
- name: Ensure docs/SECURITY/ directory exists.
|
- name: ⚙️ Convert APT sources to HTTPS.
|
||||||
|
shell: bash
|
||||||
|
run: |
|
||||||
|
set -euo pipefail
|
||||||
|
sed -i 's|http://\(archive\.ubuntu\.com\|security\.ubuntu\.com\)|https://\1|g' /etc/apt/sources.list
|
||||||
|
sed -i 's|http://\(archive\.ubuntu\.com\|security\.ubuntu\.com\)|https://\1|g' /etc/apt/sources.list.d/*.list || true
|
||||||
|
|
||||||
|
- name: 🛠️ Install DNSViz.
|
||||||
|
shell: bash
|
||||||
|
run: |
|
||||||
|
sudo apt-get update
|
||||||
|
sudo apt-get install -y dnsviz
|
||||||
|
|
||||||
|
- name: ⚙️ Ensure docs/SECURITY/ directory exists.
|
||||||
|
shell: bash
|
||||||
run: |
|
run: |
|
||||||
mkdir -p docs/SECURITY/
|
mkdir -p docs/SECURITY/
|
||||||
rm -f docs/SECURITY/coresecret.dev.png
|
rm -f docs/SECURITY/coresecret.dev.png
|
||||||
|
|
||||||
- name: Prepare DNS Cache.
|
- name: 🛠️ Prepare DNS Cache.
|
||||||
|
shell: bash
|
||||||
run: |
|
run: |
|
||||||
sudo apt-get install -y dnsutils
|
sudo apt-get install -y dnsutils
|
||||||
dig +dnssec +multi coresecret.dev @8.8.8.8
|
dig +dnssec +multi coresecret.dev @8.8.8.8
|
||||||
|
|
||||||
- name: Retrieve Zone Dump and generate .png Visualization.
|
- name: 🛠️ Retrieve Zone Dump and generate .png Visualization.
|
||||||
|
shell: bash
|
||||||
run: |
|
run: |
|
||||||
dnsviz probe -s 8.8.8.8 -R SOA,A,AAAA,CAA,CDS,CDNSKEY,LOC,HTTPS,MX,NS,TXT coresecret.dev >| coresecret.dev.json
|
dnsviz probe -s 8.8.8.8 -R SOA,A,AAAA,CAA,CDS,CDNSKEY,LOC,HTTPS,MX,NS,TXT coresecret.dev >| coresecret.dev.json
|
||||||
dnsviz graph -T png < coresecret.dev.json >| docs/SECURITY/coresecret.dev.png
|
dnsviz graph -T png < coresecret.dev.json >| docs/SECURITY/coresecret.dev.png
|
||||||
|
|
||||||
- name: Stage generated files.
|
- name: 🚧 Stash local changes (including untracked).
|
||||||
run: |
|
shell: bash
|
||||||
git add docs/SECURITY/*.png
|
|
||||||
env:
|
env:
|
||||||
GIT_SSH_COMMAND: "ssh -p 42842"
|
GIT_SSH_COMMAND: "ssh -p 42842"
|
||||||
|
|
||||||
- name: Commit and Sign changes.
|
|
||||||
run: |
|
run: |
|
||||||
|
set -euo pipefail
|
||||||
|
### Temporarily store any local modifications or untracked files.
|
||||||
|
git stash push --include-untracked -m "ci-temp" || echo "✔️ Nothing to stash."
|
||||||
|
|
||||||
|
- name: 🔄 Sync with remote before commit using merge strategy.
|
||||||
|
shell: bash
|
||||||
|
env:
|
||||||
|
GIT_SSH_COMMAND: "ssh -p 42842"
|
||||||
|
run: |
|
||||||
|
set -euo pipefail
|
||||||
export GNUPGHOME="$(pwd)/.gnupg"
|
export GNUPGHOME="$(pwd)/.gnupg"
|
||||||
git commit -S -m "DEPLOY BOT: Auto-Generate DNSSEC Status [skip ci]" || echo "No Changes, nothing to Sign or to Commit."
|
|
||||||
env:
|
|
||||||
GIT_SSH_COMMAND: "ssh -p 42842"
|
|
||||||
|
|
||||||
- name: Push back to Repository.
|
echo "🔄 Fetching origin/master ..."
|
||||||
run: |
|
git fetch origin master
|
||||||
git push origin HEAD:${GITHUB_REF_NAME}
|
|
||||||
|
echo "🔁 Merging origin/master into current branch ..."
|
||||||
|
git merge --no-edit origin/master || echo "✔️ Already up to date or fast-forward."
|
||||||
|
|
||||||
|
echo "📋 Post-merge status :"
|
||||||
|
git status
|
||||||
|
git log --oneline -n 5
|
||||||
|
|
||||||
|
- name: 🛠️ Restore stashed changes.
|
||||||
|
shell: bash
|
||||||
env:
|
env:
|
||||||
GIT_SSH_COMMAND: "ssh -p 42842"
|
GIT_SSH_COMMAND: "ssh -p 42842"
|
||||||
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=yaml
|
run: |
|
||||||
|
set -euo pipefail
|
||||||
|
### Apply previously stashed changes.
|
||||||
|
git stash pop || echo "✔️ Nothing to pop."
|
||||||
|
|
||||||
|
- name: 📦 Stage generated files.
|
||||||
|
shell: bash
|
||||||
|
env:
|
||||||
|
GIT_SSH_COMMAND: "ssh -p 42842"
|
||||||
|
run: |
|
||||||
|
set -euo pipefail
|
||||||
|
git add docs/SECURITY/*.png || echo "✔️ Nothing to add."
|
||||||
|
|
||||||
|
- name: 🔑 Commit and sign changes with CI metadata.
|
||||||
|
shell: bash
|
||||||
|
env:
|
||||||
|
GIT_SSH_COMMAND: "ssh -p 42842"
|
||||||
|
run: |
|
||||||
|
set -euo pipefail
|
||||||
|
export GNUPGHOME="$(pwd)/.gnupg"
|
||||||
|
|
||||||
|
if git diff --cached --quiet; then
|
||||||
|
echo "✔️ No staged changes to commit."
|
||||||
|
else
|
||||||
|
echo "📝 Committing changes with GPG signature ..."
|
||||||
|
|
||||||
|
### CI Metadata
|
||||||
|
TIMESTAMP_UTC="$(date -u +'%Y-%m-%dT%H:%M:%SZ')"
|
||||||
|
HOSTNAME="$(hostname -f || hostname)"
|
||||||
|
GIT_SHA="$(git rev-parse --short HEAD)"
|
||||||
|
GIT_REF="$(git symbolic-ref --short HEAD || echo detached)"
|
||||||
|
WORKFLOW_ID="${GITHUB_WORKFLOW:-render-md-to-html.yaml}"
|
||||||
|
CI_HEADER="X-CI-Metadata: ${GIT_REF}@${GIT_SHA} at ${TIMESTAMP_UTC} on ${HOSTNAME}"
|
||||||
|
|
||||||
|
COMMIT_MSG="DEPLOY BOT : 🛡️ Auto-Generate DNSSEC Status [skip ci]
|
||||||
|
|
||||||
|
${CI_HEADER}
|
||||||
|
|
||||||
|
Generated at : ${TIMESTAMP_UTC}
|
||||||
|
Runner Host : ${HOSTNAME}
|
||||||
|
Workflow ID : ${WORKFLOW_ID}
|
||||||
|
Git Commit : ${GIT_SHA} HEAD -> ${GIT_REF}
|
||||||
|
"
|
||||||
|
|
||||||
|
echo "🔏 Commit message :"
|
||||||
|
echo "${COMMIT_MSG}"
|
||||||
|
git commit -S -m "${COMMIT_MSG}"
|
||||||
|
fi
|
||||||
|
|
||||||
|
- name: 🔁 Push back to repository.
|
||||||
|
shell: bash
|
||||||
|
env:
|
||||||
|
GIT_SSH_COMMAND: "ssh -p 42842"
|
||||||
|
run: |
|
||||||
|
set -euo pipefail
|
||||||
|
echo "📤 Pushing changes to ${GITHUB_REF_NAME} ..."
|
||||||
|
git push origin HEAD:${GITHUB_REF_NAME}
|
||||||
|
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=yaml
|
||||||
|
|||||||
215
.gitea/workflows/render-dot-to-png.yaml
Normal file
215
.gitea/workflows/render-dot-to-png.yaml
Normal file
@@ -0,0 +1,215 @@
|
|||||||
|
# SPDX-Version: 3.0
|
||||||
|
# SPDX-CreationInfo: 2025-05-05; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
|
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
||||||
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
|
# SPDX-FileType: SOURCE
|
||||||
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
|
# SPDX-PackageName: CISS.debian.live.builder
|
||||||
|
# SPDX-Security-Contact: security@coresecret.eu
|
||||||
|
|
||||||
|
# Version Master V8.13.142.2025.10.14
|
||||||
|
|
||||||
|
name: 🔁 Render Graphviz Diagrams.
|
||||||
|
|
||||||
|
permissions:
|
||||||
|
contents: write
|
||||||
|
|
||||||
|
on:
|
||||||
|
push:
|
||||||
|
branches:
|
||||||
|
- master
|
||||||
|
paths:
|
||||||
|
- "**/*.gv"
|
||||||
|
- "**/*.dot"
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
build-graphiz-diagrams:
|
||||||
|
name: 🔁 Render Graphviz Diagrams.
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
|
||||||
|
steps:
|
||||||
|
- name: ⚙️ Preparing SSH Setup, SSH Deploy Key, Known Hosts, .config.
|
||||||
|
shell: bash
|
||||||
|
run: |
|
||||||
|
set -euo pipefail
|
||||||
|
var_wait=$(( RANDOM % 33 ))
|
||||||
|
printf "⏳ Waiting %s seconds to desynchronize parallel workflows...\n" "${var_wait}"
|
||||||
|
sleep "${var_wait}"
|
||||||
|
|
||||||
|
rm -rf ~/.ssh && mkdir -m700 ~/.ssh
|
||||||
|
|
||||||
|
### Private Key
|
||||||
|
echo "${{ secrets.SSH_MSW_DEPLOY_CORESECRET_DEV }}" >| ~/.ssh/id_ed25519
|
||||||
|
chmod 600 ~/.ssh/id_ed25519
|
||||||
|
|
||||||
|
### Scan git.coresecret.dev to fill ~/.ssh/known_hosts
|
||||||
|
ssh-keyscan -p 42842 git.coresecret.dev >| ~/.ssh/known_hosts
|
||||||
|
chmod 600 ~/.ssh/known_hosts
|
||||||
|
|
||||||
|
### Generate SSH Config for git.coresecret.dev Custom-Port
|
||||||
|
cat <<EOF >| ~/.ssh/config
|
||||||
|
Host git.coresecret.dev
|
||||||
|
HostName git.coresecret.dev
|
||||||
|
Port 42842
|
||||||
|
IdentityFile ~/.ssh/id_ed25519
|
||||||
|
StrictHostKeyChecking yes
|
||||||
|
UserKnownHostsFile ~/.ssh/known_hosts
|
||||||
|
EOF
|
||||||
|
chmod 600 ~/.ssh/config
|
||||||
|
|
||||||
|
### https://github.com/actions/checkout/issues/1843
|
||||||
|
- name: 🛠️ Using manual clone via SSH to circumvent Gitea SHA-256 object issues.
|
||||||
|
shell: bash
|
||||||
|
env:
|
||||||
|
### GITHUB_REF_NAME contains the branch name from the push event.
|
||||||
|
GITHUB_REF_NAME: ${{ github.ref_name }}
|
||||||
|
run: |
|
||||||
|
set -euo pipefail
|
||||||
|
git clone --branch "${GITHUB_REF_NAME}" ssh://git@git.coresecret.dev:42842/msw/CISS.debian.live.builder.git .
|
||||||
|
git fetch --unshallow || echo "Nothing to fetch - already full clone."
|
||||||
|
|
||||||
|
- name: 🛠️ Cleaning the workspace.
|
||||||
|
shell: bash
|
||||||
|
run: |
|
||||||
|
set -euo pipefail
|
||||||
|
git reset --hard
|
||||||
|
git clean -fd
|
||||||
|
|
||||||
|
- name: ⚙️ Importing the 'CI PGP DEPLOY ONLY' key.
|
||||||
|
shell: bash
|
||||||
|
run: |
|
||||||
|
set -euo pipefail
|
||||||
|
### GPG-Home relative to the Runner Workspace to avoid changing global files.
|
||||||
|
export GNUPGHOME="$(pwd)/.gnupg"
|
||||||
|
mkdir -m 700 "${GNUPGHOME}"
|
||||||
|
echo "${{ secrets.PGP_MSW_DEPLOY_CORESECRET_DEV }}" >| ci-bot.sec.asc
|
||||||
|
gpg --batch --import ci-bot.sec.asc
|
||||||
|
### Trust the key automatically
|
||||||
|
KEY_ID=$(gpg --list-keys --with-colons | awk -F: '/^pub:/ {print $5}')
|
||||||
|
echo "trust-model always" >| "${GNUPGHOME}/gpg.conf"
|
||||||
|
|
||||||
|
- name: ⚙️ Configuring Git for signed CI/DEPLOY commits.
|
||||||
|
shell: bash
|
||||||
|
run: |
|
||||||
|
set -euo pipefail
|
||||||
|
export GNUPGHOME="$(pwd)/.gnupg"
|
||||||
|
git config user.name "Marc S. Weidner BOT"
|
||||||
|
git config user.email "msw+bot@coresecret.dev"
|
||||||
|
git config commit.gpgsign true
|
||||||
|
git config gpg.program gpg
|
||||||
|
git config gpg.format openpgp
|
||||||
|
|
||||||
|
- name: ⚙️ Convert APT sources to HTTPS.
|
||||||
|
shell: bash
|
||||||
|
run: |
|
||||||
|
set -euo pipefail
|
||||||
|
sed -i 's|http://\(archive\.ubuntu\.com\|security\.ubuntu\.com\)|https://\1|g' /etc/apt/sources.list
|
||||||
|
sed -i 's|http://\(archive\.ubuntu\.com\|security\.ubuntu\.com\)|https://\1|g' /etc/apt/sources.list.d/*.list || true
|
||||||
|
|
||||||
|
- name: 🛠️ Install Graphviz.
|
||||||
|
shell: bash
|
||||||
|
run: |
|
||||||
|
set -euo pipefail
|
||||||
|
sudo apt-get update
|
||||||
|
sudo apt-get install -y graphviz
|
||||||
|
|
||||||
|
- name: 🛠️ Render all .dot / .gv to PNG.
|
||||||
|
shell: bash
|
||||||
|
run: |
|
||||||
|
set -euo pipefail
|
||||||
|
find . -type f \( -name "*.dot" -o -name "*.gv" \) | while read file; do
|
||||||
|
out="${file%.*}.png"
|
||||||
|
dot -Tpng "${file}" -o "${out}"
|
||||||
|
done
|
||||||
|
|
||||||
|
- name: 🚧 Stash local changes (including untracked).
|
||||||
|
shell: bash
|
||||||
|
env:
|
||||||
|
GIT_SSH_COMMAND: "ssh -p 42842"
|
||||||
|
run: |
|
||||||
|
set -euo pipefail
|
||||||
|
### Temporarily store any local modifications or untracked files.
|
||||||
|
git stash push --include-untracked -m "ci-temp" || echo "✔️ Nothing to stash."
|
||||||
|
|
||||||
|
- name: 🔄 Sync with remote before commit using merge strategy.
|
||||||
|
shell: bash
|
||||||
|
env:
|
||||||
|
GIT_SSH_COMMAND: "ssh -p 42842"
|
||||||
|
run: |
|
||||||
|
set -euo pipefail
|
||||||
|
export GNUPGHOME="$(pwd)/.gnupg"
|
||||||
|
|
||||||
|
echo "🔄 Fetching origin/master ..."
|
||||||
|
git fetch origin master
|
||||||
|
|
||||||
|
echo "🔁 Merging origin/master into current branch ..."
|
||||||
|
git merge --no-edit origin/master || echo "✔️ Already up to date or fast-forward."
|
||||||
|
|
||||||
|
echo "📋 Post-merge status :"
|
||||||
|
git status
|
||||||
|
git log --oneline -n 5
|
||||||
|
|
||||||
|
- name: 🛠️ Restore stashed changes.
|
||||||
|
shell: bash
|
||||||
|
env:
|
||||||
|
GIT_SSH_COMMAND: "ssh -p 42842"
|
||||||
|
run: |
|
||||||
|
set -euo pipefail
|
||||||
|
### Apply previously stashed changes.
|
||||||
|
git stash pop || echo "✔️ Nothing to pop."
|
||||||
|
|
||||||
|
- name: 📦 Stage generated files.
|
||||||
|
shell: bash
|
||||||
|
env:
|
||||||
|
GIT_SSH_COMMAND: "ssh -p 42842"
|
||||||
|
run: |
|
||||||
|
set -euo pipefail
|
||||||
|
git add *.png || echo "✔️ Nothing to add."
|
||||||
|
|
||||||
|
- name: 🔑 Commit and sign changes with CI metadata.
|
||||||
|
shell: bash
|
||||||
|
env:
|
||||||
|
GIT_SSH_COMMAND: "ssh -p 42842"
|
||||||
|
run: |
|
||||||
|
set -euo pipefail
|
||||||
|
export GNUPGHOME="$(pwd)/.gnupg"
|
||||||
|
|
||||||
|
if git diff --cached --quiet; then
|
||||||
|
echo "✔️ No staged changes to commit."
|
||||||
|
else
|
||||||
|
echo "📝 Committing changes with GPG signature ..."
|
||||||
|
|
||||||
|
### CI Metadata
|
||||||
|
TIMESTAMP_UTC="$(date -u +'%Y-%m-%dT%H:%M:%SZ')"
|
||||||
|
HOSTNAME="$(hostname -f || hostname)"
|
||||||
|
GIT_SHA="$(git rev-parse --short HEAD)"
|
||||||
|
GIT_REF="$(git symbolic-ref --short HEAD || echo detached)"
|
||||||
|
WORKFLOW_ID="${GITHUB_WORKFLOW:-render-md-to-html.yaml}"
|
||||||
|
CI_HEADER="X-CI-Metadata: ${GIT_REF}@${GIT_SHA} at ${TIMESTAMP_UTC} on ${HOSTNAME}"
|
||||||
|
|
||||||
|
COMMIT_MSG="DEPLOY BOT : 🔁 Auto-Generate PNG from *.dot. [skip ci]
|
||||||
|
|
||||||
|
${CI_HEADER}
|
||||||
|
|
||||||
|
Generated at : ${TIMESTAMP_UTC}
|
||||||
|
Runner Host : ${HOSTNAME}
|
||||||
|
Workflow ID : ${WORKFLOW_ID}
|
||||||
|
Git Commit : ${GIT_SHA} HEAD -> ${GIT_REF}
|
||||||
|
"
|
||||||
|
|
||||||
|
echo "🔏 Commit message :"
|
||||||
|
echo "${COMMIT_MSG}"
|
||||||
|
git commit -S -m "${COMMIT_MSG}"
|
||||||
|
fi
|
||||||
|
|
||||||
|
- name: 🔁 Push back to repository.
|
||||||
|
shell: bash
|
||||||
|
env:
|
||||||
|
GIT_SSH_COMMAND: "ssh -p 42842"
|
||||||
|
run: |
|
||||||
|
set -euo pipefail
|
||||||
|
echo "📤 Pushing changes to ${GITHUB_REF_NAME} ..."
|
||||||
|
git push origin HEAD:${GITHUB_REF_NAME}
|
||||||
|
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=yaml
|
||||||
3
.gitignore
vendored
3
.gitignore
vendored
@@ -2,7 +2,7 @@
|
|||||||
# SPDX-CreationInfo: 2025-05-05; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-CreationInfo: 2025-05-05; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
||||||
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
# SPDX-FileCopyrightText: 2024–2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-FileType: SOURCE
|
# SPDX-FileType: SOURCE
|
||||||
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
@@ -16,5 +16,6 @@ target/
|
|||||||
*.DS_Store
|
*.DS_Store
|
||||||
*.log
|
*.log
|
||||||
*.ps1
|
*.ps1
|
||||||
|
config.mk
|
||||||
Thumbs.db
|
Thumbs.db
|
||||||
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=conf
|
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=conf
|
||||||
|
|||||||
28
.shellcheckrc
Normal file
28
.shellcheckrc
Normal file
@@ -0,0 +1,28 @@
|
|||||||
|
# SPDX-Version: 3.0
|
||||||
|
# SPDX-CreationInfo: 2025-06-17; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
|
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.installer.git
|
||||||
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
|
# SPDX-FileType: SOURCE
|
||||||
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
|
# SPDX-PackageName: CISS.debian.installer
|
||||||
|
# SPDX-Security-Contact: security@coresecret.eu
|
||||||
|
|
||||||
|
encoding=utf-8
|
||||||
|
external-sources=true
|
||||||
|
shell=bash
|
||||||
|
source-path=~/lib
|
||||||
|
source-path=~/scripts
|
||||||
|
source-path=~/var
|
||||||
|
|
||||||
|
enable=avoid-nullary-conditions
|
||||||
|
enable=check-extra-masked-returns
|
||||||
|
enable=check-set-e-suppressed
|
||||||
|
enable=check-unassigned-uppercase
|
||||||
|
enable=deprecate-which
|
||||||
|
enable=quote-safe-variables
|
||||||
|
enable=require-double-brackets
|
||||||
|
enable=require-variable-braces
|
||||||
|
|
||||||
|
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=conf
|
||||||
@@ -2,7 +2,7 @@
|
|||||||
# SPDX-CreationInfo: 2025-05-05; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-CreationInfo: 2025-05-05; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
||||||
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
# SPDX-FileCopyrightText: 2024–2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-FileType: SOURCE
|
# SPDX-FileType: SOURCE
|
||||||
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
@@ -10,10 +10,10 @@
|
|||||||
# SPDX-Security-Contact: security@coresecret.eu
|
# SPDX-Security-Contact: security@coresecret.eu
|
||||||
properties_SPDX-Version="3.0"
|
properties_SPDX-Version="3.0"
|
||||||
properties_SPDX-ExternalRef="GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git"
|
properties_SPDX-ExternalRef="GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git"
|
||||||
properties_SPDX-FileCopyrightText="2024–2025; WEIDNER, Marc S.; <msw@coresecret.dev>"
|
properties_SPDX-FileCopyrightText="2024-2025; WEIDNER, Marc S.; <msw@coresecret.dev>"
|
||||||
properties_SPDX-License-Identifier="EUPL-1.2 OR LicenseRef-CCLA-1.0"
|
properties_SPDX-License-Identifier="EUPL-1.2 OR LicenseRef-CCLA-1.0"
|
||||||
properties_SPDX-LicenseComment="This file is part of the CISS.hardened.installer framework."
|
properties_SPDX-LicenseComment="This file is part of the CISS.debian.installer.secure framework."
|
||||||
properties_SPDX-PackageName="CISS.debian.live.builder"
|
properties_SPDX-PackageName="CISS.debian.live.builder"
|
||||||
properties_SPDX-Security-Contact="security@coresecret.eu"
|
properties_SPDX-Security-Contact="security@coresecret.eu"
|
||||||
properties_version="V8.02.644.2025.05.31"
|
properties_version="V8.13.142.2025.10.14"
|
||||||
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=conf
|
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=conf
|
||||||
@@ -6,7 +6,7 @@ Creator: Person: Marc S. Weidner (Centurion Intelligence Consulting Agency)
|
|||||||
Created: 2025-05-07T12:00:00Z
|
Created: 2025-05-07T12:00:00Z
|
||||||
Package: CISS.debian.live.builder
|
Package: CISS.debian.live.builder
|
||||||
PackageName: CISS.debian.live.builder
|
PackageName: CISS.debian.live.builder
|
||||||
PackageVersion: Master V8.02.644.2025.05.31
|
PackageVersion: Master V8.13.142.2025.10.14
|
||||||
PackageSupplier: Organization: Centurion Intelligence Consulting Agency
|
PackageSupplier: Organization: Centurion Intelligence Consulting Agency
|
||||||
PackageDownloadLocation: https://git.coresecret.dev/msw/CISS.debian.live.builder
|
PackageDownloadLocation: https://git.coresecret.dev/msw/CISS.debian.live.builder
|
||||||
PackageHomePage: https://git.coresecret.dev/msw/CISS.debian.live.builder
|
PackageHomePage: https://git.coresecret.dev/msw/CISS.debian.live.builder
|
||||||
|
|||||||
16
LINTER_RESULTS.txt
Normal file
16
LINTER_RESULTS.txt
Normal file
@@ -0,0 +1,16 @@
|
|||||||
|
# SPDX-Version: 3.0
|
||||||
|
# SPDX-CreationInfo: 2025-10-14; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
|
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
||||||
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
|
# SPDX-FileType: SOURCE
|
||||||
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
|
# SPDX-PackageName: CISS.debian.live.builder
|
||||||
|
# SPDX-Security-Contact: security@coresecret.eu
|
||||||
|
|
||||||
|
This file was automatically generated by the DEPLOY BOT on: "2025-10-14T19:37:03Z"
|
||||||
|
|
||||||
|
⚠️ The last linter check was NOT successful. ⚠️
|
||||||
|
|
||||||
|
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=text
|
||||||
27
LIVE_ISO.public
Normal file
27
LIVE_ISO.public
Normal file
@@ -0,0 +1,27 @@
|
|||||||
|
# SPDX-Version: 3.0
|
||||||
|
# SPDX-CreationInfo: 2025-10-14; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
|
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
||||||
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
|
# SPDX-FileType: SOURCE
|
||||||
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
|
# SPDX-PackageName: CISS.debian.live.builder
|
||||||
|
# SPDX-Security-Contact: security@coresecret.eu
|
||||||
|
|
||||||
|
This file was automatically generated by the DEPLOY BOT on: "2025-10-14T22:23:27Z"
|
||||||
|
|
||||||
|
CISS.debian.live.builder ISO :
|
||||||
|
"ciss-debian-live-2025_10_14T21_30_07Z-amd64.hybrid.iso"
|
||||||
|
CISS.debian.live.builder ISO sha512 :
|
||||||
|
442037d11eb48f4adbd1a3da17cf36062ec6be816627c38fe814458840020f212c551b96d5e785c4372fa09fc11fd9529f34166530b1e1f5ce9335abadb5f771
|
||||||
|
CISS.debian.live.builder ISO sha512 sign :
|
||||||
|
-----BEGIN PGP SIGNATURE-----
|
||||||
|
|
||||||
|
iHUEABYKAB0WIQSqYnPMNKGz69afyHA85KY4hzOwIQUCaO7NXwAKCRA85KY4hzOw
|
||||||
|
IT3LAP4uP8glLMDEpUntKJQTiPqSYjGUyIFoKmsgALGPJcnnoQD/fcz4Mq12mF32
|
||||||
|
jf4ETKQBqlxuQyLTPvPFhLsrBbDD0AI=
|
||||||
|
=/UNR
|
||||||
|
-----END PGP SIGNATURE-----
|
||||||
|
|
||||||
|
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=text
|
||||||
27
LIVE_ISO_TRIXIE_0.private
Normal file
27
LIVE_ISO_TRIXIE_0.private
Normal file
@@ -0,0 +1,27 @@
|
|||||||
|
# SPDX-Version: 3.0
|
||||||
|
# SPDX-CreationInfo: 2025-10-14; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
|
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
||||||
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
|
# SPDX-FileType: SOURCE
|
||||||
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
|
# SPDX-PackageName: CISS.debian.live.builder
|
||||||
|
# SPDX-Security-Contact: security@coresecret.eu
|
||||||
|
|
||||||
|
This file was automatically generated by the DEPLOY BOT on: "2025-10-14T20:32:28Z"
|
||||||
|
|
||||||
|
CISS.debian.live.builder ISO :
|
||||||
|
"ciss-debian-live-2025_10_14T19_36_59Z-amd64.hybrid.iso"
|
||||||
|
CISS.debian.live.builder ISO sha512 :
|
||||||
|
57559f9b9c5e50dad6a5b2023d992c26b8f4d25dd0d45ffa5cfd479ee623287e2c2eead70016267b848c5910db5ba5c4e2dfeeb12cca6f59fe455dad886c51d9
|
||||||
|
CISS.debian.live.builder ISO sha512 sign :
|
||||||
|
-----BEGIN PGP SIGNATURE-----
|
||||||
|
|
||||||
|
iHUEABYKAB0WIQSqYnPMNKGz69afyHA85KY4hzOwIQUCaO6zXAAKCRA85KY4hzOw
|
||||||
|
Idq2AQDRmgHRGnX1bn+cNV5JirecSke0IAwlAjEXOl4tFoQlewEA0s2R1A3OQjIq
|
||||||
|
fAhdl2wltVNT5+jUg6EUj3FE3kVPaQo=
|
||||||
|
=fmxg
|
||||||
|
-----END PGP SIGNATURE-----
|
||||||
|
|
||||||
|
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=text
|
||||||
27
LIVE_ISO_TRIXIE_1.private
Normal file
27
LIVE_ISO_TRIXIE_1.private
Normal file
@@ -0,0 +1,27 @@
|
|||||||
|
# SPDX-Version: 3.0
|
||||||
|
# SPDX-CreationInfo: 2025-10-14; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
|
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
||||||
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
|
# SPDX-FileType: SOURCE
|
||||||
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
|
# SPDX-PackageName: CISS.debian.live.builder
|
||||||
|
# SPDX-Security-Contact: security@coresecret.eu
|
||||||
|
|
||||||
|
This file was automatically generated by the DEPLOY BOT on: "2025-10-14T21:28:34Z"
|
||||||
|
|
||||||
|
CISS.debian.live.builder ISO :
|
||||||
|
"ciss-debian-live-2025_10_14T20_33_51Z-amd64.hybrid.iso"
|
||||||
|
CISS.debian.live.builder ISO sha512 :
|
||||||
|
4a47a1ed0986b67774047b2bfc6fdd53753fa8f301f8376b23ccde1f5187aeffbca7fce3194a3d7b61278630291a1d2d954a289da712c064326eb6b7020c228c
|
||||||
|
CISS.debian.live.builder ISO sha512 sign :
|
||||||
|
-----BEGIN PGP SIGNATURE-----
|
||||||
|
|
||||||
|
iHUEABYKAB0WIQSqYnPMNKGz69afyHA85KY4hzOwIQUCaO7AggAKCRA85KY4hzOw
|
||||||
|
IWpdAP4xCxUP4V0lOBE1u7+wEOoEmXiRC10Va4Hf2UXjH1BSVwEAsz/cMaGt+rJT
|
||||||
|
q0i+5EftPavvIst48aXQsp7QKjyNewM=
|
||||||
|
=x3/T
|
||||||
|
-----END PGP SIGNATURE-----
|
||||||
|
|
||||||
|
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=text
|
||||||
274
README.md
274
README.md
@@ -2,17 +2,17 @@
|
|||||||
gitea: none
|
gitea: none
|
||||||
include_toc: true
|
include_toc: true
|
||||||
---
|
---
|
||||||
[](https://git.coresecret.dev/msw/CISS.debian.live.builder)
|
[](https://git.coresecret.dev/msw/CISS.debian.live.builder)
|
||||||
|
|
||||||
[](https://eupl.eu/1.2/en/)
|
[](https://eupl.eu/1.2/en/)
|
||||||
[](https://opensource.org/license/eupl-1-2)
|
[](https://opensource.org/license/eupl-1-2)
|
||||||
[](https://www.gnu.org/software/bash/)
|
[](https://www.gnu.org/software/bash/)
|
||||||
[](https://shellcheck.net/)
|
[](https://shellcheck.net/)
|
||||||
[](https://github.com/mvdan/sh)
|
[](https://github.com/mvdan/sh)
|
||||||
[](https://google.github.io/styleguide/shellguide.html)
|
[](https://google.github.io/styleguide/shellguide.html)
|
||||||
|
|
||||||
[](https://docs.gitea.com/)
|
[](https://docs.gitea.com/)
|
||||||
[](https://www.jetbrains.com/store/?section=personal&billing=yearly)
|
[](https://www.jetbrains.com/store/?section=personal&billing=yearly)
|
||||||
[](https://keepassxc.org/)
|
[](https://keepassxc.org/)
|
||||||
[](https://www.netcup.com/de)
|
[](https://www.netcup.com/de)
|
||||||
[](https://coresecret.eu/)
|
[](https://coresecret.eu/)
|
||||||
@@ -25,32 +25,61 @@ include_toc: true
|
|||||||
|
|
||||||
**Centurion Intelligence Consulting Agency Information Security Standard**<br>
|
**Centurion Intelligence Consulting Agency Information Security Standard**<br>
|
||||||
*Debian Live Build Generator for hardened live environment and CISS Debian Installer*<br>
|
*Debian Live Build Generator for hardened live environment and CISS Debian Installer*<br>
|
||||||
**Master Version**: 8.02<br>
|
**Master Version**: 8.13<br>
|
||||||
**Build**: V8.02.644.2025.05.31<br>
|
**Build**: V8.13.142.2025.10.14<br>
|
||||||
|
|
||||||
This shell wrapper automates the creation of a Debian Bookworm live ISO hardened according to the latest best practices in server
|
This shell wrapper automates the creation of a Debian Bookworm live ISO hardened according to the latest best practices in server
|
||||||
and service security. It integrates into your build pipeline to deliver an isolated, robust environment suitable for
|
and service security. It integrates into your build pipeline to deliver an isolated, robust environment suitable for
|
||||||
cloud deployment or unattended installations via the forthcoming `CISS.debian.installer`.
|
cloud deployment or unattended installations via the forthcoming `CISS.debian.installer`. Additionally, automated CI workflows
|
||||||
|
based on Gitea Actions are provided, enabling reproducible ISO generation. A generic ISO is automatically built upon significant
|
||||||
|
changes and made publicly available for download. The latest generic ISO is available at:
|
||||||
|
**[PUBLIC CISS.debian.live.ISO](/docs/DL_PUB_ISO.md)**
|
||||||
|
|
||||||
Check out more:
|
Check out more:
|
||||||
* [CenturionNet Services](https://coresecret.eu/cnet/)
|
* [CenturionNet Services](https://coresecret.eu/cnet/)
|
||||||
* [CenturionDNS Resolver](https://dns.eddns.eu/)
|
* [CenturionDNS Resolver](https://eddns.eu/)
|
||||||
* [CenturionDNS Blocklist](https://dns.eddns.eu/blocklists/centurion_titanium_ultimate.txt)
|
* [CenturionDNS Blocklist](https://dns.eddns.eu/blocklists/centurion_titanium_ultimate.txt)
|
||||||
* [CenturionNet Status](https://uptime.coresecret.eu/)
|
* [CenturionNet Status](https://uptime.coresecret.eu/)
|
||||||
* [CenturionMeet](https://talk.e2ee.li/)
|
* [CenturionMeet](https://talk.e2ee.li/)
|
||||||
* [Contact the author](https://coresecret.eu/contact/)
|
* [Contact the author](https://coresecret.eu/contact/)
|
||||||
|
|
||||||
> Please note that all my signing keys are stored in an HSM and that the signing environment is air-gapped.
|
## 1.1. Preliminary Remarks
|
||||||
> The next step is to move to a room-gapped environment.
|
|
||||||
|
### 1.1.1. HSM
|
||||||
|
Please note that all my signing keys are stored in an HSM and that the signing environment is air-gapped. The next step is to
|
||||||
|
move to a room-gapped environment. ^^
|
||||||
|
|
||||||
|
### 1.1.2. DNSSEC, HSTS, TLS
|
||||||
|
|
||||||
Please note that `coresecret.dev` is included in the [(HSTS Preload List)](https://hstspreload.org/) and always serves the headers:
|
Please note that `coresecret.dev` is included in the [(HSTS Preload List)](https://hstspreload.org/) and always serves the headers:
|
||||||
````nginx configuration pro
|
````nginx configuration pro
|
||||||
add_header Expect-CT "max-age=86400, enforce" always;
|
add_header Expect-CT "max-age=86400, enforce" always;
|
||||||
add_header Strict-Transport-Security "max-age=63072000; includeSubDomains; preload" always;
|
add_header Strict-Transport-Security "max-age=63072000; includeSubDomains; preload" always;
|
||||||
````
|
````
|
||||||
Additionally, the entire zone is dual-signed with DNSSEC. See the current DNSSEC status at [DNSSEC Audit Report](https://git.coresecret.dev/msw/CISS.debian.live.builder/src/branch/master/docs/AUDIT_DNSSEC.md)
|
|
||||||
|
|
||||||
## 1.1. Immutable Source-of-Truth System
|
* Additionally, the entire zone is dual-signed with **DNSSEC**. See the current **DNSSEC** status at: **[DNSSEC Audit Report](/docs/AUDIT_DNSSEC.md)**
|
||||||
|
* A comprehensive TLS audit of the **`git.coresecret.dev`** Gitea server is also available. See: **[TLS Audit Report](/docs/AUDIT_TLS.md)**
|
||||||
|
* The infrastructure of the **`CISS.debian.live.builder`** building system is visualized here. See: **[Centurion Net](/docs/CNET.md)**
|
||||||
|
|
||||||
|
### 1.1.3. Gitea Action Runner Hardening
|
||||||
|
|
||||||
|
The CI runners operate on a dedicated host system located in a completely separate Autonomous System (AS). This host is solely
|
||||||
|
dedicated to providing CI runners and does not perform any other tasks. Each runner is hermetically isolated from others using
|
||||||
|
non-privileged, shell-less user accounts with no direct login capability. Additionally, each runner executes within its own
|
||||||
|
separate directory tree, employs `DynamicUser` features, and adheres to strict systemd hardening policies (achieving a ``systemd-analyze security``
|
||||||
|
rating of **``2.6``**). Docker containers used by runners do not run in privileged mode. Security is further enhanced through the use
|
||||||
|
of both UFW software firewalls and dedicated hardware firewall appliances.
|
||||||
|
|
||||||
|
## 1.2. Match Host and Target Versions
|
||||||
|
|
||||||
|
Build, for example, a Debian Trixie live image only on a Debian Trixie host. The build toolchain and boot artifacts are
|
||||||
|
release-specific: ``live-build``, ``live-boot``, ``live-config``, ``debootstrap``, ``kernel/initramfs`` tools, ``mksquashfs``,
|
||||||
|
``GRUB/ISOLINUX``, and even ``dpkg/apt`` often change defaults and formats between releases (e.g., compression modes, SquashFS
|
||||||
|
options, hook ordering, systemd/udev behavior). Building on a different host release commonly yields non-reproducible or even
|
||||||
|
unbootable ISOs (missing modules/firmware, ABI mismatches, divergent paths). Keeping host and target on the same version ensures
|
||||||
|
reproducible builds, matching dependencies, and compatible boot artifacts.
|
||||||
|
|
||||||
|
## 1.3. Immutable Source-of-Truth System
|
||||||
|
|
||||||
This live ISO establishes a secure, fully deterministic, integrity self-verifying boot environment based entirely on static
|
This live ISO establishes a secure, fully deterministic, integrity self-verifying boot environment based entirely on static
|
||||||
source-code definitions. All configurations, system components, and installation routines are embedded during build time and
|
source-code definitions. All configurations, system components, and installation routines are embedded during build time and
|
||||||
@@ -69,25 +98,25 @@ or shell-access, also via the forthcoming `CISS.debian.installer`. Such a versio
|
|||||||
provisions the target device from embedded source artifacts, and reboots into a fully encrypted system image. The system then
|
provisions the target device from embedded source artifacts, and reboots into a fully encrypted system image. The system then
|
||||||
awaits the decryption passphrase input via an embedded Dropbear SSH server (SSH PubKey only) in the initramfs, exposing no ports
|
awaits the decryption passphrase input via an embedded Dropbear SSH server (SSH PubKey only) in the initramfs, exposing no ports
|
||||||
without cryptographic hardened access, while also the `/boot` partition could be encrypted via the built-in support of
|
without cryptographic hardened access, while also the `/boot` partition could be encrypted via the built-in support of
|
||||||
`grub2 (2.12-1~bpo12+1)`.<br>
|
`grub2 (2.12-9)`.<br>
|
||||||
|
|
||||||
This approach provides a fully reproducible, audit-friendly, and tamper-resistant provisioning workflow rooted entirely in
|
This approach provides a fully reproducible, audit-friendly, and tamper-resistant provisioning workflow rooted entirely in
|
||||||
source-defined infrastructure logic.<br>
|
source-defined infrastructure logic.<br>
|
||||||
|
|
||||||
After build and configuration, the following audit reports can be generated:
|
After build and configuration, the following audit reports can be generated:
|
||||||
|
|
||||||
* **Haveged Audit Report**: Validates entropy daemon health and confirms '/dev/random' seeding performance.
|
* **Haveged Audit Report**: Validates entropy daemon health and confirms `/dev/random` seeding performance.
|
||||||
Type `chkhvg` at the prompt. See example report: [Haveged Audit Report](https://git.coresecret.dev/msw/CISS.debian.live.builder/src/branch/master/docs/AUDIT_HAVEGED.md)
|
Type `chkhvg` at the prompt. See example report: **[Haveged Audit Report](/docs/AUDIT_HAVEGED.md)**
|
||||||
* **Lynis Audit Report**: Outputs a detailed security score and recommendations, confirming a 91%+ hardening baseline.
|
* **Lynis Audit Report**: Outputs a detailed security score and recommendations, confirming a 91%+ hardening baseline.
|
||||||
Type `lsadt` at the prompt. See example report: [Lynis Audit Report](https://git.coresecret.dev/msw/CISS.debian.live.builder/src/branch/master/docs/AUDIT_LYNIS.md)
|
Type `lsadt` at the prompt. See example report: **[Lynis Audit Report](/docs/AUDIT_LYNIS.md)**
|
||||||
* **SSH Audit Report**: Verifies SSH daemon configuration against the latest best-practice cipher, KEX, and MAC recommendations.
|
* **SSH Audit Report**: Verifies SSH daemon configuration against the latest best-practice cipher, KEX, and MAC recommendations.
|
||||||
Type `ssh-audit <IP>:<PORT>`. See example report: [SSH Audit Report](https://git.coresecret.dev/msw/CISS.debian.live.builder/src/branch/master/docs/AUDIT_SSH.md)
|
Type `ssh-audit <IP>:<PORT>`. See example report: **[SSH Audit Report](/docs/AUDIT_SSH.md)**
|
||||||
|
|
||||||
## 1.2. Preview
|
## 1.4. Preview
|
||||||
|
|
||||||

|

|
||||||
|
|
||||||
## 1.3. Caution. Significant information for those considering using D-I.
|
## 1.5. Caution. Significant information for those considering using D-I.
|
||||||
|
|
||||||
**The Debian Installer (d-i) will ALWAYS boot a new system.**<br>
|
**The Debian Installer (d-i) will ALWAYS boot a new system.**<br>
|
||||||
|
|
||||||
@@ -101,7 +130,7 @@ The following happens in all cases:
|
|||||||
* The installer kernel (/install/vmlinuz) + initrd.gz are started.
|
* The installer kernel (/install/vmlinuz) + initrd.gz are started.
|
||||||
* The existing live system is exited.
|
* The existing live system is exited.
|
||||||
* The memory is overwritten.
|
* The memory is overwritten.
|
||||||
* All running processes – e.g., firewall, hardened SSH access, etc. pp. – cease to exist.
|
* All running processes - e.g., firewall, hardened SSH access, etc. pp. - cease to exist.
|
||||||
|
|
||||||
The Debian Installer loads:
|
The Debian Installer loads:
|
||||||
* its own kernel,
|
* its own kernel,
|
||||||
@@ -118,6 +147,24 @@ This means function status of the **CISS.2025.debian.live.builder** ISO after d-
|
|||||||
* Logging (rsyslog, journald) ✘ not active,
|
* Logging (rsyslog, journald) ✘ not active,
|
||||||
* preseed control over the network is possible (but without any protection).
|
* preseed control over the network is possible (but without any protection).
|
||||||
|
|
||||||
|
## 1.6. Versioning Schema
|
||||||
|
|
||||||
|
This project adheres strictly to a structured versioning scheme following the pattern x.y.z-Date.
|
||||||
|
|
||||||
|
Example: `V8.13.142.2025.10.14`
|
||||||
|
|
||||||
|
`x.y.z` represents major (x), minor (y), and patch (z) version increments.
|
||||||
|
|
||||||
|
Date (YYYY.MM.DD) denotes the build or release date, facilitating clear tracking of incremental changes and ensuring
|
||||||
|
reproducibility and traceability.
|
||||||
|
|
||||||
|
## 1.7. Keywords
|
||||||
|
|
||||||
|
The keywords "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT", "SHOULD", "SHOULD NOT", "RECOMMENDED", "NOT RECOMMENDED",
|
||||||
|
"MAY", and "OPTIONAL" in this Repo are to be interpreted as described in [[BCP 14](https://www.rfc-editor.org/info/bcp14)],
|
||||||
|
[[RFC2119](https://datatracker.ietf.org/doc/html/rfc2119)], [[RFC8174](https://datatracker.ietf.org/doc/html/rfc8174)] when,
|
||||||
|
and only when, they appear in all capitals, as shown here.
|
||||||
|
|
||||||
# 2. Features & Rationale
|
# 2. Features & Rationale
|
||||||
|
|
||||||
Below is a breakdown of each hardening component, with a summary of why each is critical to your security posture.
|
Below is a breakdown of each hardening component, with a summary of why each is critical to your security posture.
|
||||||
@@ -126,7 +173,7 @@ Below is a breakdown of each hardening component, with a summary of why each is
|
|||||||
|
|
||||||
### 2.1.1. Boot Parameters
|
### 2.1.1. Boot Parameters
|
||||||
|
|
||||||
* **Description**: Customizes kernel command‑line flags to disable unused features and enable mitigations.
|
* **Description**: Customizes kernel command-line flags to disable unused features and enable mitigations.
|
||||||
* **Key Parameters**:
|
* **Key Parameters**:
|
||||||
* `audit_backlog_limit=8192`: Ensures the audit subsystem can queue up to 8192 events to avoid dropped logs under heavy loads.
|
* `audit_backlog_limit=8192`: Ensures the audit subsystem can queue up to 8192 events to avoid dropped logs under heavy loads.
|
||||||
* `audit=1`: Enables kernel auditing from boot to record system calls and security events.
|
* `audit=1`: Enables kernel auditing from boot to record system calls and security events.
|
||||||
@@ -166,12 +213,12 @@ Below is a breakdown of each hardening component, with a summary of why each is
|
|||||||
### 2.1.2. CPU Vulnerability Mitigations
|
### 2.1.2. CPU Vulnerability Mitigations
|
||||||
|
|
||||||
* **Description**: Enables all known kernel-level mitigations (Spectre, Meltdown, MDS, L1TF, etc.).
|
* **Description**: Enables all known kernel-level mitigations (Spectre, Meltdown, MDS, L1TF, etc.).
|
||||||
* **Rationale**: Prevents side‑channel attacks that exploit speculative execution, which remain a high‑risk vector in
|
* **Rationale**: Prevents side-channel attacks that exploit speculative execution, which remain a high-risk vector in
|
||||||
multi‑tenant cloud environments.
|
multi-tenant cloud environments.
|
||||||
|
|
||||||
### 2.1.3. Kernel Self-Protection
|
### 2.1.3. Kernel Self-Protection
|
||||||
|
|
||||||
* **Description**: Activates `CONFIG_DEBUG_RODATA`, `CONFIG_STRICT_MODULE_RWX`, and other self‑protections.
|
* **Description**: Activates `CONFIG_DEBUG_RODATA`, `CONFIG_STRICT_MODULE_RWX`, and other self-protections.
|
||||||
* **Rationale**: Hardens kernel memory regions against unauthorized writings and enforces stricter module loading policies.
|
* **Rationale**: Hardens kernel memory regions against unauthorized writings and enforces stricter module loading policies.
|
||||||
|
|
||||||
### 2.1.4. Local Kernel Hardening
|
### 2.1.4. Local Kernel Hardening
|
||||||
@@ -205,14 +252,14 @@ apply or revert these controls.
|
|||||||
|
|
||||||
## 2.2. Module Blacklisting
|
## 2.2. Module Blacklisting
|
||||||
|
|
||||||
* **Description**: Disables and blacklists non‑essential or insecure kernel modules.
|
* **Description**: Disables and blacklists non-essential or insecure kernel modules.
|
||||||
* **Rationale**: Minimizes attack surface by preventing loads of drivers or modules not required by the live environment.
|
* **Rationale**: Minimizes attack surface by preventing loads of drivers or modules not required by the live environment.
|
||||||
|
|
||||||
## 2.3. Network Hardening
|
## 2.3. Network Hardening
|
||||||
|
|
||||||
* **Description**: Applies `sysctl` settings (e.g., `net.ipv4.conf.all.rp_filter=1`, `arp_ignore`, `arp_announce`) to restrict
|
* **Description**: Applies `sysctl` settings (e.g., `net.ipv4.conf.all.rp_filter=1`, `arp_ignore`, `arp_announce`) to restrict
|
||||||
inbound/outbound traffic behaviors.
|
inbound/outbound traffic behaviors.
|
||||||
* **Rationale**: Mitigates ARP spoofing, IP spoofing, and reduces the risk of man‑in‑the‑middle on internal networks.
|
* **Rationale**: Mitigates ARP spoofing, IP spoofing, and reduces the risk of man-in-the-middle on internal networks.
|
||||||
|
|
||||||
## 2.4. Core Dump & Kernel Hardening
|
## 2.4. Core Dump & Kernel Hardening
|
||||||
|
|
||||||
@@ -229,7 +276,7 @@ apply or revert these controls.
|
|||||||
## 2.6. Permissions & Authentication
|
## 2.6. Permissions & Authentication
|
||||||
|
|
||||||
* **Description**: Sets strict directory and file permissions, integrates with PAM modules (e.g., `pam_faillock`).
|
* **Description**: Sets strict directory and file permissions, integrates with PAM modules (e.g., `pam_faillock`).
|
||||||
* **Rationale**: Enforces the principle of least privilege at file‑system level and strengthens authentication policies.
|
* **Rationale**: Enforces the principle of least privilege at file-system level and strengthens authentication policies.
|
||||||
|
|
||||||
## 2.7. High-Security Baseline (Lynis Audit)
|
## 2.7. High-Security Baseline (Lynis Audit)
|
||||||
|
|
||||||
@@ -243,11 +290,11 @@ apply or revert these controls.
|
|||||||
* **Description**: The SSH tunnel and access are secured through multiple layers of defense:
|
* **Description**: The SSH tunnel and access are secured through multiple layers of defense:
|
||||||
* **Firewall Restriction**: ufw allows connections only from defined jump host or VPN exit node IPs.
|
* **Firewall Restriction**: ufw allows connections only from defined jump host or VPN exit node IPs.
|
||||||
* **TCP Wrappers**: `/etc/hosts.allow` and `/etc/hosts.deny` enforce an `ALL: ALL` deny policy, permitting only specified hosts.
|
* **TCP Wrappers**: `/etc/hosts.allow` and `/etc/hosts.deny` enforce an `ALL: ALL` deny policy, permitting only specified hosts.
|
||||||
* **One‑Hit Ban**: A custom Fail2Ban rule `/etc/fail2ban/jail.d/centurion-default.conf` immediately bans any host
|
* **One-Hit Ban**: A custom Fail2Ban rule `/etc/fail2ban/jail.d/centurion-default.conf` immediately bans any host
|
||||||
that touches closed ports.
|
that touches closed ports.
|
||||||
* Additionally, the `fail2ban` service is hardened as well according to:
|
* Additionally, the `fail2ban` service is hardened as well according to:
|
||||||
[Arch Linux Wiki Fail2ban Hardening](https://wiki.archlinux.org/title/fail2ban#Service_hardening)
|
[Arch Linux Wiki Fail2ban Hardening](https://wiki.archlinux.org/title/fail2ban#Service_hardening)
|
||||||
* **SSH Ultra‑Hardening**: The `/etc/sshd_config` enforces strict cryptographic and connection controls with respect to
|
* **SSH Ultra-Hardening**: The `/etc/sshd_config` enforces strict cryptographic and connection controls with respect to
|
||||||
[SSH Audit Guide Debian 12](https://www.ssh-audit.com/hardening_guides.html#debian_12):
|
[SSH Audit Guide Debian 12](https://www.ssh-audit.com/hardening_guides.html#debian_12):
|
||||||
* `RekeyLimit 1G 1h`
|
* `RekeyLimit 1G 1h`
|
||||||
* `HostKey /etc/ssh/ssh_host_ed25519_key`
|
* `HostKey /etc/ssh/ssh_host_ed25519_key`
|
||||||
@@ -272,7 +319,7 @@ apply or revert these controls.
|
|||||||
## 2.9. UFW Hardening
|
## 2.9. UFW Hardening
|
||||||
|
|
||||||
* **Description**: Defaults to `deny incoming` and (optionally) `deny outgoing`; automatically opens only whitelisted ports.
|
* **Description**: Defaults to `deny incoming` and (optionally) `deny outgoing`; automatically opens only whitelisted ports.
|
||||||
* **Rationale**: Implements a default‑deny firewall, reducing lateral movement and data exfiltration risks immediately after
|
* **Rationale**: Implements a default-deny firewall, reducing lateral movement and data exfiltration risks immediately after
|
||||||
deployment.
|
deployment.
|
||||||
|
|
||||||
## 2.10. Fail2Ban Enhancements
|
## 2.10. Fail2Ban Enhancements
|
||||||
@@ -281,13 +328,13 @@ apply or revert these controls.
|
|||||||
* Bans any connection to a closed port for 24 hours
|
* Bans any connection to a closed port for 24 hours
|
||||||
* Automatically ignores designated bastion/jump host subnets
|
* Automatically ignores designated bastion/jump host subnets
|
||||||
* Hardened via `systemd` policy override to limit privileges of the Fail2Ban service itself
|
* Hardened via `systemd` policy override to limit privileges of the Fail2Ban service itself
|
||||||
* **Rationale**: Provides proactive defense against port scans and brute‑force attacks, while isolating the ban daemon in a
|
* **Rationale**: Provides proactive defense against port scans and brute-force attacks, while isolating the ban daemon in a
|
||||||
minimal‑privilege context.
|
minimal-privilege context.
|
||||||
|
|
||||||
## 2.11. NTPsec & Chrony
|
## 2.11. NTPsec & Chrony
|
||||||
|
|
||||||
* **Description**: Installs `chrony`, selects PTB NTPsec servers by default.
|
* **Description**: Installs `chrony`, selects PTB NTPsec servers by default.
|
||||||
* **Rationale**: Ensures tamper‑resistant time synchronization, which is essential for log integrity, certificate validation,
|
* **Rationale**: Ensures tamper-resistant time synchronization, which is essential for log integrity, certificate validation,
|
||||||
and forensic accuracy.
|
and forensic accuracy.
|
||||||
|
|
||||||
# 3. Script Features & Rationale
|
# 3. Script Features & Rationale
|
||||||
@@ -351,36 +398,62 @@ apply or revert these controls.
|
|||||||
set -o errexit # Exit script when a command exits with non-zero status (same as "set -e").
|
set -o errexit # Exit script when a command exits with non-zero status (same as "set -e").
|
||||||
set -o errtrace # Inherit ERR traps in subshells (same as "set -E").
|
set -o errtrace # Inherit ERR traps in subshells (same as "set -E").
|
||||||
set -o functrace # Inherit DEBUG and RETURN traps in subshells (same as "set -T").
|
set -o functrace # Inherit DEBUG and RETURN traps in subshells (same as "set -T").
|
||||||
|
set -o ignoreeof # An interactive shell will not exit upon reading EOF.
|
||||||
set -o nounset # Exit script on use of an undefined variable (same as "set -u").
|
set -o nounset # Exit script on use of an undefined variable (same as "set -u").
|
||||||
set -o pipefail # Return the exit status of the last failed command in a pipeline.
|
set -o pipefail # Return the exit status of the last failed command in a pipeline.
|
||||||
set -o noclobber # Prevent overwriting files via redirection (same as "set -C").
|
set -o noclobber # Prevent overwriting files via redirection (same as "set -C").
|
||||||
```
|
```
|
||||||
|
|
||||||
|
* The following `shopt` options are applied at the beginning of the script (see
|
||||||
|
[Bash Manual, The Shopt Builtin](https://www.gnu.org/software/bash/manual/bash.html#The-Shopt-Builtin)):
|
||||||
|
````bash
|
||||||
|
shopt -s failglob # If set, patterns that fail to match filenames during filename expansion result in an expansion error.
|
||||||
|
shopt -s inherit_errexit # If set, command substitution inherits the value of the errexit option instead of unsetting it in the
|
||||||
|
# subshell environment.
|
||||||
|
shopt -s lastpipe # If set, and job control is not active, the shell runs the last command of a pipeline not executed in
|
||||||
|
# the background in the current shell environment.
|
||||||
|
shopt -u expand_aliases # If set, aliases are expanded as described. This option is enabled by default for interactive shells.
|
||||||
|
shopt -u dotglob # If set, Bash includes filenames beginning with a '.' in the results of filename expansion.
|
||||||
|
shopt -u extglob # If set, enable the extended pattern matching features.
|
||||||
|
shopt -u nullglob # If set, filename expansion patterns that match no files expand to nothing and are removed.
|
||||||
|
````
|
||||||
|
|
||||||
* **Rationale**: These options enforce strict error checking and handling, reducing silent failures and ensuring
|
* **Rationale**: These options enforce strict error checking and handling, reducing silent failures and ensuring
|
||||||
predictable script behavior.
|
predictable script behavior.
|
||||||
|
|
||||||
# 4. Prerequisites
|
# 4. Prerequisites
|
||||||
|
|
||||||
* **Host**: Debian Bookworm or newer with `live-build` package installed.
|
* **Host**: Debian Trixie with `live-build` and ``debootstrap`` packages installed.
|
||||||
* **Privileges**: Root or sudo access to execute `ciss_live_builder.sh` and related scripts.
|
* **Privileges**: Root or sudo access to execute `ciss_live_builder.sh` and related scripts.
|
||||||
* **Network**: Outbound access to Debian repositories and PTB NTPsec pool.
|
* **Network**: Outbound access to Debian repositories and PTB NTPsec pool.
|
||||||
|
|
||||||
# 5. Installation & Usage
|
# 5. Installation & Usage
|
||||||
|
|
||||||
# 5.1. Interactive CLI / Dialog Wrapper
|
## 5.1. Interactive CLI / Dialog Wrapper
|
||||||
|
|
||||||
1. Clone the repository:
|
1. Clone the repository:
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
git clone https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
git clone https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
||||||
cd CISS.debian.live.builder
|
cd CISS.debian.live.builder
|
||||||
```
|
```
|
||||||
2. Edit the '.gitea/workflows/generate-iso.yaml' file according to your requirements.
|
|
||||||
|
|
||||||
```yaml
|
2. Preparation:
|
||||||
|
1. Ensure you are root.
|
||||||
|
2. Create the build directory `mkdir /opt/livebuild`.
|
||||||
|
3. Place your desired SSH public key in the `authorized_keys` file, for example, in the `/opt/gitea/CISS.debian.live.builder` directory.
|
||||||
|
4. Place your desired Password in the `password.txt` file, for example, in the `/opt/gitea/CISS.debian.live.builder` directory.
|
||||||
|
5. Make any other changes you need to.
|
||||||
|
|
||||||
|
3. Run the config builder script `./ciss_live_builder.sh` and the integrated `lb build` command (example):
|
||||||
|
|
||||||
|
````bash
|
||||||
|
chmod 0700 ./ciss_live_builder.sh
|
||||||
|
timestamp=$(date -u +%Y-%m-%dT%H:%M:%S%z)
|
||||||
./ciss_live_builder.sh --architecture amd64 \
|
./ciss_live_builder.sh --architecture amd64 \
|
||||||
--build-directory /opt/livebuild \
|
--build-directory /opt/livebuild \
|
||||||
--change-splash hexagon \
|
--change-splash hexagon \
|
||||||
--control 384 \
|
--control "${timestamp}" \
|
||||||
|
--cdi \
|
||||||
--debug \
|
--debug \
|
||||||
--dhcp-centurion \
|
--dhcp-centurion \
|
||||||
--jump-host 10.0.0.128 [c0de:4711:0815:4242::1] [2abc:4711:0815:4242::1]/64 \
|
--jump-host 10.0.0.128 [c0de:4711:0815:4242::1] [2abc:4711:0815:4242::1]/64 \
|
||||||
@@ -389,18 +462,121 @@ predictable script behavior.
|
|||||||
--reionice-priority 1 2 \
|
--reionice-priority 1 2 \
|
||||||
--root-password-file /opt/gitea/CISS.debian.live.builder/password.txt \
|
--root-password-file /opt/gitea/CISS.debian.live.builder/password.txt \
|
||||||
--ssh-port 4242 \
|
--ssh-port 4242 \
|
||||||
--ssh-pubkey /opt/gitea/CISS.debian.live.builder
|
--ssh-pubkey /opt/gitea/CISS.debian.live.builder \
|
||||||
|
--trixie
|
||||||
|
````
|
||||||
|
|
||||||
|
4. Locate your ISO in the `--build-directory`.
|
||||||
|
5. Boot from the ISO and login to the live image via the console, or the multi-layer secured **coresecret** SSH tunnel.
|
||||||
|
6. Type `sysp` for the final kernel hardening features.
|
||||||
|
7. Check the boot log with `jboot` and via `ssf` that all services are up.
|
||||||
|
8. Finally, audit your environment with `lsadt` for a comprehensive Lynis audit.
|
||||||
|
9. Type `celp` for some shortcuts.
|
||||||
|
|
||||||
|
## 5.2. Make Wrapper, Quick Usage
|
||||||
|
|
||||||
|
This repo ships a thin make wrapper around ``./ciss_live_builder.sh``, so you can compose a correctly quoted command and either
|
||||||
|
preview it or run it.
|
||||||
|
|
||||||
|
1. Clone the repository:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
git clone https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
||||||
|
cd CISS.debian.live.builder
|
||||||
```
|
```
|
||||||
3. Locate your ISO in the `--build-directory`.
|
|
||||||
4. Boot from the ISO and login to the live image via the console, or the multi-layer secured coresecret SSH tunnel.
|
|
||||||
5. Type `sysp` for the final kernel hardening features.
|
|
||||||
6. Check the boot log with `jboot` and via `ssf` that all services are up.
|
|
||||||
7. Finally, audit your environment with `lsadt` for a comprehensive Lynis audit.
|
|
||||||
8. Type `celp` for some shortcuts.
|
|
||||||
|
|
||||||
# 5.2. CI/CD Gitea Runner Workflow Example
|
2. Preparation:
|
||||||
|
1. Ensure you are root.
|
||||||
|
2. Create the build directory `mkdir /opt/livebuild`.
|
||||||
|
3. Place your desired SSH public key in the `authorized_keys` file, for example, in the `/opt/gitea/CISS.debian.live.builder` directory.
|
||||||
|
4. Place your desired Password in the `password.txt` file, for example, in the `/opt/gitea/CISS.debian.live.builder` directory.
|
||||||
|
5. Copy and edit the sample and set your options (no spaces around commas in lists):
|
||||||
|
|
||||||
1. tba
|
````bash
|
||||||
|
cp config.mk.sample config.mk
|
||||||
|
````
|
||||||
|
|
||||||
|
````bash
|
||||||
|
BUILD_DIR=/opt/livebuild
|
||||||
|
ROOT_PASSWORD_FILE=/opt/gitea/CISS.debian.live.builder/password.txt
|
||||||
|
SSH_PORT=4242
|
||||||
|
SSH_PUBKEY=/root/.ssh
|
||||||
|
|
||||||
|
# Optional
|
||||||
|
PROVIDER_NETCUP_IPV6=2001:cdb::1
|
||||||
|
# comma-separated; IPv6 in [] is fine
|
||||||
|
JUMP_HOSTS=[2001:db8::1],[2001:db8::2]
|
||||||
|
````
|
||||||
|
|
||||||
|
3. Dry-run first (prints the exact command): ````make dry-run````
|
||||||
|
|
||||||
|
4. Execute the build: ````make live````
|
||||||
|
|
||||||
|
## 5.3. CI/CD Gitea Runner Workflow Example
|
||||||
|
|
||||||
|
1. Clone the repository:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
git clone https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
||||||
|
cd CISS.debian.live.builder
|
||||||
|
```
|
||||||
|
2. Edit the `.gitea/workflows/generate-iso.yaml` file according to your requirements. Ensure that the trigger file
|
||||||
|
`.gitea/trigger/t_generate.iso.yaml` and the counter are updated. Change all the necessary `{{ secrets.VAR }}`.
|
||||||
|
Push your commits to trigger the workflow. Then download your final ISO from the specified Location.
|
||||||
|
|
||||||
|
```yaml
|
||||||
|
#...
|
||||||
|
steps:
|
||||||
|
- name: Preparing SSH Setup, SSH Deploy Key, Known Hosts, .config.
|
||||||
|
run: |
|
||||||
|
rm -rf ~/.ssh && mkdir -m700 ~/.ssh
|
||||||
|
|
||||||
|
### Private Key
|
||||||
|
echo "${{ secrets.CHANGE_ME }}" >| ~/.ssh/id_ed25519
|
||||||
|
chmod 600 ~/.ssh/id_ed25519
|
||||||
|
#...
|
||||||
|
### https://github.com/actions/checkout/issues/1843
|
||||||
|
- name: Using manual clone via SSH to circumvent Gitea SHA-256 object issues.
|
||||||
|
run: |
|
||||||
|
git clone --branch "${GITHUB_REF_NAME}" ssh://git@CHANGE_ME .
|
||||||
|
#...
|
||||||
|
- name: Importing the 'CI PGP DEPLOY ONLY' key.
|
||||||
|
run: |
|
||||||
|
### GPG-Home relative to the Runner Workspace to avoid changing global files.
|
||||||
|
export GNUPGHOME="$(pwd)/.gnupg"
|
||||||
|
mkdir -m700 "${GNUPGHOME}"
|
||||||
|
echo "${{ secrets.CHANGE_ME }}" >| ci-bot.sec.asc
|
||||||
|
#...
|
||||||
|
- name: Configuring Git for signed CI/DEPLOY commits.
|
||||||
|
run: |
|
||||||
|
export GNUPGHOME="$(pwd)/.gnupg"
|
||||||
|
git config user.name "CHANGE_ME"
|
||||||
|
git config user.email "CHANGE_ME"
|
||||||
|
#...
|
||||||
|
- name: Preparing the build environment.
|
||||||
|
run: |
|
||||||
|
mkdir -p /opt/config
|
||||||
|
mkdir -p /opt/livebuild
|
||||||
|
echo "${{ secrets.CHANGE_ME }}" >| /opt/config/password.txt
|
||||||
|
echo "${{ secrets.CHANGE_ME }}" >| /opt/config/authorized_keys
|
||||||
|
#...
|
||||||
|
- name: Starting CISS.debian.live.builder. This may take a while ...
|
||||||
|
run: |
|
||||||
|
chmod 0700 ciss_live_builder.sh && chown root:root ciss_live_builder.sh
|
||||||
|
timestamp=$(date -u +"%Y_%m_%d_%H_%M_Z")
|
||||||
|
### Change "--autobuild=" to the specific kernel version you need: '6.12.22+bpo-amd64'.
|
||||||
|
./ciss_live_builder.sh \
|
||||||
|
--autobuild=CHANGE_ME \
|
||||||
|
--architecture CHANGE_ME \
|
||||||
|
--build-directory /opt/livebuild \
|
||||||
|
--control "${timestamp}" \
|
||||||
|
--jump-host "${{ secrets.CHANGE_ME }}" \
|
||||||
|
--root-password-file /opt/config/password.txt \
|
||||||
|
--ssh-port CHANGE_ME \
|
||||||
|
--ssh-pubkey /opt/config
|
||||||
|
#...
|
||||||
|
### SKIP OR CHANGE ALL REMAINING STEPS
|
||||||
|
```
|
||||||
|
|
||||||
# 6. Licensing & Compliance
|
# 6. Licensing & Compliance
|
||||||
|
|
||||||
@@ -410,7 +586,7 @@ standard for license expressions and metadata.
|
|||||||
|
|
||||||
# 7. Disclaimer
|
# 7. Disclaimer
|
||||||
|
|
||||||
This README is provided "as‑is" without any warranty. Review your organization's policies before deploying to production.
|
This README is provided "as-is" without any warranty. Review your organization's policies before deploying to production.
|
||||||
|
|
||||||
---
|
---
|
||||||
**[no tracking | no logging | no advertising | no profiling | no bullshit](https://coresecret.eu/)**
|
**[no tracking | no logging | no advertising | no profiling | no bullshit](https://coresecret.eu/)**
|
||||||
|
|||||||
119
REPOSITORY.md
Normal file
119
REPOSITORY.md
Normal file
@@ -0,0 +1,119 @@
|
|||||||
|
---
|
||||||
|
gitea: none
|
||||||
|
include_toc: true
|
||||||
|
---
|
||||||
|
|
||||||
|
# 1. CISS.debian.live.builder
|
||||||
|
|
||||||
|
**Centurion Intelligence Consulting Agency Information Security Standard**<br>
|
||||||
|
*Debian Live Build Generator for hardened live environment and CISS Debian Installer*<br>
|
||||||
|
**Master Version**: 8.13<br>
|
||||||
|
**Build**: V8.13.142.2025.10.14<br>
|
||||||
|
|
||||||
|
# 2.1. Repository Structure
|
||||||
|
|
||||||
|
**Project:** Centurion Intelligence Consulting Agency Information Security Standard (CISS) — Debian Live Builder
|
||||||
|
**Branch:** `master`
|
||||||
|
**Repository State:** Master Version **8.13**, Build **V8.13.142.2025.10.14** (as of 2025-10-11)
|
||||||
|
|
||||||
|
## 2.2. Top-Level Layout
|
||||||
|
|
||||||
|
````text
|
||||||
|
CISS.debian.live.builder/
|
||||||
|
├─ .archive/ # Archived artefacts or historical assets
|
||||||
|
├─ .gitea/ # Gitea CI/CD metadata (workflows, triggers, templates)
|
||||||
|
│ ├─ ISSUE_TEMPLATE/
|
||||||
|
│ ├─ properties/{json, lua}
|
||||||
|
│ ├─ TO DO/{dockerfile, render-md-to-html.yaml}
|
||||||
|
│ ├─ trigger/{t_generate_.yaml}
|
||||||
|
│ └─ workflows/{generate_.yaml, linter_char_scripts.yaml, render-.yaml}
|
||||||
|
├─ .pubkey/ # Public keys (e.g., for CI or verification)
|
||||||
|
├─ config/ # Live-build configuration (boot, hooks, includes, package lists)
|
||||||
|
│ ├─ bootloaders/{grub-efi, grub-pc, splash.png}
|
||||||
|
│ ├─ hooks/live/.chroot # Ordered chroot hooks (0000_* … 99xx_)
|
||||||
|
│ ├─ includes.binary/boot/grub/config.cfg
|
||||||
|
│ ├─ includes.chroot/{etc, preseed, root}
|
||||||
|
│ └─ package-lists/{live.list.amd64.chroot, live.list.arm64.chroot, live.list.common.chroot}
|
||||||
|
├─ docs/ # Project documentation (audits, change log, policies)
|
||||||
|
│ ├─ AUDIT_.md, BOOTPARAMS.md, CHANGELOG.md, CODING_CONVENTION.md, ...
|
||||||
|
│ ├─ SECURITY/, LICENSES/, graphviz/, screenshots/
|
||||||
|
├─ lib/ # Shell library modules used by the builder
|
||||||
|
├─ scripts/ # Helper/orchestration scripts (e.g., network, live-boot)
|
||||||
|
├─ var/ # Variable sets and early/global defaults (*.var.sh)
|
||||||
|
├─ .editorconfig
|
||||||
|
├─ .gitignore
|
||||||
|
├─ .shellcheckrc
|
||||||
|
├─ .version.properties
|
||||||
|
├─ CISS.debian.live.builder.spdx # SPDX bill of materials / license manifest
|
||||||
|
├─ LICENSE
|
||||||
|
├─ SECURITY.md
|
||||||
|
├─ README.md
|
||||||
|
├─ config.mk.sample
|
||||||
|
├─ ciss_live_builder.sh # Main entrypoint / wrapper
|
||||||
|
├─ makefile
|
||||||
|
├─ meta_sources_debug.sh
|
||||||
|
├─ LIVE_ISO_TRIXIE_0.private # CI artefact markers
|
||||||
|
├─ LIVE_ISO_TRIXIE_1.private # CI artefact markers
|
||||||
|
└─ LIVE_ISO.public # CI artefact markers
|
||||||
|
````
|
||||||
|
|
||||||
|
> **Note:** The ISO marker files (`LIVE_ISO.*`) are produced by CI workflows for convenient retrieval of generated images.
|
||||||
|
|
||||||
|
## 2.3. Directory Semantics
|
||||||
|
|
||||||
|
### 2.3.1. `.gitea/` — CI/CD Orchestration
|
||||||
|
- **`workflows/`**: Declarative Gitea Actions to lint shell scripts, render Graphviz/DNSSEC status, and generate **PUBLIC**/**PRIVATE (TRIXIE)** ISOs reproducibly.
|
||||||
|
- **`trigger/`**: Manual/auxiliary trigger manifests (`t_generate_PUBLIC.yaml`, `t_generate_PRIVATE_trixie_{0,1}.yaml`, `t_generate_dns.yaml`) to drive pipeline variants.
|
||||||
|
- **`ISSUE_TEMPLATE/`**: Issue and pull request templates to standardize change management.
|
||||||
|
- **`properties/`** and **`TODO/`**: Auxiliary config fragments (JSON/Lua) and maintenance utilities (e.g., `render-md-to-html.yaml`).
|
||||||
|
|
||||||
|
### 2.3.2. `config/` — Live-Build Configuration
|
||||||
|
- **`bootloaders/`**: Boot assets for GRUB in EFI and PC modes, incl. a branded splash image.
|
||||||
|
- **`hooks/live/`**: **Ordered** `*.chroot` hooks implementing system configuration and hardening during image creation; the numeric prefixes dictate execution (e.g., `0000_basic_chroot_setup.chroot`, `0810_chrony_setup.chroot`, `0900_ufw_setup.chroot`, `9930_hardening_ssh.chroot`, `9950_fail2ban_hardening.chroot`).
|
||||||
|
- **`includes.binary/boot/grub/`**: Static GRUB configuration embedded in the binary image (`config.cfg`).
|
||||||
|
- **`includes.chroot/`**: Files copied into the live system’s root:
|
||||||
|
- `etc/` (APT configuration, `live/`, `modprobe.d/`, network, SSH, `sysctl.d/`, systemd drop-ins, banners),
|
||||||
|
- `preseed/` (installer preseeding and supporting artifacts),
|
||||||
|
- `root/` (administrator dotfiles and keys).
|
||||||
|
- **`package-lists/`**: Architecture-specific and common package manifests (`amd64`, `arm64`, `common`) used by `live-build`.
|
||||||
|
|
||||||
|
### 2.3.3. `docs/` — Documentation Corpus
|
||||||
|
Audit reports (DNSSEC, Lynis, SSH, TLS, Haveged), **BOOTPARAMS**, **CHANGELOG**, **CODING_CONVENTION**, **CONTRIBUTING**, **REFERENCES**; plus `SECURITY/`, `LICENSES/`, architecture diagrams under `graphviz/`, and illustrative `screenshots/`.
|
||||||
|
|
||||||
|
### 2.3.4. `lib/` — Shell Library Modules
|
||||||
|
Composable, single-purpose modules used by the wrapper and CI steps (argument parsing and validation, kernel/CPU mitigation checks, provider support, `lb config/build` scaffolding, usage/version banners, sanitization and traps, SSH/root-password hardening, ultra-hardening profile, etc.).
|
||||||
|
|
||||||
|
### 2.3.5. `scripts/` — Operational Helpers
|
||||||
|
Ancillary scripts for DHCP supersedes, resolver bootstrapping, and live-boot verification; targeted paths such as `scripts/etc/network/` and `scripts/live-boot/` encapsulate deploy-time adjustments and integrity checks.
|
||||||
|
|
||||||
|
### 2.3.6. `var/` — Variables & Defaults
|
||||||
|
Layered variable sets (`early.var.sh`, `global.var.sh`, `bash.var.sh`, `color.var.sh`) providing early-boot defaults, global tuning, and TTY/UI niceties.
|
||||||
|
|
||||||
|
## 2.4. Key Files
|
||||||
|
|
||||||
|
- **`ciss_live_builder.sh`** — Primary entrypoint; orchestrates argument parsing, environment preparation, `lb config`/`lb build` execution and post-processing.
|
||||||
|
- **`makefile`** & **`config.mk.sample`** — Make-based convenience wrapper and a sample configuration surface.
|
||||||
|
- **`README.md`, `SECURITY.md`, `LICENSE`, `CISS.debian.live.builder.spdx`** — Project overview, security policy, licensing, and SPDX manifest for compliance.
|
||||||
|
- **ISO markers**: `LIVE_ISO.public`, `LIVE_ISO_TRIXIE_{0,1}.private` reflect CI pipeline outputs.
|
||||||
|
|
||||||
|
## 2.5. Conventions & Build Logic
|
||||||
|
|
||||||
|
- **Hook Ordering**: Numeric prefixes (`0000_…` → `99xx_…`) strictly determine execution sequencing within `config/hooks/live/`. Early hooks establish base state (initramfs modules, checksums), mid-range hooks integrate security services (AppArmor, Chrony/NTPsec, Lynis, UFW, Fail2Ban, SSH auditing), late hooks enforce hardening and cleanup (SSH tightening, memory-dump policies, service disablement).
|
||||||
|
- **Binary vs. Chroot Includes**: Assets under `includes.binary/` affect the ISO’s bootloader stage; `includes.chroot/` become part of the runtime filesystem.
|
||||||
|
- **Architecture Scoping**: Package lists are split into `*amd64*`, `*arm64*`, and `*common*` to keep images minimal and deterministic.
|
||||||
|
- **CI/CD**: Reproducible ISO builds are executed via Gitea workflows; dedicated `trigger/` manifests parameterize public vs. private images and auxiliary rendering jobs (e.g., DNSSEC status, Graphviz diagrams).
|
||||||
|
|
||||||
|
## 2.6. Cross-References (Documentation)
|
||||||
|
|
||||||
|
- **Boot Parameters**: see `docs/BOOTPARAMS.md`.
|
||||||
|
- **Audits**: `docs/AUDIT_*.md` (DNSSEC, Lynis, SSH, TLS, Haveged).
|
||||||
|
- **Coding & Contribution**: `docs/CODING_CONVENTION.md`, `docs/CONTRIBUTING.md`.
|
||||||
|
- **Change Log & References**: `docs/CHANGELOG.md`, `docs/REFERENCES.md`.
|
||||||
|
|
||||||
|
## 2.7. Licensing & Compliance
|
||||||
|
|
||||||
|
The repository is **SPDX-compliant**; source files carry SPDX identifiers. See `CISS.debian.live.builder.spdx` and `LICENSE` for details.
|
||||||
|
|
||||||
|
---
|
||||||
|
**[no tracking | no logging | no advertising | no profiling | no bullshit](https://coresecret.eu/)**
|
||||||
|
<!-- vim: set number et ts=2 sw=2 sts=2 ai tw=128 ft=markdown -->
|
||||||
@@ -3,7 +3,7 @@
|
|||||||
# SPDX-CreationInfo: 2025-05-05; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-CreationInfo: 2025-05-05; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
||||||
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
# SPDX-FileCopyrightText: 2024–2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-FileType: SOURCE
|
# SPDX-FileType: SOURCE
|
||||||
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
@@ -13,168 +13,237 @@
|
|||||||
### Contributions so far see ./docs/CREDITS.md
|
### Contributions so far see ./docs/CREDITS.md
|
||||||
|
|
||||||
### WHY BASH?
|
### WHY BASH?
|
||||||
# Ease of installation.
|
# Ease of installation. No compiling or installing gems, CPAN modules, pip packages, etc. Simple to use and read. Clear syntax
|
||||||
# No compiling or installing gems, CPAN modules, pip packages, etc.
|
# and straightforward output interpretation. Built-in power. Pattern matching, line processing, and regular expression support
|
||||||
# Simple to use and read. Clear syntax and straightforward output interpretation.
|
# are available natively, no external binaries required. Cross-platform consistency. '/bin/bash' is the default shell on most
|
||||||
# Built-in power.
|
# Linux distributions, ensuring scripts run unmodified across systems. macOS compatibility. Since macOS Catalina (10.15), the
|
||||||
# Pattern matching, line processing, and regular expression support are available natively,
|
# default login shell has been zsh, but bash remains available at '/bin/bash'. Windows support. You can use bash via WSL, MSYS2,
|
||||||
# no external binaries required.
|
# or Cygwin on Windows systems.
|
||||||
# Cross-platform consistency.
|
|
||||||
# '/bin/bash' is the default shell on most Linux distributions, ensuring scripts run unmodified across systems.
|
|
||||||
# macOS compatibility.
|
|
||||||
# Since macOS Catalina (10.15), the default login shell has been zsh, but bash remains available at '/bin/bash'.
|
|
||||||
# Windows support.
|
|
||||||
# You can use bash via WSL, MSYS2, or Cygwin on Windows systems.
|
|
||||||
|
|
||||||
### Preliminary checks
|
### CATCH ARGUMENTS AND DECLARE BASIC VARIABLES.
|
||||||
|
# shellcheck disable=SC2155
|
||||||
|
declare -girx VAR_START_TIME="${SECONDS}" # Start time of script execution.
|
||||||
|
declare -grx VAR_PARAM_COUNT="$#" # Arguments passed to script.
|
||||||
|
declare -grx VAR_PARAM_STRNG="$*" # Arguments passed to script as string.
|
||||||
|
declare -ag ARY_PARAM_ARRAY=("$@") # Arguments passed to script as an array.
|
||||||
|
declare -grx VAR_SETUP_FILE="${0##*/}" # 'ciss_debian_live_builder.sh'
|
||||||
|
declare -grx VAR_SETUP_PATH="$(cd "$(dirname "${0}")" && pwd)" # '/opt/git/CISS.debian.live.builder'
|
||||||
|
declare -grx VAR_SETUP_FULL="$(cd "$(dirname "${0}")" && pwd)/${0##*/}" # '/opt/git/CISS.debian.live.builder/ciss_debian_live_builder.sh'
|
||||||
|
# shellcheck disable=SC2155
|
||||||
|
declare -grx SCRIPT_FULLPATH="$(readlink -f "${BASH_SOURCE[0]:-$0}")"
|
||||||
|
# shellcheck disable=SC2155
|
||||||
|
declare -grx SCRIPT_BASEPATH="$(dirname "${SCRIPT_FULLPATH}")"
|
||||||
|
# shellcheck disable=SC2155
|
||||||
|
declare -grx VAR_WORKDIR="$(dirname "${SCRIPT_FULLPATH}")"
|
||||||
|
|
||||||
|
### PRELIMINARY CHECKS.
|
||||||
|
### No ash, dash, ksh, sh.
|
||||||
|
# shellcheck disable=2292
|
||||||
[ -z "${BASH_VERSINFO[0]}" ] && {
|
[ -z "${BASH_VERSINFO[0]}" ] && {
|
||||||
. ./var/global.var.sh; printf "\e[91m❌ Please make sure you are using 'bash'! Bye... \e[0m\n" >&2; exit "${ERR_UNSPPTBASH}"; }
|
|
||||||
[[ ${EUID} -ne 0 ]] && {
|
|
||||||
. ./var/global.var.sh; printf "\e[91m❌ Please make sure you are 'root'! Bye... \e[0m\n" >&2; exit "${ERR_NOT_USER_0}"; }
|
|
||||||
[[ $(kill -l | grep -c SIG) -eq 0 ]] && {
|
|
||||||
. ./var/global.var.sh; printf "\e[91m❌ Please make sure you are calling the script without leading 'sh'! Bye... \e[0m\n" >&2; exit "${ERR_UNSPPTBASH}"; }
|
|
||||||
[[ ${BASH_VERSINFO[0]} -lt 5 ]] && {
|
|
||||||
. ./var/global.var.sh; printf "\e[91m❌ Minimum requirement is bash 5.1. You are using '%s'! Bye... \e[0m\n" "${BASH_VERSION}" >&2; exit "${ERR_UNSPPTBASH}"; }
|
|
||||||
[[ ${BASH_VERSINFO[0]} -le 5 ]] && [[ ${BASH_VERSINFO[1]} -le 1 ]] && {
|
|
||||||
. ./var/global.var.sh; printf "\e[91m❌ Minimum requirement is bash 5.1. You are using '%s'! Bye... \e[0m\n" "${BASH_VERSION}" >&2; exit "${ERR_UNSPPTBASH}"; }
|
|
||||||
|
|
||||||
declare -gr VAR_VERSION="Master V8.02.644.2025.05.31"
|
|
||||||
declare -gr VAR_CONTACT="security@coresecret.eu"
|
|
||||||
|
|
||||||
### VERY EARLY CHECK FOR AUTO-BUILD, CONTACT, USAGE, AND VERSION STRING
|
|
||||||
declare arg
|
|
||||||
if [[ ${#} -eq 0 ]]; then . ./lib/lib_usage.sh; usage; exit 1; fi
|
|
||||||
for arg in "$@"; do case "${arg,,}" in -a=*|--autobuild=*) declare -g VAR_HANDLER_AUTOBUILD=true; declare -g VAR_KERNEL="${arg#*=}";; esac; done
|
|
||||||
for arg in "$@"; do case "${arg,,}" in -c|--contact) printf "\e[95mCISS.debian.live.builder Contact: %s\e[0m\n" "${VAR_CONTACT}"; exit 0;; esac; done
|
|
||||||
for arg in "$@"; do case "${arg,,}" in -h|--help) . ./lib/lib_usage.sh; usage; exit 0;; esac; done
|
|
||||||
for arg in "$@"; do case "${arg,,}" in -v|--version) printf "\e[95mCISS.debian.live.builder Version: %s\e[0m\n" "${VAR_VERSION}"; exit 0;; esac; done
|
|
||||||
unset arg
|
|
||||||
|
|
||||||
### VERY EARLY CHECK FOR XTRACE DEBUGGING
|
|
||||||
if [[ $* == *" --debug "* ]]; then
|
|
||||||
. ./lib/lib_debug.sh
|
|
||||||
debugger "${@}"
|
|
||||||
else
|
|
||||||
declare -grx VAR_EARLY_DEBUG=false
|
|
||||||
fi
|
|
||||||
|
|
||||||
### Advisory Lock
|
|
||||||
exec 127>/var/lock/ciss_live_builder.lock || {
|
|
||||||
. ./var/global.var.sh
|
. ./var/global.var.sh
|
||||||
|
printf "\e[91m❌ Please make sure you are using 'bash'! Bye... \e[0m\n" >&2
|
||||||
|
exit "${ERR_UNSPPTBASH}"
|
||||||
|
}
|
||||||
|
|
||||||
|
### No zsh.
|
||||||
|
[[ -n "${ZSH_VERSION:-}" ]] && {
|
||||||
|
. ./var/global.var.sh
|
||||||
|
printf "\e[91m❌ Please make sure you are using 'bash'! Bye... \e[0m\n" >&2
|
||||||
|
exit "${ERR_UNSPPTBASH}"
|
||||||
|
}
|
||||||
|
|
||||||
|
### Not root.
|
||||||
|
[[ ${EUID} -ne 0 ]] && {
|
||||||
|
. ./var/global.var.sh
|
||||||
|
printf "\e[91m❌ Please make sure you are 'root'! Bye... \e[0m\n" >&2
|
||||||
|
exit "${ERR_NOT_USER_0}"
|
||||||
|
}
|
||||||
|
|
||||||
|
### Check to be not called by sh.
|
||||||
|
# shellcheck disable=2312
|
||||||
|
[[ $(kill -l | grep -c SIG) -eq 0 ]] && {
|
||||||
|
. ./var/global.var.sh
|
||||||
|
printf "\e[91m❌ Please make sure you are calling the script without leading 'sh'! Bye... \e[0m\n" >&2
|
||||||
|
exit "${ERR_UNSPPTBASH}"
|
||||||
|
}
|
||||||
|
|
||||||
|
### Check to be not sourced.
|
||||||
|
[[ "${BASH_SOURCE[0]}" != "$0" ]] && {
|
||||||
|
. ./var/global.var.sh
|
||||||
|
printf "\e[91m❌ This script must be executed, not sourced. Please run '%s' directly! Bye... \e[0m\n" "$0" >&2
|
||||||
|
exit "${ERR_UNSPPTBASH}"
|
||||||
|
}
|
||||||
|
|
||||||
|
### Minimum Bash version 5.
|
||||||
|
[[ ${BASH_VERSINFO[0]} -lt 5 ]] && {
|
||||||
|
. ./var/global.var.sh
|
||||||
|
printf "\e[91m❌ Minimum requirement is bash 5.1. You are using '%s'! Bye... \e[0m\n" "${BASH_VERSION}" >&2
|
||||||
|
exit "${ERR_UNSPPTBASH}"
|
||||||
|
}
|
||||||
|
|
||||||
|
### Minimum Bash version 5.1.
|
||||||
|
[[ ${BASH_VERSINFO[0]} -le 5 ]] && [[ ${BASH_VERSINFO[1]} -le 1 ]] && {
|
||||||
|
. ./var/global.var.sh
|
||||||
|
printf "\e[91m❌ Minimum requirement is bash 5.1. You are using '%s'! Bye... \e[0m\n" "${BASH_VERSION}" >&2
|
||||||
|
exit "${ERR_UNSPPTBASH}"
|
||||||
|
}
|
||||||
|
|
||||||
|
### No arguments.
|
||||||
|
[[ ${#} -eq 0 ]] && {
|
||||||
|
. ./lib/lib_usage.sh
|
||||||
|
usage
|
||||||
|
exit 1
|
||||||
|
}
|
||||||
|
|
||||||
|
### SOURCING MUST SET EARLY VARIABLES, GUARD_SOURCING(), CHECK_GIT()
|
||||||
|
. ./var/early.var.sh
|
||||||
|
. ./lib/lib_guard_sourcing.sh
|
||||||
|
. ./lib/lib_source_guard.sh
|
||||||
|
source_guard "./lib/lib_git_var.sh"
|
||||||
|
|
||||||
|
### CHECK FOR CONTACT, HELP, VERSION STRING, AND XTRACE DEBUG
|
||||||
|
for arg in "$@"; do case "${arg,,}" in -c|--contact) . ./lib/lib_contact.sh; contact; exit 0;; esac; done
|
||||||
|
for arg in "$@"; do case "${arg,,}" in -h|--help) . ./lib/lib_usage.sh ; usage ; exit 0;; esac; done
|
||||||
|
for arg in "$@"; do case "${arg,,}" in -v|--version) . ./lib/lib_version.sh; version; exit 0;; esac; done
|
||||||
|
|
||||||
|
### ALL CHECKS DONE. READY TO START THE SCRIPT
|
||||||
|
source_guard "./var/bash.var.sh"
|
||||||
|
check_git
|
||||||
|
for arg in "$@"; do case "${arg,,}" in -d|--debug) . ./meta_sources_debug.sh; debugger "${@}";; esac; done
|
||||||
|
declare -gx VAR_SETUP="true"
|
||||||
|
|
||||||
|
### SOURCING VARIABLES
|
||||||
|
[[ "${VAR_SETUP}" == true ]] && {
|
||||||
|
source_guard "./var/color.var.sh"
|
||||||
|
source_guard "./var/global.var.sh"
|
||||||
|
}
|
||||||
|
|
||||||
|
### SOURCING LIBRARIES
|
||||||
|
[[ "${VAR_SETUP}" == true ]] && {
|
||||||
|
source_guard "./lib/lib_arg_parser.sh"
|
||||||
|
source_guard "./lib/lib_arg_priority_check.sh"
|
||||||
|
source_guard "./lib/lib_boot_screen.sh"
|
||||||
|
source_guard "./lib/lib_cdi.sh"
|
||||||
|
source_guard "./lib/lib_change_splash.sh"
|
||||||
|
source_guard "./lib/lib_check_dhcp.sh"
|
||||||
|
source_guard "./lib/lib_check_hooks.sh"
|
||||||
|
source_guard "./lib/lib_check_kernel.sh"
|
||||||
|
source_guard "./lib/lib_check_pkgs.sh"
|
||||||
|
source_guard "./lib/lib_check_provider.sh"
|
||||||
|
source_guard "./lib/lib_check_stats.sh"
|
||||||
|
source_guard "./lib/lib_check_var.sh"
|
||||||
|
source_guard "./lib/lib_clean_screen.sh"
|
||||||
|
source_guard "./lib/lib_clean_up.sh"
|
||||||
|
source_guard "./lib/lib_copy_integrity.sh"
|
||||||
|
source_guard "./lib/lib_hardening_root_pw.sh"
|
||||||
|
source_guard "./lib/lib_hardening_ssh.sh"
|
||||||
|
source_guard "./lib/lib_hardening_ultra.sh"
|
||||||
|
source_guard "./lib/lib_helper_ip.sh"
|
||||||
|
source_guard "./lib/lib_lb_build_start.sh"
|
||||||
|
source_guard "./lib/lib_lb_config_start.sh"
|
||||||
|
source_guard "./lib/lib_lb_config_write.sh"
|
||||||
|
source_guard "./lib/lib_lb_config_write_trixie.sh"
|
||||||
|
source_guard "./lib/lib_note_target.sh"
|
||||||
|
source_guard "./lib/lib_provider_netcup.sh"
|
||||||
|
source_guard "./lib/lib_run_analysis.sh"
|
||||||
|
source_guard "./lib/lib_sanitizer.sh"
|
||||||
|
source_guard "./lib/lib_trap_on_err.sh"
|
||||||
|
source_guard "./lib/lib_trap_on_exit.sh"
|
||||||
|
source_guard "./lib/lib_usage.sh"
|
||||||
|
}
|
||||||
|
|
||||||
|
### ADVISORY LOCK
|
||||||
|
exec 127>/var/lock/ciss_live_builder.lock || {
|
||||||
printf "\e[91m❌ Cannot open lockfile for writing! Bye... \e[0m\n" >&2
|
printf "\e[91m❌ Cannot open lockfile for writing! Bye... \e[0m\n" >&2
|
||||||
exit "${ERR_FLOCK_WRTG}"
|
exit "${ERR_FLOCK_WRTG}"
|
||||||
}
|
}
|
||||||
|
|
||||||
if ! flock -x -n 127; then
|
if ! flock -x -n 127; then
|
||||||
. ./var/global.var.sh
|
|
||||||
printf "\e[91m❌ Another instance is running! Bye...\e[0m\n" >&2
|
printf "\e[91m❌ Another instance is running! Bye...\e[0m\n" >&2
|
||||||
exit "${ERR_FLOCK_COLL}"
|
exit "${ERR_FLOCK_COLL}"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
### Checking required packages
|
### CHECK FOR AUTOBUILD MODE
|
||||||
. ./lib/lib_check_pkgs.sh
|
for arg in "$@"; do case "${arg,,}" in -a=*|--autobuild=*) declare -gx VAR_HANDLER_AUTOBUILD="true"; declare -gx VAR_KERNEL="${arg#*=}";; esac; done; unset arg
|
||||||
|
for dir in /usr/local/sbin /usr/sbin; do case ":${PATH}:" in *":${dir}:"*) ;; *) PATH="${PATH}:${dir}" ;; esac; done; export PATH; unset dir
|
||||||
|
|
||||||
|
### CHECKING REQUIRED PACKAGES
|
||||||
check_pkgs
|
check_pkgs
|
||||||
|
|
||||||
### Dialog Output for Initialization
|
### DIALOG OUTPUT FOR INITIALIZATION
|
||||||
if ! $VAR_HANDLER_AUTOBUILD; then . ./lib/lib_boot_screen.sh && boot_screen; fi
|
if ! ${VAR_HANDLER_AUTOBUILD}; then boot_screen; fi
|
||||||
|
|
||||||
### Updating Status of Dialog Gauge Bar
|
### Updating Status of Dialog Gauge Bar
|
||||||
if ! $VAR_HANDLER_AUTOBUILD; then printf "XXX\nUpdating variables ... \nXXX\n05\n" >&3; fi
|
if ! ${VAR_HANDLER_AUTOBUILD}; then printf "XXX\nInitialization done ... \nXXX\n15\n" >&3; fi
|
||||||
. ./var/global.var.sh
|
|
||||||
. ./var/colors.var.sh
|
|
||||||
|
|
||||||
### Updating Status of Dialog Gauge Bar
|
### Updating Status of Dialog Gauge Bar
|
||||||
if ! $VAR_HANDLER_AUTOBUILD; then printf "XXX\nEnabling Bash Error Handling ... \nXXX\n15\n" >&3; fi
|
if ! ${VAR_HANDLER_AUTOBUILD}; then printf "XXX\nAdditional initialization ... \nXXX\n30\n" >&3; fi
|
||||||
### For all options see https://www.gnu.org/software/bash/manual/bash.html#The-Set-Builtin
|
|
||||||
set -o errexit # Exit script when a command exits with non-zero status, the same as "set -e".
|
|
||||||
set -o errtrace # Any traps on ERR are inherited in a subshell environment, the same as "set -E".
|
|
||||||
set -o functrace # Any traps on DEBUG and RETURN are inherited in a subshell environment, the same as "set -T".
|
|
||||||
set -o nounset # Exit script on use of an undefined variable, the same as "set -u".
|
|
||||||
set -o pipefail # Makes pipelines return the exit status of the last command in the pipe that failed.
|
|
||||||
set -o noclobber # Prevent overwriting, the same as "set -C".
|
|
||||||
|
|
||||||
### Updating Status of Dialog Gauge Bar
|
### Updating Status of Dialog Gauge Bar
|
||||||
if ! $VAR_HANDLER_AUTOBUILD; then printf "XXX\nAdditional initialization ... \nXXX\n25\n" >&3; fi
|
if ! ${VAR_HANDLER_AUTOBUILD}; then printf "XXX\nActivate traps ... \nXXX\n50\n" >&3; fi
|
||||||
### Initialization
|
### Following the CISS Bash naming and ordering scheme:
|
||||||
declare -gr ARGUMENTS_COUNT="$#"
|
|
||||||
declare -gr ARG_STR_ORG_INPUT="$*"
|
|
||||||
#declare -ar ARG_ARY_ORG_INPUT=("$@")
|
|
||||||
# shellcheck disable=SC2155
|
|
||||||
declare -gr SCRIPT_FULLPATH="$(readlink -f "${BASH_SOURCE[0]:-$0}")"
|
|
||||||
# shellcheck disable=SC2155
|
|
||||||
declare -grx VAR_WORKDIR="$(dirname "${SCRIPT_FULLPATH}")"
|
|
||||||
|
|
||||||
### Updating Status of Dialog Gauge Bar
|
|
||||||
if ! $VAR_HANDLER_AUTOBUILD; then printf "XXX\nSourcing Libraries ... \nXXX\n50\n" >&3; fi
|
|
||||||
. ./lib/lib_arg_parser.sh
|
|
||||||
. ./lib/lib_arg_priority_check.sh
|
|
||||||
. ./lib/lib_cdi.sh
|
|
||||||
. ./lib/lib_change_splash.sh
|
|
||||||
. ./lib/lib_check_dhcp.sh
|
|
||||||
. ./lib/lib_check_hooks.sh
|
|
||||||
. ./lib/lib_check_kernel.sh
|
|
||||||
. ./lib/lib_check_provider.sh
|
|
||||||
. ./lib/lib_check_stats.sh
|
|
||||||
. ./lib/lib_check_var.sh
|
|
||||||
. ./lib/lib_clean_screen.sh
|
|
||||||
. ./lib/lib_clean_up.sh
|
|
||||||
. ./lib/lib_copy_integrity.sh
|
|
||||||
. ./lib/lib_hardening_root_pw.sh
|
|
||||||
. ./lib/lib_hardening_ssh.sh
|
|
||||||
. ./lib/lib_hardening_ultra.sh
|
|
||||||
. ./lib/lib_helper_ip.sh
|
|
||||||
. ./lib/lib_lb_build_start.sh
|
|
||||||
. ./lib/lib_lb_config_start.sh
|
|
||||||
. ./lib/lib_lb_config_write.sh
|
|
||||||
. ./lib/lib_provider_netcup.sh
|
|
||||||
. ./lib/lib_run_analysis.sh
|
|
||||||
. ./lib/lib_sanitizer.sh
|
|
||||||
. ./lib/lib_trap_on_err.sh
|
|
||||||
. ./lib/lib_trap_on_exit.sh
|
|
||||||
. ./lib/lib_usage.sh
|
|
||||||
|
|
||||||
### Updating Status of Dialog Gauge Bar
|
|
||||||
if ! $VAR_HANDLER_AUTOBUILD; then printf "XXX\nActivate traps ... \nXXX\n55\n" >&3; fi
|
|
||||||
### Following the CISS Bash naming and ordering scheme
|
|
||||||
trap 'trap_on_exit "$?"' EXIT
|
trap 'trap_on_exit "$?"' EXIT
|
||||||
trap 'trap_on_err "$?" "${BASH_SOURCE[0]}" "${LINENO}" "${FUNCNAME[0]:-main}" "${BASH_COMMAND}"' ERR
|
trap 'trap_on_err "$?" "${BASH_SOURCE[0]}" "${LINENO}" "${FUNCNAME[0]:-main}" "${BASH_COMMAND}"' ERR
|
||||||
|
|
||||||
### Updating Status of Dialog Gauge Bar
|
### Updating Status of Dialog Gauge Bar
|
||||||
if ! $VAR_HANDLER_AUTOBUILD; then printf "XXX\nSanitizing Arguments ... \nXXX\n70\n" >&3; fi
|
if ! ${VAR_HANDLER_AUTOBUILD}; then printf "XXX\nSanitizing Arguments ... \nXXX\n75\n" >&3; fi
|
||||||
arg_check "$@"
|
arg_check "$@"
|
||||||
declare -ar ARG_ARY_SANITIZED=("$@")
|
declare -ar ARY_ARG_SANITIZED=("$@")
|
||||||
declare -gr ARG_STR_SANITIZED="${ARG_ARY_SANITIZED[*]}"
|
declare -gr VAR_ARG_SANITIZED="${ARY_ARG_SANITIZED[*]}"
|
||||||
|
|
||||||
### Updating Status of Dialog Gauge Bar
|
### Updating Status of Dialog Gauge Bar
|
||||||
if ! $VAR_HANDLER_AUTOBUILD; then printf "XXX\nParsing Arguments ... \nXXX\n90\n" >&3; fi
|
if ! ${VAR_HANDLER_AUTOBUILD}; then printf "XXX\nParsing Arguments ... \nXXX\n90\n" >&3; fi
|
||||||
arg_parser "$@"
|
arg_parser "$@"
|
||||||
|
|
||||||
### Updating Status of Dialog Gauge Bar
|
### Updating Status of Dialog Gauge Bar
|
||||||
if ! $VAR_HANDLER_AUTOBUILD; then printf "XXX\nFinal checks ... \nXXX\n95\n" >&3; fi
|
if ! ${VAR_HANDLER_AUTOBUILD}; then printf "XXX\nFinal checks ... \nXXX\n95\n" >&3; fi
|
||||||
clean_ip
|
clean_ip
|
||||||
|
|
||||||
### Updating Status of Dialog Gauge Bar
|
### Updating Status of Dialog Gauge Bar
|
||||||
if ! $VAR_HANDLER_AUTOBUILD; then printf "XXX\nInitialization completed ... \nXXX\n100\n" >&3; sleep 1; fi
|
if ! ${VAR_HANDLER_AUTOBUILD}; then printf "XXX\nInitialization completed ... \nXXX\n100\n" >&3; sleep 1; fi
|
||||||
|
|
||||||
if ! $VAR_HANDLER_AUTOBUILD; then boot_screen_cleaner; fi
|
### Turn off Dialog Wrapper
|
||||||
|
if ! ${VAR_HANDLER_AUTOBUILD}; then boot_screen_cleaner; fi
|
||||||
|
|
||||||
### MAIN Program
|
### MAIN Program
|
||||||
arg_priority_check
|
arg_priority_check
|
||||||
check_stats
|
check_stats
|
||||||
if ! $VAR_HANDLER_AUTOBUILD; then check_provider; fi
|
if ! ${VAR_HANDLER_AUTOBUILD}; then check_provider; fi
|
||||||
if ! $VAR_HANDLER_AUTOBUILD; then check_kernel; fi
|
if ! ${VAR_HANDLER_AUTOBUILD}; then check_kernel; fi
|
||||||
|
|
||||||
|
if [[ ! "${VAR_SSHFP}" == "true" ]]; then
|
||||||
|
rm -f "${SCRIPT_BASEPATH}/config/includes.chroot/root/.ssh/id_2025_ed25519_ciss_primordial"
|
||||||
|
rm -f "${SCRIPT_BASEPATH}/config/includes.chroot/root/.ssh/id_2025_ed25519_ciss_primordial.pub"
|
||||||
|
fi
|
||||||
|
|
||||||
check_hooks
|
check_hooks
|
||||||
hardening_ssh
|
hardening_ssh
|
||||||
lb_config_start
|
lb_config_start
|
||||||
lb_config_write
|
|
||||||
|
|
||||||
|
if [[ "${VAR_SUITE}" == "bookworm" ]]; then
|
||||||
|
|
||||||
|
lb_config_write
|
||||||
|
rm -f "${SCRIPT_BASEPATH}/config/hooks/live/9998_sources_list_trixie.chroot"
|
||||||
|
rm -f "${SCRIPT_BASEPATH}/config/includes.chroot/etc/login.defs"
|
||||||
|
|
||||||
|
else
|
||||||
|
|
||||||
|
lb_config_write_trixie
|
||||||
|
rm -f "${SCRIPT_BASEPATH}/config/hooks/live/0003_install_backports.chroot"
|
||||||
|
rm -f "${SCRIPT_BASEPATH}/config/hooks/live/9998_sources_list_bookworm.chroot"
|
||||||
|
|
||||||
|
fi
|
||||||
|
|
||||||
|
# shellcheck disable=SC2164
|
||||||
cd "${VAR_WORKDIR}"
|
cd "${VAR_WORKDIR}"
|
||||||
|
|
||||||
hardening_ultra
|
hardening_ultra
|
||||||
hardening_root_pw
|
hardening_root_pw
|
||||||
change_splash
|
change_splash
|
||||||
check_dhcp
|
check_dhcp
|
||||||
cdi
|
cdi
|
||||||
provider_netcup
|
provider_netcup
|
||||||
|
note_target
|
||||||
|
|
||||||
### Start the build process
|
### Start the build process
|
||||||
set +o errtrace
|
set +o errtrace
|
||||||
|
|||||||
21
config.mk.sample
Normal file
21
config.mk.sample
Normal file
@@ -0,0 +1,21 @@
|
|||||||
|
# SPDX-Version: 3.0
|
||||||
|
# SPDX-CreationInfo: 2025-08-21; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
|
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
||||||
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
|
# SPDX-FileType: SOURCE
|
||||||
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
|
# SPDX-PackageName: CISS.debian.live.builder
|
||||||
|
# SPDX-Security-Contact: security@coresecret.eu
|
||||||
|
|
||||||
|
BUILD_DIR ?=
|
||||||
|
PROVIDER_NETCUP_IPV6 ?=
|
||||||
|
ROOT_PASSWORD_FILE ?=
|
||||||
|
SSH_PORT ?=
|
||||||
|
SSH_PUBKEY ?=
|
||||||
|
|
||||||
|
### Comma-separated jump hosts (can be empty):
|
||||||
|
JUMP_HOSTS ?=
|
||||||
|
|
||||||
|
# vim: set ft=make noet ts=8 sw=8
|
||||||
@@ -2,7 +2,7 @@
|
|||||||
# SPDX-CreationInfo: 2025-05-05; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-CreationInfo: 2025-05-05; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
||||||
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
# SPDX-FileCopyrightText: 2024–2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-FileType: SOURCE
|
# SPDX-FileType: SOURCE
|
||||||
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
|
|||||||
@@ -2,7 +2,7 @@
|
|||||||
# SPDX-CreationInfo: 2025-05-05; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-CreationInfo: 2025-05-05; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
||||||
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
# SPDX-FileCopyrightText: 2024–2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-FileType: SOURCE
|
# SPDX-FileType: SOURCE
|
||||||
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
|
|||||||
@@ -1,27 +1,28 @@
|
|||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
# SPDX-Version: 3.0
|
# SPDX-Version: 3.0
|
||||||
# SPDX-CreationInfo: 2025-05-05; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-CreationInfo: 2025-10-11; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
||||||
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
# SPDX-FileCopyrightText: 2024–2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-FileType: SOURCE
|
# SPDX-FileType: SOURCE
|
||||||
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
# SPDX-PackageName: CISS.debian.live.builder
|
# SPDX-PackageName: CISS.debian.live.builder
|
||||||
# SPDX-Security-Contact: security@coresecret.eu
|
# SPDX-Security-Contact: security@coresecret.eu
|
||||||
set -C -e -u -o pipefail
|
set -Ceuo pipefail
|
||||||
|
|
||||||
printf "\e[95m++++ ++++ ++++ ++++ ++++ ++++ ++ 🧪 '%s' starting ... \e[0m\n" "${0}"
|
printf "\e[95m++++ ++++ ++++ ++++ ++++ ++++ ++ 🧪 '%s' starting ... \e[0m\n" "${0}"
|
||||||
# sleep 1
|
|
||||||
|
|
||||||
mkdir -p /root/.ciss/dlb/backup
|
export DEBIAN_FRONTEND="noninteractive"
|
||||||
chmod 0700 /root/.ciss/dlb/backup
|
apt-get update -qq
|
||||||
|
|
||||||
|
mkdir -p /root/.ciss/dlb/{backup,log}
|
||||||
|
chmod 0700 /root/.ciss/dlb/{backup,log}
|
||||||
|
|
||||||
mkdir -p /root/git
|
mkdir -p /root/git
|
||||||
chmod 0700 /root/git
|
chmod 0700 /root/git
|
||||||
|
|
||||||
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ '%s' applied successfully. \e[0m\n" "${0}"
|
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ '%s' applied successfully. \e[0m\n" "${0}"
|
||||||
# sleep 1
|
|
||||||
|
|
||||||
exit 0
|
exit 0
|
||||||
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=sh
|
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=sh
|
||||||
@@ -1,27 +1,32 @@
|
|||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
# SPDX-Version: 3.0
|
# SPDX-Version: 3.0
|
||||||
# SPDX-CreationInfo: 2025-05-05; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-CreationInfo: 2025-10-11; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
||||||
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
# SPDX-FileCopyrightText: 2024–2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-FileType: SOURCE
|
# SPDX-FileType: SOURCE
|
||||||
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
# SPDX-LicenseComment: This file is part of the CISS.hardened.installer framework.
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
# SPDX-PackageName: CISS.debian.live.builder
|
# SPDX-PackageName: CISS.debian.live.builder
|
||||||
# SPDX-Security-Contact: security@coresecret.eu
|
# SPDX-Security-Contact: security@coresecret.eu
|
||||||
set -C -e -u -o pipefail
|
set -Ceuo pipefail
|
||||||
|
|
||||||
printf "\e[95m++++ ++++ ++++ ++++ ++++ ++++ ++ 🧪 '%s' starting ... \e[0m\n" "${0}"
|
printf "\e[95m++++ ++++ ++++ ++++ ++++ ++++ ++ 🧪 '%s' starting ... \e[0m\n" "${0}"
|
||||||
# sleep 1
|
|
||||||
|
|
||||||
#######################################
|
#######################################
|
||||||
# Get all NIC Driver of the current Host-machine
|
# Get all NIC drivers of the current Host machine.
|
||||||
|
# Globals:
|
||||||
|
# None
|
||||||
# Arguments:
|
# Arguments:
|
||||||
# None
|
# None
|
||||||
|
# Returns:
|
||||||
|
# 0: on success
|
||||||
#######################################
|
#######################################
|
||||||
grep_nic_driver_modules() {
|
grep_nic_driver_modules() {
|
||||||
declare _mods
|
declare _mods
|
||||||
# Gather all Driver and sort unique
|
|
||||||
|
### Gather all Driver and sort unique.
|
||||||
|
# shellcheck disable=SC2312
|
||||||
readarray -t _mods < <(
|
readarray -t _mods < <(
|
||||||
lspci -k \
|
lspci -k \
|
||||||
| grep -A2 -i ethernet \
|
| grep -A2 -i ethernet \
|
||||||
@@ -32,26 +37,36 @@ grep_nic_driver_modules() {
|
|||||||
|
|
||||||
declare nic_module
|
declare nic_module
|
||||||
declare nic_modules
|
declare nic_modules
|
||||||
|
|
||||||
if [[ "${#_mods[@]}" -eq 1 ]]; then
|
if [[ "${#_mods[@]}" -eq 1 ]]; then
|
||||||
|
|
||||||
nic_module="${_mods[0]}"
|
nic_module="${_mods[0]}"
|
||||||
echo "${nic_module}"
|
echo "${nic_module}"
|
||||||
|
|
||||||
else
|
else
|
||||||
|
|
||||||
nic_modules="${_mods[*]}"
|
nic_modules="${_mods[*]}"
|
||||||
echo "${nic_modules}"
|
echo "${nic_modules}"
|
||||||
|
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
return 0
|
||||||
}
|
}
|
||||||
|
|
||||||
|
export DEBIAN_FRONTEND="noninteractive"
|
||||||
|
apt-get install -y intel-microcode amd64-microcode
|
||||||
|
|
||||||
# shellcheck disable=SC2155
|
# shellcheck disable=SC2155
|
||||||
declare nic_driver="$(grep_nic_driver_modules)"
|
declare nic_driver="$(grep_nic_driver_modules)"
|
||||||
cat << EOF >| /etc/initramfs-tools/modules
|
cat << EOF >| /etc/initramfs-tools/modules
|
||||||
# SPDX-Version: 3.0
|
# SPDX-Version: 3.0
|
||||||
# SPDX-CreationInfo: 2025-05-05; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-CreationInfo: 2025-10-11; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
||||||
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
# SPDX-FileCopyrightText: 2024–2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-FileType: SOURCE
|
# SPDX-FileType: SOURCE
|
||||||
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
# SPDX-LicenseComment: This file is part of the CISS.hardened.installer framework.
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
# SPDX-PackageName: CISS.debian.live.builder
|
# SPDX-PackageName: CISS.debian.live.builder
|
||||||
# SPDX-Security-Contact: security@coresecret.eu
|
# SPDX-Security-Contact: security@coresecret.eu
|
||||||
|
|
||||||
@@ -67,56 +82,111 @@ cat << EOF >| /etc/initramfs-tools/modules
|
|||||||
# raid1
|
# raid1
|
||||||
# sd_mod
|
# sd_mod
|
||||||
|
|
||||||
### QEMU Bochs-compatible virtual machine support
|
### Load AppArmor early:
|
||||||
bochs
|
apparmor
|
||||||
|
|
||||||
### Device-mapper core module (required for all dm_* features)
|
### Entropy source for '/dev/random':
|
||||||
dm_mod
|
jitterentropy_rng
|
||||||
|
rng_core
|
||||||
|
|
||||||
### Device-mapper integrity target (provides integrity checking)
|
### Live-ISO-Stack:
|
||||||
dm-integrity
|
loop
|
||||||
|
squashfs
|
||||||
|
overlay
|
||||||
|
|
||||||
### Device-mapper crypt target (provides disk encryption)
|
### Main btrfs-Stack:
|
||||||
dm-crypt
|
|
||||||
|
|
||||||
### Generic AES block cipher implementation (used by dm-crypt)
|
|
||||||
aes_generic
|
|
||||||
|
|
||||||
### Generic SHA-256 hashing algorithm (used by various crypto and integrity targets)
|
|
||||||
sha256_generic
|
|
||||||
|
|
||||||
### Generic CRC32C checksum implementation (used by btrfs and other filesystems)
|
|
||||||
crc32c_generic
|
|
||||||
|
|
||||||
### Main btrfs filesystem module
|
|
||||||
btrfs
|
btrfs
|
||||||
|
lzo
|
||||||
### Zstandard compression support for btrfs
|
xor
|
||||||
|
xxhash
|
||||||
|
zstd
|
||||||
zstd_compress
|
zstd_compress
|
||||||
|
|
||||||
### XOR parity implementation for RAID functionality
|
### Main ext4-Stack:
|
||||||
xor
|
ext4
|
||||||
|
jbd2
|
||||||
|
libcrc32c
|
||||||
|
|
||||||
### RAID6 parity generation module
|
### Main VFAT/ESP/FAT/UEFI-Stack:
|
||||||
|
exfat
|
||||||
|
fat
|
||||||
|
nls_ascii
|
||||||
|
nls_cp437
|
||||||
|
nls_iso8859-1
|
||||||
|
nls_iso8859-15
|
||||||
|
nls_utf8
|
||||||
|
vfat
|
||||||
|
|
||||||
|
### Device mapper, encryption & integrity:
|
||||||
|
dm_mod
|
||||||
|
dm_crypt
|
||||||
|
dm_integrity
|
||||||
|
dm_verity
|
||||||
|
|
||||||
|
### Main cryptography-Stack:
|
||||||
|
aes_generic
|
||||||
|
blake2b_generic
|
||||||
|
crc32c_generic
|
||||||
|
cryptd
|
||||||
|
libcrc32c
|
||||||
|
sha256_generic
|
||||||
|
sha512_generic
|
||||||
|
xts
|
||||||
|
|
||||||
|
### QEMU Bochs-compatible virtual machine support:
|
||||||
|
bochs
|
||||||
|
|
||||||
|
### RAID6 parity generation module:
|
||||||
raid6_pq
|
raid6_pq
|
||||||
|
|
||||||
### Combined RAID4/5/6 support module
|
### Combined RAID4/5/6 support module:
|
||||||
raid456
|
raid456
|
||||||
|
|
||||||
### Network Driver Host-machine
|
### SCSI/SATA-Stack:
|
||||||
|
sd_mod
|
||||||
|
sr_mod
|
||||||
|
sg
|
||||||
|
ahci
|
||||||
|
libahci
|
||||||
|
ata_generic
|
||||||
|
libata
|
||||||
|
scsi_mod
|
||||||
|
scsi_dh_alua
|
||||||
|
|
||||||
|
### NVMe-Stack:
|
||||||
|
nvme
|
||||||
|
nvme_core
|
||||||
|
|
||||||
|
### USB-Stack:
|
||||||
|
xhci_pci
|
||||||
|
xhci_hcd
|
||||||
|
ehci_pci
|
||||||
|
ohci_pci
|
||||||
|
uhci_hcd
|
||||||
|
usb_storage
|
||||||
|
uas
|
||||||
|
|
||||||
|
### Virtual-Machines-Stack:
|
||||||
|
virtio_pci
|
||||||
|
virtio_blk
|
||||||
|
virtio_scsi
|
||||||
|
virtio_rng
|
||||||
|
virtio_console
|
||||||
|
|
||||||
|
### Network Driver Host-machine:
|
||||||
"${nic_driver}"
|
"${nic_driver}"
|
||||||
|
|
||||||
EOF
|
EOF
|
||||||
|
|
||||||
cat << 'EOF' >| /etc/initramfs-tools/update-initramfs.conf
|
cat << 'EOF' >| /etc/initramfs-tools/update-initramfs.conf
|
||||||
# SPDX-Version: 3.0
|
# SPDX-Version: 3.0
|
||||||
# SPDX-CreationInfo: 2025-05-05; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-CreationInfo: 2025-10-11; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
||||||
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
# SPDX-FileCopyrightText: 2024–2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-FileType: SOURCE
|
# SPDX-FileType: SOURCE
|
||||||
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
# SPDX-LicenseComment: This file is part of the CISS.hardened.installer framework.
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
# SPDX-PackageName: CISS.debian.live.builder
|
# SPDX-PackageName: CISS.debian.live.builder
|
||||||
# SPDX-Security-Contact: security@coresecret.eu
|
# SPDX-Security-Contact: security@coresecret.eu
|
||||||
|
|
||||||
@@ -145,13 +215,13 @@ EOF
|
|||||||
|
|
||||||
cat << 'EOF' >| /etc/initramfs-tools/initramfs.conf
|
cat << 'EOF' >| /etc/initramfs-tools/initramfs.conf
|
||||||
# SPDX-Version: 3.0
|
# SPDX-Version: 3.0
|
||||||
# SPDX-CreationInfo: 2025-05-05; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-CreationInfo: 2025-10-11; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
||||||
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
# SPDX-FileCopyrightText: 2024–2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-FileType: SOURCE
|
# SPDX-FileType: SOURCE
|
||||||
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
# SPDX-LicenseComment: This file is part of the CISS.hardened.installer framework.
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
# SPDX-PackageName: CISS.debian.live.builder
|
# SPDX-PackageName: CISS.debian.live.builder
|
||||||
# SPDX-Security-Contact: security@coresecret.eu
|
# SPDX-Security-Contact: security@coresecret.eu
|
||||||
|
|
||||||
@@ -207,9 +277,9 @@ COMPRESS=zstd
|
|||||||
# Defaults vary by compressor.
|
# Defaults vary by compressor.
|
||||||
#
|
#
|
||||||
# Valid values are:
|
# Valid values are:
|
||||||
# 1–9 for gzip|bzip2|lzma|lzop
|
# 1-9 for gzip|bzip2|lzma|lzop
|
||||||
# 0–9 for lz4|xz
|
# 0-9 for lz4|xz
|
||||||
# 0–19 for zstd
|
# 0-19 for zstd
|
||||||
# COMPRESSLEVEL=3
|
# COMPRESSLEVEL=3
|
||||||
|
|
||||||
#
|
#
|
||||||
@@ -250,13 +320,13 @@ EOF
|
|||||||
cat << 'EOF' >> /etc/initramfs-tools/hooks/ciss_debian_live_builder
|
cat << 'EOF' >> /etc/initramfs-tools/hooks/ciss_debian_live_builder
|
||||||
#!/bin/sh
|
#!/bin/sh
|
||||||
# SPDX-Version: 3.0
|
# SPDX-Version: 3.0
|
||||||
# SPDX-CreationInfo: 2025-05-05; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-CreationInfo: 2025-10-11; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
||||||
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
# SPDX-FileCopyrightText: 2024–2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-FileType: SOURCE
|
# SPDX-FileType: SOURCE
|
||||||
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
# SPDX-LicenseComment: This file is part of the CISS.hardened.installer framework.
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
# SPDX-PackageName: CISS.debian.live.builder
|
# SPDX-PackageName: CISS.debian.live.builder
|
||||||
# SPDX-Security-Contact: security@coresecret.eu
|
# SPDX-Security-Contact: security@coresecret.eu
|
||||||
|
|
||||||
@@ -285,10 +355,9 @@ EOF
|
|||||||
chmod 0755 /etc/initramfs-tools/hooks/ciss_debian_live_builder
|
chmod 0755 /etc/initramfs-tools/hooks/ciss_debian_live_builder
|
||||||
|
|
||||||
### Regenerate the initramfs for the live system kernel
|
### Regenerate the initramfs for the live system kernel
|
||||||
update-initramfs -u -k all
|
update-initramfs -u -k all -v
|
||||||
|
|
||||||
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ '%s' applied successfully. \e[0m\n" "${0}"
|
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ '%s' applied successfully. \e[0m\n" "${0}"
|
||||||
# sleep 1
|
|
||||||
|
|
||||||
exit 0
|
exit 0
|
||||||
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=sh
|
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=sh
|
||||||
|
|||||||
@@ -1,18 +1,17 @@
|
|||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
# SPDX-Version: 3.0
|
# SPDX-Version: 3.0
|
||||||
# SPDX-CreationInfo: 2025-05-05; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-CreationInfo: 2025-10-11; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
||||||
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
# SPDX-FileCopyrightText: 2024–2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-FileType: SOURCE
|
# SPDX-FileType: SOURCE
|
||||||
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
# SPDX-LicenseComment: This file is part of the CISS.hardened.installer framework.
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
# SPDX-PackageName: CISS.debian.live.builder
|
# SPDX-PackageName: CISS.debian.live.builder
|
||||||
# SPDX-Security-Contact: security@coresecret.eu
|
# SPDX-Security-Contact: security@coresecret.eu
|
||||||
set -C -e -u -o pipefail
|
set -Ceuo pipefail
|
||||||
|
|
||||||
printf "\e[95m++++ ++++ ++++ ++++ ++++ ++++ ++ 🧪 '%s' starting ... \e[0m\n" "${0}"
|
printf "\e[95m++++ ++++ ++++ ++++ ++++ ++++ ++ 🧪 '%s' starting ... \e[0m\n" "${0}"
|
||||||
# sleep 1
|
|
||||||
|
|
||||||
target="/usr/lib/live/boot/0030-verify-checksums"
|
target="/usr/lib/live/boot/0030-verify-checksums"
|
||||||
src="$(mktemp)"
|
src="$(mktemp)"
|
||||||
@@ -24,13 +23,13 @@ fi
|
|||||||
cat << 'EOF' >| "${src}"
|
cat << 'EOF' >| "${src}"
|
||||||
#!/bin/sh
|
#!/bin/sh
|
||||||
# SPDX-Version: 3.0
|
# SPDX-Version: 3.0
|
||||||
# SPDX-CreationInfo: 2025-05-05; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-CreationInfo: 2025-10-11; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
||||||
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
# SPDX-FileCopyrightText: 2024–2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-FileType: SOURCE
|
# SPDX-FileType: SOURCE
|
||||||
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
# SPDX-LicenseComment: This file is part of the CISS.hardened.installer framework.
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
# SPDX-PackageName: CISS.debian.live.builder
|
# SPDX-PackageName: CISS.debian.live.builder
|
||||||
# SPDX-Security-Contact: security@coresecret.eu
|
# SPDX-Security-Contact: security@coresecret.eu
|
||||||
|
|
||||||
@@ -138,7 +137,6 @@ rm -f "${src}"
|
|||||||
unset target src
|
unset target src
|
||||||
|
|
||||||
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ '%s' applied successfully. \e[0m\n" "${0}"
|
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ '%s' applied successfully. \e[0m\n" "${0}"
|
||||||
# sleep 1
|
|
||||||
|
|
||||||
exit 0
|
exit 0
|
||||||
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=sh
|
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=sh
|
||||||
|
|||||||
34
config/hooks/live/0010_install_apparmor.chroot
Normal file
34
config/hooks/live/0010_install_apparmor.chroot
Normal file
@@ -0,0 +1,34 @@
|
|||||||
|
#!/bin/bash
|
||||||
|
# SPDX-Version: 3.0
|
||||||
|
# SPDX-CreationInfo: 2025-10-11; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
|
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
||||||
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
|
# SPDX-FileType: SOURCE
|
||||||
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
|
# SPDX-PackageName: CISS.debian.live.builder
|
||||||
|
# SPDX-Security-Contact: security@coresecret.eu
|
||||||
|
set -Ceuo pipefail
|
||||||
|
|
||||||
|
printf "\e[95m++++ ++++ ++++ ++++ ++++ ++++ ++ 🧪 '%s' starting ... \e[0m\n" "${0}"
|
||||||
|
|
||||||
|
export DEBIAN_FRONTEND="noninteractive"
|
||||||
|
apt-get install -y --no-install-recommends apparmor apparmor-utils apparmor-profiles apparmor-profiles-extra
|
||||||
|
|
||||||
|
install -d /etc/systemd/system/apparmor.service.d
|
||||||
|
cat << EOF >| /etc/systemd/system/apparmor.service.d/10-live-force.conf
|
||||||
|
[Unit]
|
||||||
|
### Drop any negative live conditions that would skip AppArmor on overlay.
|
||||||
|
ConditionPathExists=
|
||||||
|
|
||||||
|
### Ensure we only rely on the security=apparmor condition.
|
||||||
|
ConditionSecurity=apparmor
|
||||||
|
EOF
|
||||||
|
|
||||||
|
install -d -m 0755 /var/cache/apparmor
|
||||||
|
|
||||||
|
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ '%s' applied successfully. \e[0m\n" "${0}"
|
||||||
|
|
||||||
|
exit 0
|
||||||
|
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=sh
|
||||||
44
config/hooks/live/0040_ssh_config_setup.chroot
Normal file
44
config/hooks/live/0040_ssh_config_setup.chroot
Normal file
@@ -0,0 +1,44 @@
|
|||||||
|
#!/bin/bash
|
||||||
|
# SPDX-Version: 3.0
|
||||||
|
# SPDX-CreationInfo: 2025-10-11; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
|
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
||||||
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
|
# SPDX-FileType: SOURCE
|
||||||
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
|
# SPDX-PackageName: CISS.debian.live.builder
|
||||||
|
# SPDX-Security-Contact: security@coresecret.eu
|
||||||
|
set -Ceuo pipefail
|
||||||
|
|
||||||
|
printf "\e[95m++++ ++++ ++++ ++++ ++++ ++++ ++ 🧪 '%s' starting ... \e[0m\n" "${0}"
|
||||||
|
|
||||||
|
cat << EOF >> /etc/ssh/ssh_config.d/10-sshfp.conf
|
||||||
|
# SPDX-Version: 3.0
|
||||||
|
# SPDX-CreationInfo: 2025-10-11; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
|
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
||||||
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
|
# SPDX-FileType: SOURCE
|
||||||
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
|
# SPDX-PackageName: CISS.debian.live.builder
|
||||||
|
# SPDX-Security-Contact: security@coresecret.eu
|
||||||
|
|
||||||
|
Host git.coresecret.dev
|
||||||
|
Port 42842
|
||||||
|
VerifyHostKeyDNS yes
|
||||||
|
StrictHostKeyChecking yes
|
||||||
|
GlobalKnownHostsFile /etc/ssh/ssh_known_hosts
|
||||||
|
UserKnownHostsFile /dev/null
|
||||||
|
HostKeyAlgorithms ssh-ed25519-cert-v01@openssh.com,ssh-ed25519,rsa-sha2-512-cert-v01@openssh.com,rsa-sha2-512,rsa-sha2-256-cert-v01@openssh.com,rsa-sha2-256
|
||||||
|
CanonicalizeHostname no
|
||||||
|
UpdateHostKeys no
|
||||||
|
|
||||||
|
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=conf
|
||||||
|
EOF
|
||||||
|
|
||||||
|
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ '%s' applied successfully. \e[0m\n" "${0}"
|
||||||
|
|
||||||
|
exit 0
|
||||||
|
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=sh
|
||||||
@@ -1,32 +1,32 @@
|
|||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
# SPDX-Version: 3.0
|
# SPDX-Version: 3.0
|
||||||
# SPDX-CreationInfo: 2025-05-05; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-CreationInfo: 2025-10-11; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
||||||
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
# SPDX-FileCopyrightText: 2024–2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-FileType: SOURCE
|
# SPDX-FileType: SOURCE
|
||||||
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
# SPDX-LicenseComment: This file is part of the CISS.hardened.installer framework.
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
# SPDX-PackageName: CISS.debian.live.builder
|
# SPDX-PackageName: CISS.debian.live.builder
|
||||||
# SPDX-Security-Contact: security@coresecret.eu
|
# SPDX-Security-Contact: security@coresecret.eu
|
||||||
set -C -e -u -o pipefail
|
set -Ceuo pipefail
|
||||||
|
|
||||||
printf "\e[95m++++ ++++ ++++ ++++ ++++ ++++ ++ 🧪 '%s' starting ... \e[0m\n" "${0}"
|
printf "\e[95m++++ ++++ ++++ ++++ ++++ ++++ ++ 🧪 '%s' starting ... \e[0m\n" "${0}"
|
||||||
# sleep 1
|
|
||||||
|
|
||||||
if [[ ! -f /root/.pwd ]]; then
|
if [[ ! -f /root/.pwd ]]; then
|
||||||
|
|
||||||
printf "\e[93m++++ ++++ ++++ ++++ ++++ ++++ ++ ❌ /root/.pwd NOT found. \e[0m\n"
|
printf "\e[93m++++ ++++ ++++ ++++ ++++ ++++ ++ ❌ /root/.pwd NOT found. \e[0m\n"
|
||||||
# sleep 1
|
|
||||||
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ❌ Exiting Hook ... \e[0m\n"
|
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ❌ Exiting Hook ... \e[0m\n"
|
||||||
# sleep 1
|
|
||||||
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ '%s' done. Nothing changed. \e[0m\n" "${0}"
|
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ '%s' done. Nothing changed. \e[0m\n" "${0}"
|
||||||
exit 0
|
exit 0
|
||||||
|
|
||||||
fi
|
fi
|
||||||
|
|
||||||
cd /root
|
cd /root
|
||||||
|
|
||||||
|
# shellcheck disable=SC2312
|
||||||
cp /etc/shadow /root/.ciss/dlb/backup/shadow.bak."$(date +%F_%T)"
|
cp /etc/shadow /root/.ciss/dlb/backup/shadow.bak."$(date +%F_%T)"
|
||||||
chmod 600 /root/.ciss/dlb/backup/shadow.bak.*
|
chmod 0600 /root/.ciss/dlb/backup/shadow.bak.*
|
||||||
|
|
||||||
declare hashed_pwd
|
declare hashed_pwd
|
||||||
declare safe_hashed_pwd
|
declare safe_hashed_pwd
|
||||||
@@ -38,16 +38,18 @@ sed -i "s|^user:[^:]*:\(.*\)|user:${safe_hashed_pwd}:\1|" /etc/shadow
|
|||||||
unset hashed_pwd safe_hashed_pwd
|
unset hashed_pwd safe_hashed_pwd
|
||||||
|
|
||||||
cat /etc/shadow
|
cat /etc/shadow
|
||||||
# sleep 1
|
|
||||||
|
|
||||||
if shred -vfzu -n 5 /root/.pwd; then
|
if shred -vfzu -n 5 /root/.pwd; then
|
||||||
|
|
||||||
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ Password file /root/.pwd: -vfzu -n 5 >> done. \e[0m\n"
|
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ Password file /root/.pwd: -vfzu -n 5 >> done. \e[0m\n"
|
||||||
|
|
||||||
else
|
else
|
||||||
|
|
||||||
printf "\e[91m++++ ++++ ++++ ++++ ++++ ++++ ++ ❌ Password file /root/.pwd: -vfzu -n 5 >> NOT successful. \e[0m\n" >&2
|
printf "\e[91m++++ ++++ ++++ ++++ ++++ ++++ ++ ❌ Password file /root/.pwd: -vfzu -n 5 >> NOT successful. \e[0m\n" >&2
|
||||||
|
|
||||||
fi
|
fi
|
||||||
|
|
||||||
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ '%s' applied successfully. \e[0m\n" "${0}"
|
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ '%s' applied successfully. \e[0m\n" "${0}"
|
||||||
# sleep 1
|
|
||||||
|
|
||||||
exit 0
|
exit 0
|
||||||
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=sh
|
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=sh
|
||||||
|
|||||||
@@ -1,18 +1,17 @@
|
|||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
# SPDX-Version: 3.0
|
# SPDX-Version: 3.0
|
||||||
# SPDX-CreationInfo: 2025-05-05; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-CreationInfo: 2025-10-11; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
||||||
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
# SPDX-FileCopyrightText: 2024–2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-FileType: SOURCE
|
# SPDX-FileType: SOURCE
|
||||||
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
# SPDX-PackageName: CISS.debian.live.builder
|
# SPDX-PackageName: CISS.debian.live.builder
|
||||||
# SPDX-Security-Contact: security@coresecret.eu
|
# SPDX-Security-Contact: security@coresecret.eu
|
||||||
set -C -e -u -o pipefail
|
set -Ceuo pipefail
|
||||||
|
|
||||||
printf "\e[95m++++ ++++ ++++ ++++ ++++ ++++ ++ 🧪 '%s' starting ... \e[0m\n" "${0}"
|
printf "\e[95m++++ ++++ ++++ ++++ ++++ ++++ ++ 🧪 '%s' starting ... \e[0m\n" "${0}"
|
||||||
# sleep 1
|
|
||||||
|
|
||||||
cat << 'EOF' >| /etc/default/keyboard
|
cat << 'EOF' >| /etc/default/keyboard
|
||||||
XKBMODEL="pc105"
|
XKBMODEL="pc105"
|
||||||
@@ -25,7 +24,6 @@ EOF
|
|||||||
dpkg-reconfigure -f noninteractive keyboard-configuration
|
dpkg-reconfigure -f noninteractive keyboard-configuration
|
||||||
|
|
||||||
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ '%s' applied successfully. \e[0m\n" "${0}"
|
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ '%s' applied successfully. \e[0m\n" "${0}"
|
||||||
# sleep 1
|
|
||||||
|
|
||||||
exit 0
|
exit 0
|
||||||
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=sh
|
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=sh
|
||||||
|
|||||||
@@ -1,21 +1,20 @@
|
|||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
# SPDX-Version: 3.0
|
# SPDX-Version: 3.0
|
||||||
# SPDX-CreationInfo: 2025-05-05; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-CreationInfo: 2025-10-11; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
||||||
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
# SPDX-FileCopyrightText: 2024–2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-FileType: SOURCE
|
# SPDX-FileType: SOURCE
|
||||||
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
# SPDX-PackageName: CISS.debian.live.builder
|
# SPDX-PackageName: CISS.debian.live.builder
|
||||||
# SPDX-Security-Contact: security@coresecret.eu
|
# SPDX-Security-Contact: security@coresecret.eu
|
||||||
set -C -e -u -o pipefail
|
set -Ceuo pipefail
|
||||||
|
|
||||||
printf "\e[95m++++ ++++ ++++ ++++ ++++ ++++ ++ 🧪 '%s' starting ... \e[0m\n" "${0}"
|
printf "\e[95m++++ ++++ ++++ ++++ ++++ ++++ ++ 🧪 '%s' starting ... \e[0m\n" "${0}"
|
||||||
# sleep 1
|
|
||||||
|
|
||||||
apt-get update -y
|
export DEBIAN_FRONTEND="noninteractive"
|
||||||
apt-get install --no-install-recommends haveged -y
|
apt-get install -y --no-install-recommends haveged
|
||||||
|
|
||||||
cd /root
|
cd /root
|
||||||
cat << 'EOF' >| /etc/default/haveged
|
cat << 'EOF' >| /etc/default/haveged
|
||||||
@@ -25,18 +24,8 @@ cat << 'EOF' >| /etc/default/haveged
|
|||||||
DAEMON_ARGS="-w 2048 -v 1"
|
DAEMON_ARGS="-w 2048 -v 1"
|
||||||
EOF
|
EOF
|
||||||
|
|
||||||
#mkdir -p /etc/systemd/system/haveged.service.d
|
|
||||||
#cat << 'EOF' >| /etc/systemd/system/haveged.service.d/override.conf
|
|
||||||
#[Service]
|
|
||||||
#NoNewPrivileges=yes
|
|
||||||
#ReadWritePaths=/dev/random /dev/urandom
|
|
||||||
#AmbientCapabilities=
|
|
||||||
#User=haveged
|
|
||||||
#Group=nogroup
|
|
||||||
#EOF
|
|
||||||
|
|
||||||
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ '%s' applied successfully. \e[0m\n" "${0}"
|
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ '%s' applied successfully. \e[0m\n" "${0}"
|
||||||
# sleep 1
|
|
||||||
|
|
||||||
exit 0
|
exit 0
|
||||||
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=sh
|
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=sh
|
||||||
|
|||||||
@@ -1,15 +1,15 @@
|
|||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
# SPDX-Version: 3.0
|
# SPDX-Version: 3.0
|
||||||
# SPDX-CreationInfo: 2025-05-05; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-CreationInfo: 2025-10-11; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
||||||
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
# SPDX-FileCopyrightText: 2024–2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-FileType: SOURCE
|
# SPDX-FileType: SOURCE
|
||||||
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
# SPDX-PackageName: CISS.debian.live.builder
|
# SPDX-PackageName: CISS.debian.live.builder
|
||||||
# SPDX-Security-Contact: security@coresecret.eu
|
# SPDX-Security-Contact: security@coresecret.eu
|
||||||
set -C -e -u -o pipefail
|
set -Ceuo pipefail
|
||||||
|
|
||||||
printf "\e[95m++++ ++++ ++++ ++++ ++++ ++++ ++ 🧪 '%s' starting ... \e[0m\n" "${0}"
|
printf "\e[95m++++ ++++ ++++ ++++ ++++ ++++ ++ 🧪 '%s' starting ... \e[0m\n" "${0}"
|
||||||
# sleep 1
|
# sleep 1
|
||||||
|
|||||||
@@ -1,15 +1,15 @@
|
|||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
# SPDX-Version: 3.0
|
# SPDX-Version: 3.0
|
||||||
# SPDX-CreationInfo: 2025-05-05; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-CreationInfo: 2025-10-11; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
||||||
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
# SPDX-FileCopyrightText: 2024–2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-FileType: SOURCE
|
# SPDX-FileType: SOURCE
|
||||||
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
# SPDX-PackageName: CISS.debian.live.builder
|
# SPDX-PackageName: CISS.debian.live.builder
|
||||||
# SPDX-Security-Contact: security@coresecret.eu
|
# SPDX-Security-Contact: security@coresecret.eu
|
||||||
set -C -e -u -o pipefail
|
set -Ceuo pipefail
|
||||||
|
|
||||||
printf "\e[95m++++ ++++ ++++ ++++ ++++ ++++ ++ 🧪 '%s' starting ... \e[0m\n" "${0}"
|
printf "\e[95m++++ ++++ ++++ ++++ ++++ ++++ ++ 🧪 '%s' starting ... \e[0m\n" "${0}"
|
||||||
# sleep 1
|
# sleep 1
|
||||||
|
|||||||
@@ -1,18 +1,17 @@
|
|||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
# SPDX-Version: 3.0
|
# SPDX-Version: 3.0
|
||||||
# SPDX-CreationInfo: 2025-05-05; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-CreationInfo: 2025-10-11; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
||||||
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
# SPDX-FileCopyrightText: 2024–2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-FileType: SOURCE
|
# SPDX-FileType: SOURCE
|
||||||
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
# SPDX-PackageName: CISS.debian.live.builder
|
# SPDX-PackageName: CISS.debian.live.builder
|
||||||
# SPDX-Security-Contact: security@coresecret.eu
|
# SPDX-Security-Contact: security@coresecret.eu
|
||||||
set -C -e -u -o pipefail
|
set -Ceuo pipefail
|
||||||
|
|
||||||
printf "\e[95m++++ ++++ ++++ ++++ ++++ ++++ ++ 🧪 '%s' starting ... \e[0m\n" "${0}"
|
printf "\e[95m++++ ++++ ++++ ++++ ++++ ++++ ++ 🧪 '%s' starting ... \e[0m\n" "${0}"
|
||||||
# sleep 1
|
|
||||||
|
|
||||||
cd /root
|
cd /root
|
||||||
|
|
||||||
@@ -24,7 +23,8 @@ wget -qO- https://raw.githubusercontent.com/eza-community/eza/main/deb.asc | gpg
|
|||||||
echo "deb [signed-by=/etc/apt/keyrings/gierens.gpg] http://deb.gierens.de stable main" | tee /etc/apt/sources.list.d/gierens.list
|
echo "deb [signed-by=/etc/apt/keyrings/gierens.gpg] http://deb.gierens.de stable main" | tee /etc/apt/sources.list.d/gierens.list
|
||||||
chmod 644 /etc/apt/keyrings/gierens.gpg /etc/apt/sources.list.d/gierens.list
|
chmod 644 /etc/apt/keyrings/gierens.gpg /etc/apt/sources.list.d/gierens.list
|
||||||
|
|
||||||
apt-get update -y
|
export DEBIAN_FRONTEND="noninteractive"
|
||||||
|
apt-get update
|
||||||
apt-get install -y eza
|
apt-get install -y eza
|
||||||
|
|
||||||
git clone https://github.com/eza-community/eza-themes.git
|
git clone https://github.com/eza-community/eza-themes.git
|
||||||
@@ -133,14 +133,6 @@ symlink_path: {foreground: Cyan}
|
|||||||
control_char: {foreground: Red}
|
control_char: {foreground: Red}
|
||||||
broken_symlink: {foreground: Red}
|
broken_symlink: {foreground: Red}
|
||||||
broken_path_overlay: {foreground: Default, is_underlined: true}
|
broken_path_overlay: {foreground: Default, is_underlined: true}
|
||||||
|
|
||||||
filenames:
|
|
||||||
# Custom filename-based overrides
|
|
||||||
# Cargo.toml: {icon: {glyph: 🦀}}
|
|
||||||
|
|
||||||
extensions:
|
|
||||||
# Custom extension-based overrides
|
|
||||||
# rs: {filename: {foreground: Red}, icon: {glyph: 🦀}}
|
|
||||||
EOF
|
EOF
|
||||||
|
|
||||||
chmod 0644 "/root/eza-themes/themes/centurion.yml"
|
chmod 0644 "/root/eza-themes/themes/centurion.yml"
|
||||||
@@ -153,10 +145,7 @@ unzip /tmp/nerd/Hack.zip -d /root/.local/share/fonts
|
|||||||
fc-cache -fv
|
fc-cache -fv
|
||||||
rm -rf /tmp/nerd
|
rm -rf /tmp/nerd
|
||||||
|
|
||||||
unset repo latest_release download_url
|
|
||||||
|
|
||||||
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ '%s' applied successfully. \e[0m\n" "${0}"
|
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ '%s' applied successfully. \e[0m\n" "${0}"
|
||||||
# sleep 1
|
|
||||||
|
|
||||||
exit 0
|
exit 0
|
||||||
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=sh
|
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=sh
|
||||||
|
|||||||
@@ -1,28 +1,27 @@
|
|||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
# SPDX-Version: 3.0
|
# SPDX-Version: 3.0
|
||||||
# SPDX-CreationInfo: 2025-05-05; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-CreationInfo: 2025-10-11; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
||||||
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
# SPDX-FileCopyrightText: 2024–2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-FileType: SOURCE
|
# SPDX-FileType: SOURCE
|
||||||
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
# SPDX-PackageName: CISS.debian.live.builder
|
# SPDX-PackageName: CISS.debian.live.builder
|
||||||
# SPDX-Security-Contact: security@coresecret.eu
|
# SPDX-Security-Contact: security@coresecret.eu
|
||||||
set -C -e -u -o pipefail
|
set -Ceuo pipefail
|
||||||
|
|
||||||
printf "\e[95m++++ ++++ ++++ ++++ ++++ ++++ ++ 🧪 '%s' starting ... \e[0m\n" "${0}"
|
printf "\e[95m++++ ++++ ++++ ++++ ++++ ++++ ++ 🧪 '%s' starting ... \e[0m\n" "${0}"
|
||||||
# sleep 1
|
|
||||||
|
|
||||||
curl -fsSL https://packages.cisofy.com/keys/cisofy-software-public.key | gpg --dearmor -o /etc/apt/trusted.gpg.d/cisofy-software-public.gpg
|
curl -fsSL https://packages.cisofy.com/keys/cisofy-software-public.key | gpg --dearmor -o /etc/apt/trusted.gpg.d/cisofy-software-public.gpg
|
||||||
echo "deb [arch=amd64,arm64 signed-by=/etc/apt/trusted.gpg.d/cisofy-software-public.gpg] https://packages.cisofy.com/community/lynis/deb/ stable main" | tee /etc/apt/sources.list.d/cisofy-lynis.list
|
echo "deb [arch=amd64,arm64 signed-by=/etc/apt/trusted.gpg.d/cisofy-software-public.gpg] https://packages.cisofy.com/community/lynis/deb/ stable main" | tee /etc/apt/sources.list.d/cisofy-lynis.list
|
||||||
|
|
||||||
apt-get update -y
|
export DEBIAN_FRONTEND="noninteractive"
|
||||||
|
apt-get update
|
||||||
apt-get install -y lynis
|
apt-get install -y lynis
|
||||||
lynis show version
|
lynis show version
|
||||||
|
|
||||||
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ '%s' applied successfully. \e[0m\n" "${0}"
|
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ '%s' applied successfully. \e[0m\n" "${0}"
|
||||||
# sleep 1
|
|
||||||
|
|
||||||
exit 0
|
exit 0
|
||||||
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=sh
|
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=sh
|
||||||
|
|||||||
@@ -1,28 +1,42 @@
|
|||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
# SPDX-Version: 3.0
|
# SPDX-Version: 3.0
|
||||||
# SPDX-CreationInfo: 2025-05-05; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-CreationInfo: 2025-10-11; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
||||||
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
# SPDX-FileCopyrightText: 2024–2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-FileType: SOURCE
|
# SPDX-FileType: SOURCE
|
||||||
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
# SPDX-PackageName: CISS.debian.live.builder
|
# SPDX-PackageName: CISS.debian.live.builder
|
||||||
# SPDX-Security-Contact: security@coresecret.eu
|
# SPDX-Security-Contact: security@coresecret.eu
|
||||||
set -C -e -u -o pipefail
|
set -Ceuo pipefail
|
||||||
|
|
||||||
printf "\e[95m++++ ++++ ++++ ++++ ++++ ++++ ++ 🧪 '%s' starting ... \e[0m\n" "${0}"
|
printf "\e[95m++++ ++++ ++++ ++++ ++++ ++++ ++ 🧪 '%s' starting ... \e[0m\n" "${0}"
|
||||||
# sleep 1
|
|
||||||
|
|
||||||
mkdir -p /var/log/chrony
|
mkdir -p /var/log/chrony
|
||||||
# See https://coresecret.eu/tutorials/debian-package-glossary/ for a brief description of the installed packages.
|
|
||||||
apt-get install chrony -y
|
export DEBIAN_FRONTEND="noninteractive"
|
||||||
|
export TZ="Etc/UTC"
|
||||||
|
|
||||||
|
apt-get install -y adjtimex chrony tzdata
|
||||||
|
|
||||||
systemctl enable chrony.service
|
systemctl enable chrony.service
|
||||||
|
|
||||||
mv /etc/chrony/chrony.conf /root/.ciss/dlb/backup/chrony.conf.bak
|
mv /etc/chrony/chrony.conf /root/.ciss/dlb/backup/chrony.conf.bak
|
||||||
chmod 644 /root/.ciss/dlb/backup/chrony.conf.bak
|
chmod 0644 /root/.ciss/dlb/backup/chrony.conf.bak
|
||||||
|
|
||||||
|
cat << EOF >| /etc/chrony/chrony.conf
|
||||||
|
# SPDX-Version: 3.0
|
||||||
|
# SPDX-CreationInfo: 2025-10-11; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
|
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
||||||
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
|
# SPDX-FileType: SOURCE
|
||||||
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
|
# SPDX-PackageName: CISS.debian.live.builder
|
||||||
|
# SPDX-Security-Contact: security@coresecret.eu
|
||||||
|
|
||||||
cat << 'EOF' >| /etc/chrony/chrony.conf
|
|
||||||
# Include configuration files found in /etc/chrony/conf.d.
|
# Include configuration files found in /etc/chrony/conf.d.
|
||||||
confdir /etc/chrony/conf.d
|
confdir /etc/chrony/conf.d
|
||||||
driftfile /var/lib/chrony/chrony.drift
|
driftfile /var/lib/chrony/chrony.drift
|
||||||
@@ -36,17 +50,14 @@ log tracking measurements statistics
|
|||||||
|
|
||||||
authselectmode require
|
authselectmode require
|
||||||
|
|
||||||
server ptbtime1.ptb.de iburst nts minpoll 5 maxpoll 9
|
server ntp.ripe.net iburst nts minpoll 5 maxpoll 9
|
||||||
server ptbtime2.ptb.de iburst nts minpoll 5 maxpoll 9
|
server ptbtime3.ptb.de iburst nts minpoll 5 maxpoll 9
|
||||||
server ptbtime3.ptb.de iburst nts minpoll 5 maxpoll 9
|
server ptbtime2.ptb.de iburst nts minpoll 5 maxpoll 9
|
||||||
server ptbtime4.ptb.de iburst nts noselect minpoll 5 maxpoll 9
|
server ptbtime1.ptb.de iburst nts minpoll 5 maxpoll 9
|
||||||
# server nts.netnod.se iburst nts minpoll 5 maxpoll 9
|
server ntp13.metas.ch iburst nts minpoll 5 maxpoll 9
|
||||||
|
server time-c-b.nist.gov iburst nts minpoll 5 maxpoll 9
|
||||||
# server ntp.ripe.net iburst nts minpoll 5 maxpoll 9
|
server sth1.ntp.se iburst nts minpoll 5 maxpoll 9
|
||||||
# server ntp12.metas.ch iburst nts minpoll 5 maxpoll 9
|
server ntp0.fau.de iburst nts minpoll 5 maxpoll 9
|
||||||
# server ntp2.tecnico.ulisboa.pt iburst nts minpoll 5 maxpoll 9
|
|
||||||
# server time-c-b.nist.gov iburst nts minpoll 5 maxpoll 9
|
|
||||||
server ntp0.fau.de iburst nts minpoll 5 maxpoll 9
|
|
||||||
|
|
||||||
leapsectz right/UTC
|
leapsectz right/UTC
|
||||||
|
|
||||||
@@ -56,13 +67,50 @@ maxupdateskew 100.0
|
|||||||
|
|
||||||
rtcsync
|
rtcsync
|
||||||
|
|
||||||
makestep 1 3
|
makestep 0.25 3
|
||||||
|
|
||||||
|
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=conf
|
||||||
EOF
|
EOF
|
||||||
|
|
||||||
chmod 644 /etc/chrony/chrony.conf
|
chmod 0644 /etc/chrony/chrony.conf
|
||||||
|
|
||||||
|
[[ -f /root/.ciss/check_chrony.sh ]] && chmod 0700 /root/.ciss/check_chrony.sh
|
||||||
|
|
||||||
|
### Build right/UTC from tzdata leap table if missing.
|
||||||
|
if [[ ! -e /usr/share/zoneinfo/right/UTC ]]; then
|
||||||
|
|
||||||
|
install -d -m 0755 /usr/share/zoneinfo/right
|
||||||
|
|
||||||
|
### Minimal zic source for a fixed UTC zone.
|
||||||
|
declare -r tmp_src="/tmp/UTC.src"
|
||||||
|
printf 'Zone UTC 0 - UTC\n' > "${tmp_src}"
|
||||||
|
|
||||||
|
### Prefer the zic-format leapseconds file.
|
||||||
|
declare leap_zic="/usr/share/zoneinfo/leapseconds"
|
||||||
|
|
||||||
|
if [[ -s "${leap_zic}" ]]; then
|
||||||
|
|
||||||
|
zic -d /usr/share/zoneinfo/right -L "${leap_zic}" "${tmp_src}"
|
||||||
|
|
||||||
|
else
|
||||||
|
|
||||||
|
echo "WARNING: ${leap_zic} not found; building right/UTC without leap info." >&2
|
||||||
|
zic -d /usr/share/zoneinfo/right -L /dev/null "${tmp_src}"
|
||||||
|
|
||||||
|
fi
|
||||||
|
|
||||||
|
rm -f "${tmp_src}"
|
||||||
|
|
||||||
|
fi
|
||||||
|
|
||||||
|
if [[ -e /usr/share/zoneinfo/right/UTC ]]; then
|
||||||
|
|
||||||
|
### Expect to see 'Sat Dec 31 23:59:60 UTC 2016' rendered in right/UTC
|
||||||
|
TZ=right/UTC date -ud '2017-01-01 00:00:00 -1 second' || true
|
||||||
|
|
||||||
|
fi
|
||||||
|
|
||||||
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ '%s' applied successfully. \e[0m\n" "${0}"
|
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ '%s' applied successfully. \e[0m\n" "${0}"
|
||||||
# sleep 1
|
|
||||||
|
|
||||||
exit 0
|
exit 0
|
||||||
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=sh
|
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=sh
|
||||||
|
|||||||
@@ -1,24 +1,22 @@
|
|||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
# SPDX-Version: 3.0
|
# SPDX-Version: 3.0
|
||||||
# SPDX-CreationInfo: 2025-05-05; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-CreationInfo: 2025-10-11; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
||||||
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
# SPDX-FileCopyrightText: 2024–2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-FileType: SOURCE
|
# SPDX-FileType: SOURCE
|
||||||
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
# SPDX-PackageName: CISS.debian.live.builder
|
# SPDX-PackageName: CISS.debian.live.builder
|
||||||
# SPDX-Security-Contact: security@coresecret.eu
|
# SPDX-Security-Contact: security@coresecret.eu
|
||||||
set -C -e -u -o pipefail
|
set -Ceuo pipefail
|
||||||
|
|
||||||
printf "\e[95m++++ ++++ ++++ ++++ ++++ ++++ ++ 🧪 '%s' starting ... \e[0m\n" "${0}"
|
printf "\e[95m++++ ++++ ++++ ++++ ++++ ++++ ++ 🧪 '%s' starting ... \e[0m\n" "${0}"
|
||||||
# sleep 1
|
|
||||||
|
|
||||||
cd /root/git
|
cd /root/git
|
||||||
git clone https://github.com/a13xp0p0v/kernel-hardening-checker.git
|
git clone https://github.com/a13xp0p0v/kernel-hardening-checker.git
|
||||||
|
|
||||||
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ '%s' applied successfully. \e[0m\n" "${0}"
|
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ '%s' applied successfully. \e[0m\n" "${0}"
|
||||||
# sleep 1
|
|
||||||
|
|
||||||
exit 0
|
exit 0
|
||||||
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=sh
|
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=sh
|
||||||
|
|||||||
@@ -1,18 +1,17 @@
|
|||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
# SPDX-Version: 3.0
|
# SPDX-Version: 3.0
|
||||||
# SPDX-CreationInfo: 2025-05-05; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-CreationInfo: 2025-10-11; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
||||||
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
# SPDX-FileCopyrightText: 2024–2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-FileType: SOURCE
|
# SPDX-FileType: SOURCE
|
||||||
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
# SPDX-PackageName: CISS.debian.live.builder
|
# SPDX-PackageName: CISS.debian.live.builder
|
||||||
# SPDX-Security-Contact: security@coresecret.eu
|
# SPDX-Security-Contact: security@coresecret.eu
|
||||||
set -C -e -u -o pipefail
|
set -Ceuo pipefail
|
||||||
|
|
||||||
printf "\e[95m++++ ++++ ++++ ++++ ++++ ++++ ++ 🧪 '%s' starting ... \e[0m\n" "${0}"
|
printf "\e[95m++++ ++++ ++++ ++++ ++++ ++++ ++ 🧪 '%s' starting ... \e[0m\n" "${0}"
|
||||||
# sleep 1
|
|
||||||
|
|
||||||
cd /root
|
cd /root
|
||||||
declare target_script="/etc/cron.d/restart-ssh"
|
declare target_script="/etc/cron.d/restart-ssh"
|
||||||
@@ -21,15 +20,15 @@ cat << 'EOF' >| "${target_script}"
|
|||||||
@reboot root /usr/local/bin/restart-ssh.sh
|
@reboot root /usr/local/bin/restart-ssh.sh
|
||||||
EOF
|
EOF
|
||||||
|
|
||||||
chmod 644 "${target_script}"
|
chmod 0644 "${target_script}"
|
||||||
|
|
||||||
cat << 'EOF' >| /usr/local/bin/restart-ssh.sh
|
cat << 'EOF' >| /usr/local/bin/restart-ssh.sh
|
||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
# SPDX-Version: 3.0
|
# SPDX-Version: 3.0
|
||||||
# SPDX-CreationInfo: 2025-05-05; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-CreationInfo: 2025-10-11; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
||||||
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
# SPDX-FileCopyrightText: 2024–2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-FileType: SOURCE
|
# SPDX-FileType: SOURCE
|
||||||
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
@@ -43,10 +42,8 @@ systemctl start ssh
|
|||||||
EOF
|
EOF
|
||||||
|
|
||||||
chmod +x /usr/local/bin/restart-ssh.sh
|
chmod +x /usr/local/bin/restart-ssh.sh
|
||||||
unset target_script
|
|
||||||
|
|
||||||
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ '%s' applied successfully. \e[0m\n" "${0}"
|
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ '%s' applied successfully. \e[0m\n" "${0}"
|
||||||
# sleep 1
|
|
||||||
|
|
||||||
exit 0
|
exit 0
|
||||||
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=sh
|
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=sh
|
||||||
|
|||||||
@@ -1,24 +1,22 @@
|
|||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
# SPDX-Version: 3.0
|
# SPDX-Version: 3.0
|
||||||
# SPDX-CreationInfo: 2025-05-05; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-CreationInfo: 2025-10-11; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
||||||
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
# SPDX-FileCopyrightText: 2024–2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-FileType: SOURCE
|
# SPDX-FileType: SOURCE
|
||||||
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
# SPDX-PackageName: CISS.debian.live.builder
|
# SPDX-PackageName: CISS.debian.live.builder
|
||||||
# SPDX-Security-Contact: security@coresecret.eu
|
# SPDX-Security-Contact: security@coresecret.eu
|
||||||
set -C -e -u -o pipefail
|
set -Ceuo pipefail
|
||||||
|
|
||||||
printf "\e[95m++++ ++++ ++++ ++++ ++++ ++++ ++ 🧪 '%s' starting ... \e[0m\n" "${0}"
|
printf "\e[95m++++ ++++ ++++ ++++ ++++ ++++ ++ 🧪 '%s' starting ... \e[0m\n" "${0}"
|
||||||
# sleep 1
|
|
||||||
|
|
||||||
cd /root/git
|
cd /root/git
|
||||||
git clone --depth 1 -b master https://github.com/major/MySQLTuner-perl.git
|
git clone --depth 1 -b master https://github.com/major/MySQLTuner-perl.git
|
||||||
|
|
||||||
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ '%s' applied successfully. \e[0m\n" "${0}"
|
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ '%s' applied successfully. \e[0m\n" "${0}"
|
||||||
# sleep 1
|
|
||||||
|
|
||||||
exit 0
|
exit 0
|
||||||
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=sh
|
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=sh
|
||||||
|
|||||||
@@ -1,24 +1,22 @@
|
|||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
# SPDX-Version: 3.0
|
# SPDX-Version: 3.0
|
||||||
# SPDX-CreationInfo: 2025-05-05; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-CreationInfo: 2025-10-11; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
||||||
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
# SPDX-FileCopyrightText: 2024–2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-FileType: SOURCE
|
# SPDX-FileType: SOURCE
|
||||||
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
# SPDX-PackageName: CISS.debian.live.builder
|
# SPDX-PackageName: CISS.debian.live.builder
|
||||||
# SPDX-Security-Contact: security@coresecret.eu
|
# SPDX-Security-Contact: security@coresecret.eu
|
||||||
set -C -e -u -o pipefail
|
set -Ceuo pipefail
|
||||||
|
|
||||||
printf "\e[95m++++ ++++ ++++ ++++ ++++ ++++ ++ 🧪 '%s' starting ... \e[0m\n" "${0}"
|
printf "\e[95m++++ ++++ ++++ ++++ ++++ ++++ ++ 🧪 '%s' starting ... \e[0m\n" "${0}"
|
||||||
# sleep 1
|
|
||||||
|
|
||||||
wget https://github.com/mikefarah/yq/releases/latest/download/yq_linux_amd64 -O /usr/bin/yq
|
wget https://github.com/mikefarah/yq/releases/latest/download/yq_linux_amd64 -O /usr/bin/yq
|
||||||
chmod +x /usr/bin/yq
|
chmod +x /usr/bin/yq
|
||||||
|
|
||||||
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ '%s' applied successfully. \e[0m\n" "${0}"
|
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ '%s' applied successfully. \e[0m\n" "${0}"
|
||||||
# sleep 1
|
|
||||||
|
|
||||||
exit 0
|
exit 0
|
||||||
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=sh
|
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=sh
|
||||||
|
|||||||
@@ -1,24 +1,22 @@
|
|||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
# SPDX-Version: 3.0
|
# SPDX-Version: 3.0
|
||||||
# SPDX-CreationInfo: 2025-05-05; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-CreationInfo: 2025-10-11; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
||||||
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
# SPDX-FileCopyrightText: 2024–2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-FileType: SOURCE
|
# SPDX-FileType: SOURCE
|
||||||
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
# SPDX-PackageName: CISS.debian.live.builder
|
# SPDX-PackageName: CISS.debian.live.builder
|
||||||
# SPDX-Security-Contact: security@coresecret.eu
|
# SPDX-Security-Contact: security@coresecret.eu
|
||||||
set -C -e -u -o pipefail
|
set -Ceuo pipefail
|
||||||
|
|
||||||
printf "\e[95m++++ ++++ ++++ ++++ ++++ ++++ ++ 🧪 '%s' starting ... \e[0m\n" "${0}"
|
printf "\e[95m++++ ++++ ++++ ++++ ++++ ++++ ++ 🧪 '%s' starting ... \e[0m\n" "${0}"
|
||||||
# sleep 1
|
|
||||||
|
|
||||||
cd /root/git
|
cd /root/git
|
||||||
git clone https://github.com/testssl/testssl.sh.git
|
git clone https://github.com/testssl/testssl.sh.git
|
||||||
|
|
||||||
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ '%s' applied successfully. \e[0m\n" "${0}"
|
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ '%s' applied successfully. \e[0m\n" "${0}"
|
||||||
# sleep 1
|
|
||||||
|
|
||||||
exit 0
|
exit 0
|
||||||
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=sh
|
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=sh
|
||||||
|
|||||||
@@ -1,20 +1,19 @@
|
|||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
# SPDX-Version: 3.0
|
# SPDX-Version: 3.0
|
||||||
# SPDX-CreationInfo: 2025-05-05; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-CreationInfo: 2025-10-11; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
||||||
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
# SPDX-FileCopyrightText: 2024–2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-FileType: SOURCE
|
# SPDX-FileType: SOURCE
|
||||||
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
# SPDX-PackageName: CISS.debian.live.builder
|
# SPDX-PackageName: CISS.debian.live.builder
|
||||||
# SPDX-Security-Contact: security@coresecret.eu
|
# SPDX-Security-Contact: security@coresecret.eu
|
||||||
set -C -e -u -o pipefail
|
set -Ceuo pipefail
|
||||||
|
|
||||||
printf "\e[95m++++ ++++ ++++ ++++ ++++ ++++ ++ 🧪 '%s' starting ... \e[0m\n" "${0}"
|
printf "\e[95m++++ ++++ ++++ ++++ ++++ ++++ ++ 🧪 '%s' starting ... \e[0m\n" "${0}"
|
||||||
# sleep 1
|
|
||||||
|
|
||||||
apt-get install -y curl
|
export DEBIAN_FRONTEND="noninteractive"
|
||||||
curl -fsSL https://deb.nodesource.com/setup_22.x | sudo -E bash - && \
|
curl -fsSL https://deb.nodesource.com/setup_22.x | sudo -E bash - && \
|
||||||
apt-get install -y nodejs
|
apt-get install -y nodejs
|
||||||
|
|
||||||
@@ -22,7 +21,6 @@ cd /root/git
|
|||||||
git clone https://github.com/sefinek/UFW-AbuseIPDB-Reporter.git
|
git clone https://github.com/sefinek/UFW-AbuseIPDB-Reporter.git
|
||||||
|
|
||||||
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ '%s' applied successfully. \e[0m\n" "${0}"
|
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ '%s' applied successfully. \e[0m\n" "${0}"
|
||||||
# sleep 1
|
|
||||||
|
|
||||||
exit 0
|
exit 0
|
||||||
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=sh
|
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=sh
|
||||||
|
|||||||
@@ -1,15 +1,15 @@
|
|||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
# SPDX-Version: 3.0
|
# SPDX-Version: 3.0
|
||||||
# SPDX-CreationInfo: 2025-05-05; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-CreationInfo: 2025-10-11; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
||||||
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
# SPDX-FileCopyrightText: 2024–2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-FileType: SOURCE
|
# SPDX-FileType: SOURCE
|
||||||
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
# SPDX-PackageName: CISS.debian.live.builder
|
# SPDX-PackageName: CISS.debian.live.builder
|
||||||
# SPDX-Security-Contact: security@coresecret.eu
|
# SPDX-Security-Contact: security@coresecret.eu
|
||||||
set -C -e -u -o pipefail
|
set -Ceuo pipefail
|
||||||
|
|
||||||
printf "\e[95m++++ ++++ ++++ ++++ ++++ ++++ ++ 🧪 '%s' starting ... \e[0m\n" "${0}"
|
printf "\e[95m++++ ++++ ++++ ++++ ++++ ++++ ++ 🧪 '%s' starting ... \e[0m\n" "${0}"
|
||||||
# sleep 1
|
# sleep 1
|
||||||
|
|||||||
@@ -1,15 +1,15 @@
|
|||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
# SPDX-Version: 3.0
|
# SPDX-Version: 3.0
|
||||||
# SPDX-CreationInfo: 2025-05-05; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-CreationInfo: 2025-10-11; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
||||||
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
# SPDX-FileCopyrightText: 2024–2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-FileType: SOURCE
|
# SPDX-FileType: SOURCE
|
||||||
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
# SPDX-LicenseComment: This file is part of the CISS.hardened.installer framework.
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
# SPDX-PackageName: CISS.debian.live.builder
|
# SPDX-PackageName: CISS.debian.live.builder
|
||||||
# SPDX-Security-Contact: security@coresecret.eu
|
# SPDX-Security-Contact: security@coresecret.eu
|
||||||
set -C -e -u -o pipefail
|
set -Ceuo pipefail
|
||||||
|
|
||||||
printf "\e[95m++++ ++++ ++++ ++++ ++++ ++++ ++ 🧪 '%s' starting ... \e[0m\n" "${0}"
|
printf "\e[95m++++ ++++ ++++ ++++ ++++ ++++ ++ 🧪 '%s' starting ... \e[0m\n" "${0}"
|
||||||
# sleep 1
|
# sleep 1
|
||||||
|
|||||||
@@ -1,25 +1,24 @@
|
|||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
# SPDX-Version: 3.0
|
# SPDX-Version: 3.0
|
||||||
# SPDX-CreationInfo: 2025-05-05; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-CreationInfo: 2025-10-11; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
||||||
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
# SPDX-FileCopyrightText: 2024–2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-FileType: SOURCE
|
# SPDX-FileType: SOURCE
|
||||||
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
# SPDX-PackageName: CISS.debian.live.builder
|
# SPDX-PackageName: CISS.debian.live.builder
|
||||||
# SPDX-Security-Contact: security@coresecret.eu
|
# SPDX-Security-Contact: security@coresecret.eu
|
||||||
set -C -e -u -o pipefail
|
set -Ceuo pipefail
|
||||||
|
|
||||||
printf "\e[95m++++ ++++ ++++ ++++ ++++ ++++ ++ 🧪 '%s' starting ... \e[0m\n" "${0}"
|
printf "\e[95m++++ ++++ ++++ ++++ ++++ ++++ ++ 🧪 '%s' starting ... \e[0m\n" "${0}"
|
||||||
# sleep 1
|
# sleep 1
|
||||||
|
|
||||||
# TODO: MUST be uncommented
|
|
||||||
cd /root/git
|
cd /root/git
|
||||||
# git clone https://git.coresecret.dev/msw/CISS.debian.installer.git
|
git clone https://github.com/dnsviz/dnsviz.git
|
||||||
|
|
||||||
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ '%s' applied successfully. \e[0m\n" "${0}"
|
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ '%s' applied successfully. \e[0m\n" "${0}"
|
||||||
# sleep 1
|
sleep 1
|
||||||
|
|
||||||
exit 0
|
exit 0
|
||||||
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=sh
|
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=sh
|
||||||
53
config/hooks/live/0860_sops.chroot
Normal file
53
config/hooks/live/0860_sops.chroot
Normal file
@@ -0,0 +1,53 @@
|
|||||||
|
#!/bin/bash
|
||||||
|
# SPDX-Version: 3.0
|
||||||
|
# SPDX-CreationInfo: 2025-10-11; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
|
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
||||||
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
|
# SPDX-FileType: SOURCE
|
||||||
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
|
# SPDX-PackageName: CISS.debian.live.builder
|
||||||
|
# SPDX-Security-Contact: security@coresecret.eu
|
||||||
|
set -Ceuo pipefail
|
||||||
|
|
||||||
|
printf "\e[95m++++ ++++ ++++ ++++ ++++ ++++ ++ 🧪 '%s' starting ... \e[0m\n" "${0}"
|
||||||
|
|
||||||
|
export DEBIAN_FRONTEND=noninteractive
|
||||||
|
|
||||||
|
SOPS_VER="v3.11.0"
|
||||||
|
ARCH="$(dpkg --print-architecture)"
|
||||||
|
case "${ARCH}" in
|
||||||
|
amd64) SOPS_FILE="sops-${SOPS_VER}.linux.amd64" ;;
|
||||||
|
arm64) SOPS_FILE="sops-${SOPS_VER}.linux.arm64" ;;
|
||||||
|
*) echo "Unsupported arch: ${ARCH}" >&2; exit 1 ;;
|
||||||
|
esac
|
||||||
|
|
||||||
|
cd /tmp
|
||||||
|
|
||||||
|
curl -fsSLO "https://github.com/getsops/sops/releases/download/${SOPS_VER}/${SOPS_FILE}"
|
||||||
|
curl -fsSLO "https://github.com/getsops/sops/releases/download/${SOPS_VER}/sops-${SOPS_VER}.checksums.txt"
|
||||||
|
curl -fsSLO "https://github.com/getsops/sops/releases/download/${SOPS_VER}/sops-${SOPS_VER}.checksums.pem"
|
||||||
|
curl -fsSLO "https://github.com/getsops/sops/releases/download/${SOPS_VER}/sops-${SOPS_VER}.checksums.sig"
|
||||||
|
|
||||||
|
cosign verify-blob "sops-${SOPS_VER}.checksums.txt" \
|
||||||
|
--certificate "sops-${SOPS_VER}.checksums.pem" \
|
||||||
|
--signature "sops-${SOPS_VER}.checksums.sig" \
|
||||||
|
--certificate-identity-regexp="https://github.com/getsops" \
|
||||||
|
--certificate-oidc-issuer="https://token.actions.githubusercontent.com"
|
||||||
|
|
||||||
|
sha256sum -c "sops-${SOPS_VER}.checksums.txt" --ignore-missing
|
||||||
|
|
||||||
|
install -m 0755 "${SOPS_FILE}" /usr/local/bin/sops
|
||||||
|
sops --version --check-for-updates
|
||||||
|
age --version
|
||||||
|
|
||||||
|
rm -f "/tmp/${SOPS_FILE}"
|
||||||
|
rm -f "/tmp/sops-${SOPS_VER}.checksums.txt"
|
||||||
|
rm -f "/tmp/sops-${SOPS_VER}.checksums.pem"
|
||||||
|
rm -f "/tmp/sops-${SOPS_VER}.checksums.sig"
|
||||||
|
|
||||||
|
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ '%s' applied successfully. \e[0m\n" "${0}"
|
||||||
|
|
||||||
|
exit 0
|
||||||
|
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=sh
|
||||||
@@ -1,15 +1,15 @@
|
|||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
# SPDX-Version: 3.0
|
# SPDX-Version: 3.0
|
||||||
# SPDX-CreationInfo: 2025-05-05; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-CreationInfo: 2025-10-11; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
||||||
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
# SPDX-FileCopyrightText: 2024–2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-FileType: SOURCE
|
# SPDX-FileType: SOURCE
|
||||||
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
# SPDX-PackageName: CISS.debian.live.builder
|
# SPDX-PackageName: CISS.debian.live.builder
|
||||||
# SPDX-Security-Contact: security@coresecret.eu
|
# SPDX-Security-Contact: security@coresecret.eu
|
||||||
set -C -e -u -o pipefail
|
set -Ceuo pipefail
|
||||||
|
|
||||||
printf "\e[95m++++ ++++ ++++ ++++ ++++ ++++ ++ 🧪 '%s' starting ... \e[0m\n" "${0}"
|
printf "\e[95m++++ ++++ ++++ ++++ ++++ ++++ ++ 🧪 '%s' starting ... \e[0m\n" "${0}"
|
||||||
# sleep 1
|
# sleep 1
|
||||||
|
|||||||
@@ -1,33 +1,38 @@
|
|||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
# SPDX-Version: 3.0
|
# SPDX-Version: 3.0
|
||||||
# SPDX-CreationInfo: 2025-05-05; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-CreationInfo: 2025-10-11; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
||||||
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
# SPDX-FileCopyrightText: 2024–2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-FileType: SOURCE
|
# SPDX-FileType: SOURCE
|
||||||
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
# SPDX-LicenseComment: This file is part of the CISS.hardened.installer framework.
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
# SPDX-PackageName: CISS.debian.live.builder
|
# SPDX-PackageName: CISS.debian.live.builder
|
||||||
# SPDX-Security-Contact: security@coresecret.eu
|
# SPDX-Security-Contact: security@coresecret.eu
|
||||||
set -C -e -u -o pipefail
|
set -Ceuo pipefail
|
||||||
|
|
||||||
printf "\e[95m++++ ++++ ++++ ++++ ++++ ++++ ++ 🧪 '%s' starting ... \e[0m\n" "${0}"
|
printf "\e[95m++++ ++++ ++++ ++++ ++++ ++++ ++ 🧪 '%s' starting ... \e[0m\n" "${0}"
|
||||||
# sleep 1
|
|
||||||
|
|
||||||
|
export DEBIAN_FRONTEND="noninteractive"
|
||||||
apt-get install -y acct
|
apt-get install -y acct
|
||||||
|
|
||||||
if [[ ! -d /etc/systemd/system/multi-user.target.wants ]]; then
|
if [[ ! -d /etc/systemd/system/multi-user.target.wants ]]; then
|
||||||
|
|
||||||
mkdir -p /etc/systemd/system/multi-user.target.wants
|
mkdir -p /etc/systemd/system/multi-user.target.wants
|
||||||
|
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if ln -s /lib/systemd/system/acct.service /etc/systemd/system/multi-user.target.wants/acct.service; then
|
if ln -s /lib/systemd/system/acct.service /etc/systemd/system/multi-user.target.wants/acct.service; then
|
||||||
|
|
||||||
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ 'Process Accounting' enabled successful. \e[0m\n"
|
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ 'Process Accounting' enabled successful. \e[0m\n"
|
||||||
|
|
||||||
else
|
else
|
||||||
|
|
||||||
printf "\e[91m++++ ++++ ++++ ++++ ++++ ++++ ++ ❌ 'Process Accounting' already enabled. \e[0m\n" >&2
|
printf "\e[91m++++ ++++ ++++ ++++ ++++ ++++ ++ ❌ 'Process Accounting' already enabled. \e[0m\n" >&2
|
||||||
|
|
||||||
fi
|
fi
|
||||||
|
|
||||||
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ '%s' applied successfully. \e[0m\n" "${0}"
|
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ '%s' applied successfully. \e[0m\n" "${0}"
|
||||||
# sleep 1
|
|
||||||
|
|
||||||
exit 0
|
exit 0
|
||||||
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=sh
|
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=sh
|
||||||
|
|||||||
@@ -1,18 +1,17 @@
|
|||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
# SPDX-Version: 3.0
|
# SPDX-Version: 3.0
|
||||||
# SPDX-CreationInfo: 2025-05-05; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-CreationInfo: 2025-10-11; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
||||||
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
# SPDX-FileCopyrightText: 2024–2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-FileType: SOURCE
|
# SPDX-FileType: SOURCE
|
||||||
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
# SPDX-LicenseComment: This file is part of the CISS.hardened.installer framework.
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
# SPDX-PackageName: CISS.debian.live.builder
|
# SPDX-PackageName: CISS.debian.live.builder
|
||||||
# SPDX-Security-Contact: security@coresecret.eu
|
# SPDX-Security-Contact: security@coresecret.eu
|
||||||
set -C -e -u -o pipefail
|
set -Ceuo pipefail
|
||||||
|
|
||||||
printf "\e[95m++++ ++++ ++++ ++++ ++++ ++++ ++ 🧪 '%s' starting ... \e[0m\n" "${0}"
|
printf "\e[95m++++ ++++ ++++ ++++ ++++ ++++ ++ 🧪 '%s' starting ... \e[0m\n" "${0}"
|
||||||
# sleep 1
|
|
||||||
|
|
||||||
mkdir -p /root/.ciss/dlb/backup/update-motd.d
|
mkdir -p /root/.ciss/dlb/backup/update-motd.d
|
||||||
cp -af /etc/update-motd.d/* /root/.ciss/dlb/backup/update-motd.d
|
cp -af /etc/update-motd.d/* /root/.ciss/dlb/backup/update-motd.d
|
||||||
@@ -24,8 +23,7 @@ EOF
|
|||||||
|
|
||||||
chmod 0755 /etc/update-motd.d/10-uname
|
chmod 0755 /etc/update-motd.d/10-uname
|
||||||
|
|
||||||
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ '%s' successful applied. \e[0m\n" "${0}"
|
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ '%s' successfully applied. \e[0m\n" "${0}"
|
||||||
# sleep 1
|
|
||||||
|
|
||||||
exit 0
|
exit 0
|
||||||
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=sh
|
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=sh
|
||||||
|
|||||||
@@ -1,18 +1,17 @@
|
|||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
# SPDX-Version: 3.0
|
# SPDX-Version: 3.0
|
||||||
# SPDX-CreationInfo: 2025-05-05; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-CreationInfo: 2025-10-11; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
||||||
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
# SPDX-FileCopyrightText: 2024–2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-FileType: SOURCE
|
# SPDX-FileType: SOURCE
|
||||||
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
# SPDX-PackageName: CISS.debian.live.builder
|
# SPDX-PackageName: CISS.debian.live.builder
|
||||||
# SPDX-Security-Contact: security@coresecret.eu
|
# SPDX-Security-Contact: security@coresecret.eu
|
||||||
set -C -e -u -o pipefail
|
set -Ceuo pipefail
|
||||||
|
|
||||||
printf "\e[95m++++ ++++ ++++ ++++ ++++ ++++ ++ 🧪 '%s' starting ... \e[0m\n" "${0}"
|
printf "\e[95m++++ ++++ ++++ ++++ ++++ ++++ ++ 🧪 '%s' starting ... \e[0m\n" "${0}"
|
||||||
# sleep 1
|
|
||||||
|
|
||||||
declare -a search_dirs=("/etc/ssl/certs" "/usr/local/share/ca-certificates" "/usr/share/ca-certificates" "/etc/letsencrypt")
|
declare -a search_dirs=("/etc/ssl/certs" "/usr/local/share/ca-certificates" "/usr/share/ca-certificates" "/etc/letsencrypt")
|
||||||
declare backup_dir="/root/.ciss/dlb/backup/certificates"
|
declare backup_dir="/root/.ciss/dlb/backup/certificates"
|
||||||
@@ -27,17 +26,24 @@ declare -ax expired_certificates=()
|
|||||||
# search_dirs
|
# search_dirs
|
||||||
# dir
|
# dir
|
||||||
# Arguments:
|
# Arguments:
|
||||||
# None
|
# None
|
||||||
#######################################
|
#######################################
|
||||||
create_backup() {
|
create_backup() {
|
||||||
printf "\e[95m++++ ++++ ++++ ++++ ++++ ++++ ++ 🧪 Backup Certificate: '%s' ... \e[0m\n" "${backup_dir}"
|
printf "\e[95m++++ ++++ ++++ ++++ ++++ ++++ ++ 🧪 Backup Certificate: '%s' ... \e[0m\n" "${backup_dir}"
|
||||||
|
|
||||||
mkdir -p "${backup_dir}"
|
mkdir -p "${backup_dir}"
|
||||||
declare dir=""
|
declare dir=""
|
||||||
|
|
||||||
for dir in "${search_dirs[@]}"; do
|
for dir in "${search_dirs[@]}"; do
|
||||||
if [ -d "${dir}" ] && compgen -G "${dir}"/* > /dev/null; then
|
|
||||||
|
if [[ -d "${dir}" ]] && compgen -G "${dir}"/* > /dev/null; then
|
||||||
|
|
||||||
cp -r "${dir}"/* "${backup_dir}"
|
cp -r "${dir}"/* "${backup_dir}"
|
||||||
|
|
||||||
fi
|
fi
|
||||||
|
|
||||||
done
|
done
|
||||||
|
|
||||||
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ Backup Certificate: '%s' done.\e[0m\n" "${backup_dir}"
|
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ Backup Certificate: '%s' done.\e[0m\n" "${backup_dir}"
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -52,25 +58,32 @@ create_backup() {
|
|||||||
# EXPIRED_CERTIFICATES
|
# EXPIRED_CERTIFICATES
|
||||||
# SEARCH_DIRS
|
# SEARCH_DIRS
|
||||||
# Arguments:
|
# Arguments:
|
||||||
# None
|
# None
|
||||||
#######################################
|
#######################################
|
||||||
check_certificates() {
|
check_certificates() {
|
||||||
declare dir=""
|
declare dir=""
|
||||||
declare cert=""
|
declare cert=""
|
||||||
declare cert_date=""
|
declare cert_date=""
|
||||||
declare cert_date_seconds=""
|
declare cert_date_seconds=""
|
||||||
|
|
||||||
for dir in "${search_dirs[@]}"; do
|
for dir in "${search_dirs[@]}"; do
|
||||||
|
|
||||||
|
# shellcheck disable=SC2312
|
||||||
while IFS= read -r -d '' cert; do
|
while IFS= read -r -d '' cert; do
|
||||||
|
|
||||||
cert_date=$(openssl x509 -in "${cert}" -noout -enddate | sed 's/notAfter=//')
|
cert_date=$(openssl x509 -in "${cert}" -noout -enddate | sed 's/notAfter=//')
|
||||||
cert_date_seconds=$(date -d "${cert_date}" +%s)
|
cert_date_seconds=$(date -d "${cert_date}" +%s)
|
||||||
|
|
||||||
if [[ ${cert_date_seconds} -lt ${current_date} ]]; then
|
if [[ ${cert_date_seconds} -lt ${current_date} ]]; then
|
||||||
|
|
||||||
declare -g expired_certificates+=("${cert}")
|
declare -g expired_certificates+=("${cert}")
|
||||||
|
|
||||||
fi
|
fi
|
||||||
|
|
||||||
done < <(find "${dir}" -type f \( -name "*.crt" -o -name "*.pem" \) -print0)
|
done < <(find "${dir}" -type f \( -name "*.crt" -o -name "*.pem" \) -print0)
|
||||||
|
|
||||||
done
|
done
|
||||||
}
|
}
|
||||||
# done < <(find "${dir}" -type f -name "*.crt" -o -name "*.pem" -print0)
|
|
||||||
# done < <(find "${DIR}" -type f \( -name "*.crt" -o -name "*.pem" \) -print0)
|
|
||||||
|
|
||||||
#######################################
|
#######################################
|
||||||
# Find and clean all ca-certificates.crt files in SEARCH_DIRS.
|
# Find and clean all ca-certificates.crt files in SEARCH_DIRS.
|
||||||
@@ -80,13 +93,17 @@ check_certificates() {
|
|||||||
# cert
|
# cert
|
||||||
# line
|
# line
|
||||||
# Arguments:
|
# Arguments:
|
||||||
# None
|
# None
|
||||||
#######################################
|
#######################################
|
||||||
delete_expired_from_all_bundles() {
|
delete_expired_from_all_bundles() {
|
||||||
declare dir bundle
|
declare dir bundle
|
||||||
|
|
||||||
for dir in "${search_dirs[@]}"; do
|
for dir in "${search_dirs[@]}"; do
|
||||||
|
|
||||||
bundle="${dir}/ca-certificates.crt"
|
bundle="${dir}/ca-certificates.crt"
|
||||||
|
|
||||||
if [[ -f ${bundle} ]]; then
|
if [[ -f ${bundle} ]]; then
|
||||||
|
|
||||||
printf "\e[95m++++ ++++ ++++ ++++ ++++ ++++ ++ 🧪 Checking Root-CA Bundle: '%s' ...\e[0m\n" "${bundle}"
|
printf "\e[95m++++ ++++ ++++ ++++ ++++ ++++ ++ 🧪 Checking Root-CA Bundle: '%s' ...\e[0m\n" "${bundle}"
|
||||||
declare tmp_bundle="${bundle}.tmp"
|
declare tmp_bundle="${bundle}.tmp"
|
||||||
declare -a block=()
|
declare -a block=()
|
||||||
@@ -97,33 +114,57 @@ delete_expired_from_all_bundles() {
|
|||||||
|
|
||||||
declare line=""
|
declare line=""
|
||||||
while IFS= read -r line; do
|
while IFS= read -r line; do
|
||||||
|
|
||||||
block+=("${line}")
|
block+=("${line}")
|
||||||
|
|
||||||
if [[ ${line} == "-----END CERTIFICATE-----" ]]; then
|
if [[ ${line} == "-----END CERTIFICATE-----" ]]; then
|
||||||
|
|
||||||
cert=$(printf "%s\n" "${block[@]}")
|
cert=$(printf "%s\n" "${block[@]}")
|
||||||
enddate=$(echo "${cert}" | openssl x509 -noout -enddate 2> /dev/null | sed 's/notAfter=//')
|
enddate=$(echo "${cert}" | openssl x509 -noout -enddate 2> /dev/null | sed 's/notAfter=//')
|
||||||
|
|
||||||
if [[ -n ${enddate} ]]; then
|
if [[ -n ${enddate} ]]; then
|
||||||
|
|
||||||
declare cert_date_seconds=""
|
declare cert_date_seconds=""
|
||||||
cert_date_seconds=$(date -d "${enddate}" +%s)
|
cert_date_seconds=$(date -d "${enddate}" +%s)
|
||||||
|
|
||||||
if [[ ${cert_date_seconds} -lt ${current_date} ]]; then
|
if [[ ${cert_date_seconds} -lt ${current_date} ]]; then
|
||||||
|
|
||||||
expired=1
|
expired=1
|
||||||
|
|
||||||
else
|
else
|
||||||
|
|
||||||
expired=0
|
expired=0
|
||||||
|
|
||||||
fi
|
fi
|
||||||
|
|
||||||
else
|
else
|
||||||
|
|
||||||
expired=0
|
expired=0
|
||||||
|
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if [[ ${expired} -eq 0 ]]; then
|
if [[ ${expired} -eq 0 ]]; then
|
||||||
|
|
||||||
printf "%s\n" "${block[@]}" >> "${tmp_bundle}"
|
printf "%s\n" "${block[@]}" >> "${tmp_bundle}"
|
||||||
|
|
||||||
else
|
else
|
||||||
|
|
||||||
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ Certificate deleted: '%s' (Expired: %s)\e[0m\n" "${bundle}" "${enddate}"
|
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ Certificate deleted: '%s' (Expired: %s)\e[0m\n" "${bundle}" "${enddate}"
|
||||||
|
|
||||||
fi
|
fi
|
||||||
|
|
||||||
block=()
|
block=()
|
||||||
|
|
||||||
fi
|
fi
|
||||||
|
|
||||||
done < "${bundle}"
|
done < "${bundle}"
|
||||||
|
|
||||||
mv -f "${tmp_bundle}" "${bundle}"
|
mv -f "${tmp_bundle}" "${bundle}"
|
||||||
|
|
||||||
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ Checking Root-CA Bundle: '%s' done. \e[0m\n" "${bundle}"
|
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ Checking Root-CA Bundle: '%s' done. \e[0m\n" "${bundle}"
|
||||||
|
|
||||||
fi
|
fi
|
||||||
|
|
||||||
done
|
done
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -141,30 +182,38 @@ else
|
|||||||
printf "\e[95m++++ ++++ ++++ ++++ ++++ ++++ ++ 🧪 Expired certificates found:\e[0m\n"
|
printf "\e[95m++++ ++++ ++++ ++++ ++++ ++++ ++ 🧪 Expired certificates found:\e[0m\n"
|
||||||
|
|
||||||
for exp_cert in "${expired_certificates[@]}"; do
|
for exp_cert in "${expired_certificates[@]}"; do
|
||||||
|
|
||||||
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ '%s'. \e[0m\n" "${exp_cert}"
|
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ '%s'. \e[0m\n" "${exp_cert}"
|
||||||
|
|
||||||
done
|
done
|
||||||
|
|
||||||
for exp_cert in "${expired_certificates[@]}"; do
|
for exp_cert in "${expired_certificates[@]}"; do
|
||||||
|
|
||||||
rm -f "${exp_cert}"
|
rm -f "${exp_cert}"
|
||||||
|
|
||||||
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ Certificate deleted: '%s'.\e[0m\n" "${exp_cert}"
|
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ Certificate deleted: '%s'.\e[0m\n" "${exp_cert}"
|
||||||
basename=$(basename "${exp_cert}")
|
basename=$(basename "${exp_cert}")
|
||||||
mozilla_entry="mozilla/${basename%.pem}.crt"
|
mozilla_entry="mozilla/${basename%.pem}.crt"
|
||||||
mozilla_entry="${mozilla_entry%.crt}.crt"
|
mozilla_entry="${mozilla_entry%.crt}.crt"
|
||||||
declare ca_conf="/etc/ca-certificates.conf"
|
declare ca_conf="/etc/ca-certificates.conf"
|
||||||
|
|
||||||
if grep -Fxq "${mozilla_entry}" "${ca_conf}"; then
|
if grep -Fxq "${mozilla_entry}" "${ca_conf}"; then
|
||||||
|
|
||||||
sed -i "s|^${mozilla_entry}$|#${mozilla_entry}|" "${ca_conf}"
|
sed -i "s|^${mozilla_entry}$|#${mozilla_entry}|" "${ca_conf}"
|
||||||
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ Entry in ca-certificates.conf deselected: '#%s'.\e[0m\n" "${mozilla_entry}"
|
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ Entry in ca-certificates.conf deselected: '#%s'.\e[0m\n" "${mozilla_entry}"
|
||||||
|
|
||||||
fi
|
fi
|
||||||
|
|
||||||
done
|
done
|
||||||
|
|
||||||
printf "\e[95m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ Updating the certificate cache ... \e[0m\n"
|
printf "\e[95m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ Updating the certificate cache ... \e[0m\n"
|
||||||
update-ca-certificates --fresh
|
update-ca-certificates --fresh
|
||||||
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ Updating the certificate cache done.\e[0m\n"
|
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ Updating the certificate cache done.\e[0m\n"
|
||||||
# sleep 1
|
|
||||||
fi
|
fi
|
||||||
|
|
||||||
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ '%s' applied successfully. \e[0m\n" "${0}"
|
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ '%s' applied successfully. \e[0m\n" "${0}"
|
||||||
# sleep 1
|
|
||||||
|
|
||||||
exit 0
|
exit 0
|
||||||
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=sh
|
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=sh
|
||||||
|
|||||||
@@ -1,25 +1,26 @@
|
|||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
# SPDX-Version: 3.0
|
# SPDX-Version: 3.0
|
||||||
# SPDX-CreationInfo: 2025-05-05; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-CreationInfo: 2025-10-11; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
||||||
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
# SPDX-FileCopyrightText: 2024–2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-FileType: SOURCE
|
# SPDX-FileType: SOURCE
|
||||||
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
# SPDX-PackageName: CISS.debian.live.builder
|
# SPDX-PackageName: CISS.debian.live.builder
|
||||||
# SPDX-Security-Contact: security@coresecret.eu
|
# SPDX-Security-Contact: security@coresecret.eu
|
||||||
set -C -e -u -o pipefail
|
set -Ceuo pipefail
|
||||||
|
|
||||||
printf "\e[95m++++ ++++ ++++ ++++ ++++ ++++ ++ 🧪 '%s' starting ... \e[0m\n" "${0}"
|
printf "\e[95m++++ ++++ ++++ ++++ ++++ ++++ ++ 🧪 '%s' starting ... \e[0m\n" "${0}"
|
||||||
# sleep 1
|
|
||||||
|
|
||||||
cd /etc/ssh || {
|
cd /etc/ssh || {
|
||||||
printf "\e[91mm++++ ++++ ++++ ++++ ++++ ++++ ++ Could not find /etc/ssh \e[0m\n"
|
printf "\e[91mm++++ ++++ ++++ ++++ ++++ ++++ ++ Could not find /etc/ssh \e[0m\n"
|
||||||
}
|
}
|
||||||
rm -rf ssh_host_*key*
|
rm -rf ssh_host_*key*
|
||||||
|
|
||||||
|
# shellcheck disable=SC2312
|
||||||
ssh-keygen -o -N "" -t ed25519 -f /etc/ssh/ssh_host_ed25519_key -C "root@live-$(date -I)"
|
ssh-keygen -o -N "" -t ed25519 -f /etc/ssh/ssh_host_ed25519_key -C "root@live-$(date -I)"
|
||||||
|
# shellcheck disable=SC2312
|
||||||
ssh-keygen -o -N "" -t rsa -b 8192 -f /etc/ssh/ssh_host_rsa_key -C "root@live-$(date -I)"
|
ssh-keygen -o -N "" -t rsa -b 8192 -f /etc/ssh/ssh_host_rsa_key -C "root@live-$(date -I)"
|
||||||
|
|
||||||
awk '$5 >= 4000' /etc/ssh/moduli >| /etc/ssh/moduli.safe
|
awk '$5 >= 4000' /etc/ssh/moduli >| /etc/ssh/moduli.safe
|
||||||
@@ -44,7 +45,26 @@ ssh-keygen -r @ >| /root/sshfp
|
|||||||
# The chmod +x command ensures that the file is executed in every shell session. #
|
# The chmod +x command ensures that the file is executed in every shell session. #
|
||||||
###########################################################################################
|
###########################################################################################
|
||||||
cat << 'EOF' >| /etc/profile.d/idle-users.sh
|
cat << 'EOF' >| /etc/profile.d/idle-users.sh
|
||||||
declare -girx TMOUT=14400
|
# SPDX-Version: 3.0
|
||||||
|
# SPDX-CreationInfo: 2025-10-11; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
|
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
||||||
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
|
# SPDX-FileType: SOURCE
|
||||||
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
|
# SPDX-PackageName: CISS.debian.live.builder
|
||||||
|
# SPDX-Security-Contact: security@coresecret.eu
|
||||||
|
|
||||||
|
case $- in
|
||||||
|
*i*)
|
||||||
|
TMOUT=14400
|
||||||
|
export TMOUT
|
||||||
|
readonly TMOUT
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
|
||||||
|
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=sh
|
||||||
EOF
|
EOF
|
||||||
|
|
||||||
chmod +x /etc/profile.d/idle-users.sh
|
chmod +x /etc/profile.d/idle-users.sh
|
||||||
@@ -58,7 +78,6 @@ EOF
|
|||||||
chmod 0644 /etc/systemd/system/ssh.service.d/override.conf
|
chmod 0644 /etc/systemd/system/ssh.service.d/override.conf
|
||||||
|
|
||||||
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ '%s' applied successfully. \e[0m\n" "${0}"
|
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ '%s' applied successfully. \e[0m\n" "${0}"
|
||||||
# sleep 1
|
|
||||||
|
|
||||||
exit 0
|
exit 0
|
||||||
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=sh
|
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=sh
|
||||||
|
|||||||
93
config/hooks/live/9935_hardening_ssh.chroot.tmpl
Normal file
93
config/hooks/live/9935_hardening_ssh.chroot.tmpl
Normal file
@@ -0,0 +1,93 @@
|
|||||||
|
#!/bin/bash
|
||||||
|
# SPDX-Version: 3.0
|
||||||
|
# SPDX-CreationInfo: 2025-10-11; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
|
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
||||||
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
|
# SPDX-FileType: SOURCE
|
||||||
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
|
# SPDX-PackageName: CISS.debian.live.builder
|
||||||
|
# SPDX-Security-Contact: security@coresecret.eu
|
||||||
|
set -Ceuo pipefail
|
||||||
|
|
||||||
|
printf "\e[95m++++ ++++ ++++ ++++ ++++ ++++ ++ 🧪 '%s' starting ... \e[0m\n" "${0}"
|
||||||
|
|
||||||
|
cd /etc/ssh || {
|
||||||
|
printf "\e[91mm++++ ++++ ++++ ++++ ++++ ++++ ++ Could not find /etc/ssh \e[0m\n"
|
||||||
|
}
|
||||||
|
|
||||||
|
cat << 'EOF' >| ssh_host_ed25519_key
|
||||||
|
{{ secrets.CISS_DLB_SSH_HOST_ED25519_KEY }}
|
||||||
|
EOF
|
||||||
|
|
||||||
|
cat << 'EOF' >| ssh_host_ed25519_key.pub
|
||||||
|
{{ secrets.CISS_DLB_SSH_HOST_ED25519_KEY_PUB }}
|
||||||
|
EOF
|
||||||
|
|
||||||
|
cat << 'EOF' >| ssh_host_rsa_key
|
||||||
|
{{ secrets.CISS_DLB_SSH_HOST_RSA_KEY }}
|
||||||
|
EOF
|
||||||
|
|
||||||
|
cat << 'EOF' >| ssh_host_rsa_key.pub
|
||||||
|
{{ secrets.CISS_DLB_SSH_HOST_RSA_KEY_PUB }}
|
||||||
|
EOF
|
||||||
|
|
||||||
|
awk '$5 >= 4000' /etc/ssh/moduli >| /etc/ssh/moduli.safe
|
||||||
|
rm -rf /etc/ssh/moduli
|
||||||
|
mv /etc/ssh/moduli.safe /etc/ssh/moduli
|
||||||
|
|
||||||
|
chmod 0600 /etc/ssh/ssh_host_*_key
|
||||||
|
chown root:root /etc/ssh/ssh_host_*_key
|
||||||
|
chmod 0644 /etc/ssh/ssh_host_*_key.pub
|
||||||
|
chown root:root /etc/ssh/ssh_host_*_key.pub
|
||||||
|
|
||||||
|
chmod 600 /etc/ssh/sshd_config /etc/ssh/ssh_config
|
||||||
|
|
||||||
|
touch /root/sshfp
|
||||||
|
ssh-keygen -r @ >| /root/sshfp
|
||||||
|
|
||||||
|
###########################################################################################
|
||||||
|
# Remarks: The file /etc/profile.d/idle-users.sh is created to set two read-only #
|
||||||
|
# environment variables: TMOUT and HISTFILE. #
|
||||||
|
# TMOUT=14400 ensures that users are automatically logged out after 4 hours of inactivity.#
|
||||||
|
# readonly HISTFILE ensures that the command history cannot be changed. #
|
||||||
|
# The chmod +x command ensures that the file is executed in every shell session. #
|
||||||
|
###########################################################################################
|
||||||
|
cat << 'EOF' >| /etc/profile.d/idle-users.sh
|
||||||
|
# SPDX-Version: 3.0
|
||||||
|
# SPDX-CreationInfo: 2025-10-11; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
|
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
||||||
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
|
# SPDX-FileType: SOURCE
|
||||||
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
|
# SPDX-PackageName: CISS.debian.live.builder
|
||||||
|
# SPDX-Security-Contact: security@coresecret.eu
|
||||||
|
|
||||||
|
case $- in
|
||||||
|
*i*)
|
||||||
|
TMOUT=14400
|
||||||
|
export TMOUT
|
||||||
|
readonly TMOUT
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
|
||||||
|
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=sh
|
||||||
|
EOF
|
||||||
|
|
||||||
|
chmod +x /etc/profile.d/idle-users.sh
|
||||||
|
|
||||||
|
mkdir -p /etc/systemd/system/ssh.service.d
|
||||||
|
cat << 'EOF' >| /etc/systemd/system/ssh.service.d/override.conf
|
||||||
|
[Unit]
|
||||||
|
After=ufw.service
|
||||||
|
Requires=ufw.service
|
||||||
|
EOF
|
||||||
|
chmod 0644 /etc/systemd/system/ssh.service.d/override.conf
|
||||||
|
|
||||||
|
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ '%s' applied successfully. \e[0m\n" "${0}"
|
||||||
|
|
||||||
|
exit 0
|
||||||
|
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=sh
|
||||||
@@ -1,26 +1,31 @@
|
|||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
# SPDX-Version: 3.0
|
# SPDX-Version: 3.0
|
||||||
# SPDX-CreationInfo: 2025-05-05; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-CreationInfo: 2025-10-11; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
||||||
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
# SPDX-FileCopyrightText: 2024–2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-FileType: SOURCE
|
# SPDX-FileType: SOURCE
|
||||||
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
# SPDX-PackageName: CISS.debian.live.builder
|
# SPDX-PackageName: CISS.debian.live.builder
|
||||||
# SPDX-Security-Contact: security@coresecret.eu
|
# SPDX-Security-Contact: security@coresecret.eu
|
||||||
set -C -e -u -o pipefail
|
set -Ceuo pipefail
|
||||||
|
|
||||||
printf "\e[95m++++ ++++ ++++ ++++ ++++ ++++ ++ 🧪 '%s' starting ... \e[0m\n" "${0}"
|
printf "\e[95m++++ ++++ ++++ ++++ ++++ ++++ ++ 🧪 '%s' starting ... \e[0m\n" "${0}"
|
||||||
# sleep 1
|
|
||||||
|
|
||||||
cp -u /etc/security/limits.conf /root/.ciss/dlb/backup/limits.conf.bak
|
cp -u /etc/security/limits.conf /root/.ciss/dlb/backup/limits.conf.bak
|
||||||
chmod 0644 /root/.ciss/dlb/backup/limits.conf.bak
|
chmod 0644 /root/.ciss/dlb/backup/limits.conf.bak
|
||||||
sed -i "/#* soft core 0/ i\* soft core 0" /etc/security/limits.conf
|
|
||||||
sed -i "/#root hard core 100000/ i\* hard core 0" /etc/security/limits.conf
|
grep -Eq '^[[:space:]]*\*[[:space:]]+soft[[:space:]]+core[[:space:]]+0[[:space:]]*$' /etc/security/limits.conf \
|
||||||
|
|| sed -i -E '/^[[:space:]]*#?[[:space:]]*soft[[:space:]]+core[[:space:]]+0[[:space:]]*$/ i\* soft core 0' /etc/security/limits.conf
|
||||||
|
|
||||||
|
grep -Eq '^[[:space:]]*\*[[:space:]]+hard[[:space:]]+core[[:space:]]+0[[:space:]]*$' /etc/security/limits.conf \
|
||||||
|
|| sed -i -E '/^[[:space:]]*#?[[:space:]]*root[[:space:]]+hard[[:space:]]+core[[:space:]]+100000[[:space:]]*$/ i\* hard core 0' /etc/security/limits.conf
|
||||||
|
|
||||||
if [[ ! -d /etc/systemd/coredump.conf.d ]]; then
|
if [[ ! -d /etc/systemd/coredump.conf.d ]]; then
|
||||||
|
|
||||||
mkdir -p /etc/systemd/coredump.conf.d
|
mkdir -p /etc/systemd/coredump.conf.d
|
||||||
|
|
||||||
fi
|
fi
|
||||||
|
|
||||||
touch /etc/systemd/coredump.conf.d/disable.conf
|
touch /etc/systemd/coredump.conf.d/disable.conf
|
||||||
@@ -31,7 +36,6 @@ Storage=none
|
|||||||
EOF
|
EOF
|
||||||
|
|
||||||
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ '%s' applied successfully. \e[0m\n" "${0}"
|
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ '%s' applied successfully. \e[0m\n" "${0}"
|
||||||
# sleep 1
|
|
||||||
|
|
||||||
exit 0
|
exit 0
|
||||||
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=sh
|
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=sh
|
||||||
|
|||||||
@@ -1,18 +1,17 @@
|
|||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
# SPDX-Version: 3.0
|
# SPDX-Version: 3.0
|
||||||
# SPDX-CreationInfo: 2025-05-05; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-CreationInfo: 2025-10-11; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
||||||
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
# SPDX-FileCopyrightText: 2024–2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-FileType: SOURCE
|
# SPDX-FileType: SOURCE
|
||||||
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
# SPDX-PackageName: CISS.debian.live.builder
|
# SPDX-PackageName: CISS.debian.live.builder
|
||||||
# SPDX-Security-Contact: security@coresecret.eu
|
# SPDX-Security-Contact: security@coresecret.eu
|
||||||
set -C -e -u -o pipefail
|
set -Ceuo pipefail
|
||||||
|
|
||||||
printf "\e[95m++++ ++++ ++++ ++++ ++++ ++++ ++ 🧪 '%s' starting ... \e[0m\n" "${0}"
|
printf "\e[95m++++ ++++ ++++ ++++ ++++ ++++ ++ 🧪 '%s' starting ... \e[0m\n" "${0}"
|
||||||
# sleep 1
|
|
||||||
|
|
||||||
cd /root
|
cd /root
|
||||||
|
|
||||||
@@ -30,11 +29,11 @@ cat << 'EOF' >| /etc/fail2ban/jail.d/centurion-default.conf
|
|||||||
# SPDX-CreationInfo: 2025-05-05; WEIDNER, Marc S.; <cendev@coresecret.eu>
|
# SPDX-CreationInfo: 2025-05-05; WEIDNER, Marc S.; <cendev@coresecret.eu>
|
||||||
# SPDX-ExternalRef: GIT https://cendev.eu/marc.weidner/CISS.2025.debian.live.builder.git
|
# SPDX-ExternalRef: GIT https://cendev.eu/marc.weidner/CISS.2025.debian.live.builder.git
|
||||||
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
# SPDX-FileCopyrightText: 2024–2025; WEIDNER, Marc S.; <cendev@coresecret.eu>
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <cendev@coresecret.eu>
|
||||||
# SPDX-FileType: SOURCE
|
# SPDX-FileType: SOURCE
|
||||||
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
# SPDX-LicenseComment: This file is part of the CISS.2025.hardened.installer framework.
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
# SPDX-PackageName: CISS.2025.debian.live.builder
|
# SPDX-PackageName: CISS.debian.live.builder
|
||||||
# SPDX-Security-Contact: security@coresecret.eu
|
# SPDX-Security-Contact: security@coresecret.eu
|
||||||
|
|
||||||
[DEFAULT]
|
[DEFAULT]
|
||||||
@@ -46,7 +45,7 @@ findtime = 24h
|
|||||||
bantime = 24h
|
bantime = 24h
|
||||||
|
|
||||||
### SSH Handling: Foreign IP (not in /etc/hosts.allow): refused to connect: immediate ban [sshd-refused]
|
### SSH Handling: Foreign IP (not in /etc/hosts.allow): refused to connect: immediate ban [sshd-refused]
|
||||||
### Jump host mistyped 1–3 times: no ban, only after four attempts [sshd]
|
### Jump host mistyped 1-3 times: no ban, only after four attempts [sshd]
|
||||||
|
|
||||||
[sshd]
|
[sshd]
|
||||||
enabled = true
|
enabled = true
|
||||||
@@ -142,7 +141,6 @@ touch /var/log/fail2ban/fail2ban.log
|
|||||||
chmod 640 /var/log/fail2ban/fail2ban.log
|
chmod 640 /var/log/fail2ban/fail2ban.log
|
||||||
|
|
||||||
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ '%s' applied successfully. \e[0m\n" "${0}"
|
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ '%s' applied successfully. \e[0m\n" "${0}"
|
||||||
# sleep 1
|
|
||||||
|
|
||||||
exit 0
|
exit 0
|
||||||
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=sh
|
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=sh
|
||||||
|
|||||||
@@ -1,18 +1,17 @@
|
|||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
# SPDX-Version: 3.0
|
# SPDX-Version: 3.0
|
||||||
# SPDX-CreationInfo: 2025-05-05; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-CreationInfo: 2025-10-11; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
||||||
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
# SPDX-FileCopyrightText: 2024–2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-FileType: SOURCE
|
# SPDX-FileType: SOURCE
|
||||||
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
# SPDX-PackageName: CISS.debian.live.builder
|
# SPDX-PackageName: CISS.debian.live.builder
|
||||||
# SPDX-Security-Contact: security@coresecret.eu
|
# SPDX-Security-Contact: security@coresecret.eu
|
||||||
set -C -e -u -o pipefail
|
set -Ceuo pipefail
|
||||||
|
|
||||||
printf "\e[95m++++ ++++ ++++ ++++ ++++ ++++ ++ 🧪 '%s' starting ... \e[0m\n" "${0}"
|
printf "\e[95m++++ ++++ ++++ ++++ ++++ ++++ ++ 🧪 '%s' starting ... \e[0m\n" "${0}"
|
||||||
# sleep 1
|
|
||||||
|
|
||||||
###########################################################################################
|
###########################################################################################
|
||||||
# Remarks: Turn off Energy saving mode and ctrl-alt-del #
|
# Remarks: Turn off Energy saving mode and ctrl-alt-del #
|
||||||
@@ -25,7 +24,6 @@ done
|
|||||||
unset target
|
unset target
|
||||||
|
|
||||||
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ '%s' applied successfully. \e[0m\n" "${0}"
|
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ '%s' applied successfully. \e[0m\n" "${0}"
|
||||||
# sleep 1
|
|
||||||
|
|
||||||
exit 0
|
exit 0
|
||||||
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=sh
|
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=sh
|
||||||
|
|||||||
@@ -1,32 +1,28 @@
|
|||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
# SPDX-Version: 3.0
|
# SPDX-Version: 3.0
|
||||||
# SPDX-CreationInfo: 2025-05-05; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-CreationInfo: 2025-10-11; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
||||||
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
# SPDX-FileCopyrightText: 2024–2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-FileType: SOURCE
|
# SPDX-FileType: SOURCE
|
||||||
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
# SPDX-PackageName: CISS.debian.live.builder
|
# SPDX-PackageName: CISS.debian.live.builder
|
||||||
# SPDX-Security-Contact: security@coresecret.eu
|
# SPDX-Security-Contact: security@coresecret.eu
|
||||||
set -C -e -u -o pipefail
|
set -Ceuo pipefail
|
||||||
|
|
||||||
printf "\e[95m++++ ++++ ++++ ++++ ++++ ++++ ++ 🧪 '%s' starting ... \e[0m\n" "${0}"
|
printf "\e[95m++++ ++++ ++++ ++++ ++++ ++++ ++ 🧪 '%s' starting ... \e[0m\n" "${0}"
|
||||||
# sleep 1
|
|
||||||
|
|
||||||
cd /etc
|
cd /etc
|
||||||
|
|
||||||
apt-get purge exim4 -y
|
apt-get purge exim4 exim4-base exim4-config -y
|
||||||
apt-get purge exim4-base -y
|
|
||||||
apt-get purge exim4-config -y
|
|
||||||
|
|
||||||
apt-get autoremove -y
|
apt-get autoremove -y
|
||||||
apt-get autoclean -y
|
apt-get autoclean -y
|
||||||
apt-get autopurge -y
|
apt-get autopurge -y
|
||||||
|
|
||||||
apt-mark hold exim4 exim4-daemon-light exim4-base exim4-config
|
apt-mark hold exim4 exim4-daemon-light exim4-base exim4-config
|
||||||
|
|
||||||
apt-get update -y
|
apt-get update
|
||||||
apt-get upgrade -y
|
apt-get upgrade -y
|
||||||
|
|
||||||
if [[ -d /etc/exim4 ]]; then
|
if [[ -d /etc/exim4 ]]; then
|
||||||
@@ -34,7 +30,6 @@ if [[ -d /etc/exim4 ]]; then
|
|||||||
fi
|
fi
|
||||||
|
|
||||||
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ '%s' applied successfully. \e[0m\n" "${0}"
|
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ '%s' applied successfully. \e[0m\n" "${0}"
|
||||||
# sleep 1
|
|
||||||
|
|
||||||
exit 0
|
exit 0
|
||||||
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=sh
|
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=sh
|
||||||
|
|||||||
@@ -1,45 +1,45 @@
|
|||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
# SPDX-Version: 3.0
|
# SPDX-Version: 3.0
|
||||||
# SPDX-CreationInfo: 2025-05-05; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-CreationInfo: 2025-10-11; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
||||||
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
# SPDX-FileCopyrightText: 2024–2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-FileType: SOURCE
|
# SPDX-FileType: SOURCE
|
||||||
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
# SPDX-PackageName: CISS.debian.live.builder
|
# SPDX-PackageName: CISS.debian.live.builder
|
||||||
# SPDX-Security-Contact: security@coresecret.eu
|
# SPDX-Security-Contact: security@coresecret.eu
|
||||||
set -C -e -u -o pipefail
|
set -Ceuo pipefail
|
||||||
|
|
||||||
printf "\e[95m++++ ++++ ++++ ++++ ++++ ++++ ++ 🧪 '%s' starting ... \e[0m\n" "${0}"
|
printf "\e[95m++++ ++++ ++++ ++++ ++++ ++++ ++ 🧪 '%s' starting ... \e[0m\n" "${0}"
|
||||||
# sleep 1
|
|
||||||
|
|
||||||
|
export DEBIAN_FRONTEND="noninteractive"
|
||||||
apt-get install -y usbguard
|
apt-get install -y usbguard
|
||||||
|
|
||||||
# sleep 1
|
### Preparing USBGuard: see https://www.privacy-handbuch.de/handbuch_91a.htm
|
||||||
|
|
||||||
# Preparing USBGuard: see https://www.privacy-handbuch.de/handbuch_91a.htm
|
|
||||||
touch /tmp/rules.conf
|
touch /tmp/rules.conf
|
||||||
usbguard generate-policy >> /tmp/rules.conf
|
usbguard generate-policy >> /tmp/rules.conf
|
||||||
|
|
||||||
if [[ -f /etc/usbguard/rules.conf && -s /etc/usbguard/rules.conf ]]; then
|
if [[ -f /etc/usbguard/rules.conf && -s /etc/usbguard/rules.conf ]]; then
|
||||||
|
|
||||||
mv /etc/usbguard/rules.conf /root/.ciss/dlb/backup/usbguard_rules.conf.bak
|
mv /etc/usbguard/rules.conf /root/.ciss/dlb/backup/usbguard_rules.conf.bak
|
||||||
cp -a /tmp/rules.conf /etc/usbguard/rules.conf
|
cp -a /tmp/rules.conf /etc/usbguard/rules.conf
|
||||||
chmod 0600 /etc/usbguard/rules.conf
|
chmod 0600 /etc/usbguard/rules.conf
|
||||||
|
|
||||||
else
|
else
|
||||||
|
|
||||||
rm -f /etc/usbguard/rules.conf
|
rm -f /etc/usbguard/rules.conf
|
||||||
cp -a /tmp/rules.conf /etc/usbguard/rules.conf
|
cp -a /tmp/rules.conf /etc/usbguard/rules.conf
|
||||||
chmod 0600 /etc/usbguard/rules.conf
|
chmod 0600 /etc/usbguard/rules.conf
|
||||||
|
|
||||||
fi
|
fi
|
||||||
|
|
||||||
cp -a /etc/usbguard/usbguard-daemon.conf /root/.ciss/dlb/backup/usbguard-daemon.conf.bak
|
cp -a /etc/usbguard/usbguard-daemon.conf /root/.ciss/dlb/backup/usbguard-daemon.conf.bak
|
||||||
sed -i "s/PresentDevicePolicy=apply-policy/PresentDevicePolicy=allow/" /etc/usbguard/usbguard-daemon.conf
|
#sed -i "s/PresentDevicePolicy=apply-policy/PresentDevicePolicy=allow/" /etc/usbguard/usbguard-daemon.conf
|
||||||
# sleep 1
|
|
||||||
|
|
||||||
rm -f /tmp/rules.conf
|
rm -f /tmp/rules.conf
|
||||||
|
|
||||||
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ '%s' applied successfully. \e[0m\n" "${0}"
|
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ '%s' applied successfully. \e[0m\n" "${0}"
|
||||||
# sleep 1
|
|
||||||
|
|
||||||
exit 0
|
exit 0
|
||||||
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=sh
|
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=sh
|
||||||
|
|||||||
@@ -1,18 +1,17 @@
|
|||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
# SPDX-Version: 3.0
|
# SPDX-Version: 3.0
|
||||||
# SPDX-CreationInfo: 2025-05-05; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-CreationInfo: 2025-10-11; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
||||||
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
# SPDX-FileCopyrightText: 2024–2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-FileType: SOURCE
|
# SPDX-FileType: SOURCE
|
||||||
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
# SPDX-PackageName: CISS.debian.live.builder
|
# SPDX-PackageName: CISS.debian.live.builder
|
||||||
# SPDX-Security-Contact: security@coresecret.eu
|
# SPDX-Security-Contact: security@coresecret.eu
|
||||||
set -C -e -u -o pipefail
|
set -Ceuo pipefail
|
||||||
|
|
||||||
printf "\e[95m++++ ++++ ++++ ++++ ++++ ++++ ++ 🧪 '%s' starting ... \e[0m\n" "${0}"
|
printf "\e[95m++++ ++++ ++++ ++++ ++++ ++++ ++ 🧪 '%s' starting ... \e[0m\n" "${0}"
|
||||||
# sleep 1
|
|
||||||
|
|
||||||
mkdir -p /etc/systemd/system/clamav-daemon.service.d
|
mkdir -p /etc/systemd/system/clamav-daemon.service.d
|
||||||
cat << 'EOF' >| /etc/systemd/system/clamav-daemon.service.d/override.conf
|
cat << 'EOF' >| /etc/systemd/system/clamav-daemon.service.d/override.conf
|
||||||
@@ -32,8 +31,8 @@ ReadOnlyPaths=/
|
|||||||
ReadWritePaths=/var/lib/clamav /var/log/clamav /var/run/clamav /run/clamav
|
ReadWritePaths=/var/lib/clamav /var/log/clamav /var/run/clamav /run/clamav
|
||||||
|
|
||||||
MemoryDenyWriteExecute=yes
|
MemoryDenyWriteExecute=yes
|
||||||
MemoryLimit=512M
|
#MemoryLimit=4096M
|
||||||
CPUShares=512
|
#CPUShares=512
|
||||||
|
|
||||||
RestrictAddressFamilies=AF_INET AF_INET6
|
RestrictAddressFamilies=AF_INET AF_INET6
|
||||||
RestrictNamespaces=yes
|
RestrictNamespaces=yes
|
||||||
@@ -58,8 +57,8 @@ ReadOnlyPaths=/
|
|||||||
ReadWritePaths=/var/lib/clamav /var/log/clamav /var/run/clamav
|
ReadWritePaths=/var/lib/clamav /var/log/clamav /var/run/clamav
|
||||||
|
|
||||||
MemoryDenyWriteExecute=yes
|
MemoryDenyWriteExecute=yes
|
||||||
MemoryLimit=512M
|
#MemoryLimit=4096M
|
||||||
CPUShares=512
|
#CPUShares=512
|
||||||
|
|
||||||
RestrictAddressFamilies=AF_INET AF_INET6
|
RestrictAddressFamilies=AF_INET AF_INET6
|
||||||
RestrictNamespaces=yes
|
RestrictNamespaces=yes
|
||||||
@@ -71,7 +70,6 @@ EOF
|
|||||||
chmod 0644 /etc/systemd/system/clamav-freshclam.service.d/override.conf
|
chmod 0644 /etc/systemd/system/clamav-freshclam.service.d/override.conf
|
||||||
|
|
||||||
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ '%s' applied successfully. \e[0m\n" "${0}"
|
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ '%s' applied successfully. \e[0m\n" "${0}"
|
||||||
# sleep 1
|
|
||||||
|
|
||||||
exit 0
|
exit 0
|
||||||
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=sh
|
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=sh
|
||||||
|
|||||||
@@ -1,47 +1,52 @@
|
|||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
# SPDX-Version: 3.0
|
# SPDX-Version: 3.0
|
||||||
# SPDX-CreationInfo: 2025-05-05; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-CreationInfo: 2025-10-11; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
||||||
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
# SPDX-FileCopyrightText: 2024–2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-FileType: SOURCE
|
# SPDX-FileType: SOURCE
|
||||||
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
# SPDX-PackageName: CISS.debian.live.builder
|
# SPDX-PackageName: CISS.debian.live.builder
|
||||||
# SPDX-Security-Contact: security@coresecret.eu
|
# SPDX-Security-Contact: security@coresecret.eu
|
||||||
set -C -e -u -o pipefail
|
set -Ceuo pipefail
|
||||||
|
|
||||||
printf "\e[95m++++ ++++ ++++ ++++ ++++ ++++ ++ 🧪 '%s' starting ... \e[0m\n" "${0}"
|
printf "\e[95m++++ ++++ ++++ ++++ ++++ ++++ ++ 🧪 '%s' starting ... \e[0m\n" "${0}"
|
||||||
# sleep 1
|
|
||||||
|
|
||||||
apt-get update -y
|
export DEBIAN_FRONTEND="noninteractive"
|
||||||
|
|
||||||
apt-get purge -y exim4 exim4-daemon-light exim4-base exim4-config \
|
apt-get update -qq
|
||||||
qemu-guest-agent rmail sendmail-base sendmail-bin sendmail-cf sensible-mda sendmail-doc
|
|
||||||
|
|
||||||
apt-mark hold exim4 exim4-daemon-light exim4-base exim4-config \
|
apt-get purge -y exim4 exim4-daemon-light exim4-base exim4-config qemu-guest-agent rmail
|
||||||
qemu-guest-agent rmail sendmail-base sendmail-bin sendmail-cf sensible-mda sendmail-doc
|
|
||||||
|
|
||||||
dpkg --get-selections | grep deinstall >> /tmp/deinstall.log || true
|
apt-mark hold exim4 exim4-daemon-light exim4-base exim4-config qemu-guest-agent rmail
|
||||||
|
|
||||||
|
dpkg --get-selections | grep deinstall >| /tmp/deinstall.log || true
|
||||||
|
|
||||||
if [[ -s /tmp/deinstall.log ]]; then
|
if [[ -s /tmp/deinstall.log ]]; then
|
||||||
|
|
||||||
printf "\n"
|
printf "\n"
|
||||||
printf "\e[95m++++ ++++ ++++ ++++ ++++ ++++ ++ 🧪 Packages to purge ... \e[0m\n"
|
printf "\e[95m++++ ++++ ++++ ++++ ++++ ++++ ++ 🧪 Packages to purge ... \e[0m\n"
|
||||||
sed -i 's!deinstall!!' /tmp/deinstall.log
|
sed -i 's!deinstall!!' /tmp/deinstall.log
|
||||||
|
|
||||||
while IFS= read -r line; do
|
while IFS= read -r line; do
|
||||||
|
|
||||||
declare trimmed_string
|
declare trimmed_string
|
||||||
trimmed_string=$(echo "$line" | awk '{$1=$1};1')
|
trimmed_string=$(echo "${line}" | awk '{$1=$1};1')
|
||||||
echo "y" | apt-get purge "${trimmed_string}"
|
echo "y" | apt-get purge "${trimmed_string}"
|
||||||
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ Package '%s' purged. \e[0m\n" "${trimmed_string}"
|
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ Package '%s' purged. \e[0m\n" "${trimmed_string}"
|
||||||
# sleep 1
|
|
||||||
done < /tmp/deinstall.log
|
done < /tmp/deinstall.log
|
||||||
|
|
||||||
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ Packages to purge done. \e[0m\n"
|
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ Packages to purge done. \e[0m\n"
|
||||||
|
|
||||||
else
|
else
|
||||||
|
|
||||||
printf "\n"
|
printf "\n"
|
||||||
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ No Packages to purge, proceeding with clean up. \e[0m\n"
|
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ No Packages to purge, proceeding with clean up. \e[0m\n"
|
||||||
|
|
||||||
fi
|
fi
|
||||||
|
|
||||||
apt-get update -y
|
|
||||||
apt-get upgrade -y
|
apt-get upgrade -y
|
||||||
|
|
||||||
rm -f /tmp/deinstall.log
|
rm -f /tmp/deinstall.log
|
||||||
@@ -52,8 +57,7 @@ apt-get autopurge -y
|
|||||||
|
|
||||||
updatedb
|
updatedb
|
||||||
|
|
||||||
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ '%s' successful applied. \e[0m\n" "${0}"
|
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ '%s' successfully applied. \e[0m\n" "${0}"
|
||||||
# sleep 1
|
|
||||||
|
|
||||||
exit 0
|
exit 0
|
||||||
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=sh
|
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=sh
|
||||||
|
|||||||
@@ -1,18 +1,17 @@
|
|||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
# SPDX-Version: 3.0
|
# SPDX-Version: 3.0
|
||||||
# SPDX-CreationInfo: 2025-05-05; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-CreationInfo: 2025-10-11; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
||||||
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
# SPDX-FileCopyrightText: 2024–2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-FileType: SOURCE
|
# SPDX-FileType: SOURCE
|
||||||
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
# SPDX-PackageName: CISS.debian.live.builder
|
# SPDX-PackageName: CISS.debian.live.builder
|
||||||
# SPDX-Security-Contact: security@coresecret.eu
|
# SPDX-Security-Contact: security@coresecret.eu
|
||||||
set -C -e -u -o pipefail
|
set -Ceuo pipefail
|
||||||
|
|
||||||
printf "\e[95m++++ ++++ ++++ ++++ ++++ ++++ ++ 🧪 '%s' starting ... \e[0m\n" "${0}"
|
printf "\e[95m++++ ++++ ++++ ++++ ++++ ++++ ++ 🧪 '%s' starting ... \e[0m\n" "${0}"
|
||||||
# sleep 1
|
|
||||||
|
|
||||||
chmod 0644 /etc/banner
|
chmod 0644 /etc/banner
|
||||||
chmod 0644 /etc/issue
|
chmod 0644 /etc/issue
|
||||||
@@ -39,6 +38,7 @@ EOF
|
|||||||
|
|
||||||
cp -a /etc/login.defs /root/.ciss/dlb/backup/login.defs.bak
|
cp -a /etc/login.defs /root/.ciss/dlb/backup/login.defs.bak
|
||||||
|
|
||||||
|
sed -ri 's/^(#?LOGIN_TIMEOUT)[[:space:]]+[0-9]+/\1 180/' /etc/login.defs
|
||||||
sed -i 's/UMASK 022/UMASK 077/' /etc/login.defs
|
sed -i 's/UMASK 022/UMASK 077/' /etc/login.defs
|
||||||
sed -i 's/PASS_MAX_DAYS 99999/PASS_MAX_DAYS 16384/' /etc/login.defs
|
sed -i 's/PASS_MAX_DAYS 99999/PASS_MAX_DAYS 16384/' /etc/login.defs
|
||||||
sed -i 's/PASS_MIN_DAYS 0/PASS_MIN_DAYS 1/' /etc/login.defs
|
sed -i 's/PASS_MIN_DAYS 0/PASS_MIN_DAYS 1/' /etc/login.defs
|
||||||
@@ -54,8 +54,8 @@ fi
|
|||||||
|
|
||||||
if [[ -f /etc/cron.allow ]]; then
|
if [[ -f /etc/cron.allow ]]; then
|
||||||
cp -u /etc/cron.allow /root/.backup/cron.allow.bak
|
cp -u /etc/cron.allow /root/.backup/cron.allow.bak
|
||||||
chmod 644 /root/.backup/cron.allow.bak
|
chmod 0644 /root/.backup/cron.allow.bak
|
||||||
chmod 600 /etc/cron.allow
|
chmod 0600 /etc/cron.allow
|
||||||
cat << EOF >| /etc/cron.allow
|
cat << EOF >| /etc/cron.allow
|
||||||
root
|
root
|
||||||
EOF
|
EOF
|
||||||
@@ -98,8 +98,18 @@ for bin in as gcc g++ cc clang; do
|
|||||||
done
|
done
|
||||||
unset bin target
|
unset bin target
|
||||||
|
|
||||||
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ '%s' successful applied. \e[0m\n" "${0}"
|
### Directories: 0700
|
||||||
# sleep 1
|
find /root -type d -exec chmod 0700 {} +
|
||||||
|
### Executable files: 0700 (any x-bit set)
|
||||||
|
find /root -type f -perm /111 -exec chmod 0700 {} +
|
||||||
|
### Non-executable files: 0600
|
||||||
|
find /root -type f ! -perm /111 -exec chmod 0600 {} +
|
||||||
|
### Ownership: UID:GID (do not dereference symlinks; stay on this filesystem)
|
||||||
|
find /root -xdev -exec chown -h root:root {} +
|
||||||
|
|
||||||
|
rm -f /etc/tmpfiles.d/legacy.conf
|
||||||
|
|
||||||
|
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ '%s' successfully applied. \e[0m\n" "${0}"
|
||||||
|
|
||||||
exit 0
|
exit 0
|
||||||
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=sh
|
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=sh
|
||||||
|
|||||||
@@ -1,42 +1,46 @@
|
|||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
# SPDX-Version: 3.0
|
# SPDX-Version: 3.0
|
||||||
# SPDX-CreationInfo: 2025-05-05; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-CreationInfo: 2025-10-11; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
||||||
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
# SPDX-FileCopyrightText: 2024–2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-FileType: SOURCE
|
# SPDX-FileType: SOURCE
|
||||||
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
# SPDX-LicenseComment: This file is part of the CISS.hardened.installer framework.
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
# SPDX-PackageName: CISS.debian.live.builder
|
# SPDX-PackageName: CISS.debian.live.builder
|
||||||
# SPDX-Security-Contact: security@coresecret.eu
|
# SPDX-Security-Contact: security@coresecret.eu
|
||||||
set -C -e -u -o pipefail
|
set -Ceuo pipefail
|
||||||
|
|
||||||
printf "\e[95m++++ ++++ ++++ ++++ ++++ ++++ ++ 🧪 '%s' starting ... \e[0m\n" "${0}"
|
printf "\e[95m++++ ++++ ++++ ++++ ++++ ++++ ++ 🧪 '%s' starting ... \e[0m\n" "${0}"
|
||||||
# sleep 1
|
|
||||||
|
|
||||||
if ! command -v chage &>/dev/null; then
|
if ! command -v chage &>/dev/null; then
|
||||||
|
|
||||||
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ Info: 'chage' NOT found. Exiting hook ... \e[0m\n"
|
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ Info: 'chage' NOT found. Exiting hook ... \e[0m\n"
|
||||||
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ '%s' applied successfully. \e[0m\n" "${0}"
|
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ '%s' applied successfully. \e[0m\n" "${0}"
|
||||||
# sleep 1
|
|
||||||
exit 0
|
exit 0
|
||||||
|
|
||||||
fi
|
fi
|
||||||
|
|
||||||
declare -i max_days=16384
|
declare -i max_days=16384
|
||||||
|
# shellcheck disable=SC2312
|
||||||
mapfile -t users_to_update < <(
|
mapfile -t users_to_update < <(
|
||||||
awk -F: '$2 !~ /^[!*]/ { print $1 }' /etc/shadow
|
awk -F: '$2 !~ /^[!*]/ { print $1 }' /etc/shadow
|
||||||
)
|
)
|
||||||
|
|
||||||
if [[ ${#users_to_update[@]} -eq 0 ]]; then
|
if [[ ${#users_to_update[@]} -eq 0 ]]; then
|
||||||
|
|
||||||
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ No enabled-login accounts found in /etc/shadow. Exiting hook ... \e[0m\n"
|
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ No enabled-login accounts found in /etc/shadow. Exiting hook ... \e[0m\n"
|
||||||
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ '%s' applied successfully. \e[0m\n" "${0}"
|
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ '%s' applied successfully. \e[0m\n" "${0}"
|
||||||
# sleep 1
|
|
||||||
exit 0
|
exit 0
|
||||||
|
|
||||||
fi
|
fi
|
||||||
|
|
||||||
declare user
|
declare user
|
||||||
for user in "${users_to_update[@]}"; do
|
for user in "${users_to_update[@]}"; do
|
||||||
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ Setting max password age for user '%s' to '%s' days. \e[0m\n" "${user}" "${max_days}"
|
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ Setting max password age for user '%s' to '%s' days. \e[0m\n" "${user}" "${max_days}"
|
||||||
chage --maxdays "$max_days" "$user"
|
chage --maxdays "${max_days}" "${user}"
|
||||||
done
|
done
|
||||||
|
|
||||||
unset max_days user users_to_update
|
unset max_days user users_to_update
|
||||||
@@ -46,7 +50,6 @@ awk -F: '$2 !~ /^\$[0-9]/ && length($2)==13 { print $1,$2 }' /etc/shadow
|
|||||||
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ All applicable accounts have been updated. \e[0m\n"
|
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ All applicable accounts have been updated. \e[0m\n"
|
||||||
|
|
||||||
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ '%s' applied successfully. \e[0m\n" "${0}"
|
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ '%s' applied successfully. \e[0m\n" "${0}"
|
||||||
# sleep 1
|
|
||||||
|
|
||||||
exit 0
|
exit 0
|
||||||
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=sh
|
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=sh
|
||||||
|
|||||||
@@ -1,32 +1,35 @@
|
|||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
# SPDX-Version: 3.0
|
# SPDX-Version: 3.0
|
||||||
# SPDX-CreationInfo: 2025-05-05; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-CreationInfo: 2025-10-11; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
||||||
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
# SPDX-FileCopyrightText: 2024–2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-FileType: SOURCE
|
# SPDX-FileType: SOURCE
|
||||||
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
# SPDX-LicenseComment: This file is part of the CISS.hardened.installer framework.
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
# SPDX-PackageName: CISS.debian.live.builder
|
# SPDX-PackageName: CISS.debian.live.builder
|
||||||
# SPDX-Security-Contact: security@coresecret.eu
|
# SPDX-Security-Contact: security@coresecret.eu
|
||||||
set -C -e -u -o pipefail
|
set -Ceuo pipefail
|
||||||
|
|
||||||
printf "\e[95m++++ ++++ ++++ ++++ ++++ ++++ ++ 🧪 '%s' starting ... \e[0m\n" "${0}"
|
printf "\e[95m++++ ++++ ++++ ++++ ++++ ++++ ++ 🧪 '%s' starting ... \e[0m\n" "${0}"
|
||||||
# sleep 1
|
|
||||||
|
|
||||||
apt-get install -y aide
|
export DEBIAN_FRONTEND="noninteractive"
|
||||||
|
apt-get install -y aide > /dev/null 2>&1
|
||||||
|
|
||||||
cp -u /etc/aide/aide.conf /root/.ciss/dlb/backup/aide.conf.bak
|
cp -u /etc/aide/aide.conf /root/.ciss/dlb/backup/aide.conf.bak
|
||||||
sed -i "s/Checksums = H/Checksums = sha512/" /etc/aide/aide.conf
|
sed -i "s/Checksums = H/Checksums = sha512/" /etc/aide/aide.conf
|
||||||
|
|
||||||
if aideinit; then
|
if aideinit > /dev/null 2>&1; then
|
||||||
|
|
||||||
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ 'aideinit' successful. \e[0m\n"
|
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ 'aideinit' successful. \e[0m\n"
|
||||||
|
|
||||||
else
|
else
|
||||||
|
|
||||||
printf "\e[91m++++ ++++ ++++ ++++ ++++ ++++ ++ ❌ 'aideinit' NOT successful. \e[0m\n" >&2
|
printf "\e[91m++++ ++++ ++++ ++++ ++++ ++++ ++ ❌ 'aideinit' NOT successful. \e[0m\n" >&2
|
||||||
|
|
||||||
fi
|
fi
|
||||||
|
|
||||||
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ '%s' applied successfully. \e[0m\n" "${0}"
|
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ '%s' applied successfully. \e[0m\n" "${0}"
|
||||||
# sleep 1
|
|
||||||
|
|
||||||
exit 0
|
exit 0
|
||||||
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=sh
|
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=sh
|
||||||
|
|||||||
@@ -1,40 +1,42 @@
|
|||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
# SPDX-Version: 3.0
|
# SPDX-Version: 3.0
|
||||||
# SPDX-CreationInfo: 2025-05-05; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-CreationInfo: 2025-10-11; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
||||||
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
# SPDX-FileCopyrightText: 2024–2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-FileType: SOURCE
|
# SPDX-FileType: SOURCE
|
||||||
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
# SPDX-LicenseComment: This file is part of the CISS.hardened.installer framework.
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
# SPDX-PackageName: CISS.debian.live.builder
|
# SPDX-PackageName: CISS.debian.live.builder
|
||||||
# SPDX-Security-Contact: security@coresecret.eu
|
# SPDX-Security-Contact: security@coresecret.eu
|
||||||
|
|
||||||
### NIST recommends at least eight characters but advises longer passphrases (e.g., 12–64) for increased security.
|
### NIST recommends at least eight characters but advises longer passphrases (e.g., 12-64) for increased security.
|
||||||
### NIST SP 800–63B, https://pages.nist.gov/800-63-3/sp800-63b.html
|
### NIST SP 800-63B, https://pages.nist.gov/800-63-3/sp800-63b.html
|
||||||
|
|
||||||
set -C -e -u -o pipefail
|
set -Ceuo pipefail
|
||||||
|
|
||||||
printf "\e[95m++++ ++++ ++++ ++++ ++++ ++++ ++ 🧪 '%s' starting ... \e[0m\n" "${0}"
|
printf "\e[95m++++ ++++ ++++ ++++ ++++ ++++ ++ 🧪 '%s' starting ... \e[0m\n" "${0}"
|
||||||
# sleep 1
|
|
||||||
|
# shellcheck disable=SC2155
|
||||||
|
declare -r VAR_DATE="$(date +%F)"
|
||||||
|
|
||||||
cp -a /etc/security/pwquality.conf /root/.ciss/dlb/backup/pwquality.conf.bak
|
cp -a /etc/security/pwquality.conf /root/.ciss/dlb/backup/pwquality.conf.bak
|
||||||
chmod 0644 /root/.ciss/dlb/backup/pwquality.conf.bak
|
chmod 0644 /root/.ciss/dlb/backup/pwquality.conf.bak
|
||||||
|
|
||||||
cat << 'EOF' >| /etc/security/pwquality.conf
|
cat << EOF >| /etc/security/pwquality.conf
|
||||||
# SPDX-Version: 3.0
|
# SPDX-Version: 3.0
|
||||||
# SPDX-CreationInfo: 2025-05-05; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-CreationInfo: ${VAR_DATE}; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
||||||
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
# SPDX-FileCopyrightText: 2024–2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-FileType: SOURCE
|
# SPDX-FileType: SOURCE
|
||||||
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
# SPDX-LicenseComment: This file is part of the CISS.hardened.installer framework.
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
# SPDX-PackageName: CISS.debian.live.builder
|
# SPDX-PackageName: CISS.debian.live.builder
|
||||||
# SPDX-Security-Contact: security@coresecret.eu
|
# SPDX-Security-Contact: security@coresecret.eu
|
||||||
|
|
||||||
### Current recommendations for '/etc/security/pwquality.conf' based on common best practices,
|
### Current recommendations for '/etc/security/pwquality.conf' based on common best practices,
|
||||||
### including NIST SP 800–63B, https://pages.nist.gov/800-63-3/sp800-63b.html
|
### including NIST SP 800-63B, https://pages.nist.gov/800-63-3/sp800-63b.html
|
||||||
### and weighing usability against security.
|
### and weighing usability against security.
|
||||||
|
|
||||||
### Configuration for systemwide password quality limits
|
### Configuration for systemwide password quality limits
|
||||||
@@ -46,16 +48,16 @@ difok = 4
|
|||||||
|
|
||||||
### Length over complexity: Studies show that longer passphrases are significantly more
|
### Length over complexity: Studies show that longer passphrases are significantly more
|
||||||
### resistant to brute-force and dictionary attacks. NIST recommends at least eight characters
|
### resistant to brute-force and dictionary attacks. NIST recommends at least eight characters
|
||||||
### but advises longer passphrases (e.g., 12–64) for increased security. Twenty characters strike a
|
### but advises longer passphrases (e.g., 12-64) for increased security. Twenty characters strike a
|
||||||
### good balance between security and user convenience.
|
### good balance between security and user convenience.
|
||||||
### Minimum acceptable size for the new password (plus one if
|
### Minimum acceptable size for the new password (plus one if
|
||||||
### credits are not disabled, which is the default). (See pam_cracklib manual.)
|
### credits are not disabled, which is the default). (See pam_cracklib manual.)
|
||||||
### Cannot be set to a lower value than 6.
|
### Cannot be set to a lower value than 6.
|
||||||
minlen = 20
|
minlen = 40
|
||||||
|
|
||||||
### dcredit = 0, ucredit = 0, lcredit = 0, ocredit = 0, minclass = 0
|
### dcredit = 0, ucredit = 0, lcredit = 0, ocredit = 0, minclass = 0
|
||||||
### NIST SP 800–63B advises against rigid complexity rules (numbers, symbols, uppercase)
|
### NIST SP 800-63B advises against rigid complexity rules (numbers, symbols, uppercase)
|
||||||
### because they can lead users to adopt predictable patterns (e.g., “Pa$$word!”).
|
### because they can lead users to adopt predictable patterns (e.g., "Pa$$word!").
|
||||||
### Length and dictionary checks are more effective.
|
### Length and dictionary checks are more effective.
|
||||||
|
|
||||||
### The maximum credit for having digits in the new password. If less than 0
|
### The maximum credit for having digits in the new password. If less than 0
|
||||||
@@ -83,12 +85,12 @@ minlen = 20
|
|||||||
|
|
||||||
### The maximum number of allowed consecutive same characters in the new password.
|
### The maximum number of allowed consecutive same characters in the new password.
|
||||||
### The check is disabled if the value is 0.
|
### The check is disabled if the value is 0.
|
||||||
maxrepeat = 2
|
maxrepeat = 3
|
||||||
|
|
||||||
### The maximum number of allowed consecutive characters of the same class in the
|
### The maximum number of allowed consecutive characters of the same class in the
|
||||||
### new password.
|
### new password.
|
||||||
### The check is disabled if the value is 0.
|
### The check is disabled if the value is 0.
|
||||||
maxclassrepeat = 4
|
maxclassrepeat = 0
|
||||||
|
|
||||||
### Whether to check for the words from the passwd entry GECOS string of the user.
|
### Whether to check for the words from the passwd entry GECOS string of the user.
|
||||||
### The check is enabled if the value is not 0.
|
### The check is enabled if the value is not 0.
|
||||||
@@ -129,7 +131,6 @@ local_users_only
|
|||||||
EOF
|
EOF
|
||||||
|
|
||||||
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ '%s' applied successfully. \e[0m\n" "${0}"
|
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ '%s' applied successfully. \e[0m\n" "${0}"
|
||||||
# sleep 1
|
|
||||||
|
|
||||||
exit 0
|
exit 0
|
||||||
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=sh
|
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=sh
|
||||||
|
|||||||
@@ -1,23 +1,21 @@
|
|||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
# SPDX-Version: 3.0
|
# SPDX-Version: 3.0
|
||||||
# SPDX-CreationInfo: 2025-05-05; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-CreationInfo: 2025-10-11; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
||||||
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
# SPDX-FileCopyrightText: 2024–2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-FileType: SOURCE
|
# SPDX-FileType: SOURCE
|
||||||
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
# SPDX-LicenseComment: This file is part of the CISS.hardened.installer framework.
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
# SPDX-PackageName: CISS.debian.live.builder
|
# SPDX-PackageName: CISS.debian.live.builder
|
||||||
# SPDX-Security-Contact: security@coresecret.eu
|
# SPDX-Security-Contact: security@coresecret.eu
|
||||||
set -C -e -u -o pipefail
|
set -Ceuo pipefail
|
||||||
|
|
||||||
printf "\e[95m++++ ++++ ++++ ++++ ++++ ++++ ++ 🧪 '%s' starting ... \e[0m\n" "${0}"
|
printf "\e[95m++++ ++++ ++++ ++++ ++++ ++++ ++ 🧪 '%s' starting ... \e[0m\n" "${0}"
|
||||||
# sleep 1
|
|
||||||
|
|
||||||
sed -i 's#^\(ENABLED=\).*#\1"true"#' /etc/default/sysstat
|
sed -i 's#^\(ENABLED=\).*#\1"true"#' /etc/default/sysstat
|
||||||
|
|
||||||
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ '%s' applied successfully. \e[0m\n" "${0}"
|
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ '%s' applied successfully. \e[0m\n" "${0}"
|
||||||
# sleep 1
|
|
||||||
|
|
||||||
exit 0
|
exit 0
|
||||||
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=sh
|
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=sh
|
||||||
|
|||||||
@@ -1,25 +1,32 @@
|
|||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
# SPDX-Version: 3.0
|
# SPDX-Version: 3.0
|
||||||
# SPDX-CreationInfo: 2025-05-05; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-CreationInfo: 2025-10-11; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
||||||
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
# SPDX-FileCopyrightText: 2024–2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-FileType: SOURCE
|
# SPDX-FileType: SOURCE
|
||||||
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
# SPDX-LicenseComment: This file is part of the CISS.hardened.installer framework.
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
# SPDX-PackageName: CISS.debian.live.builder
|
# SPDX-PackageName: CISS.debian.live.builder
|
||||||
# SPDX-Security-Contact: security@coresecret.eu
|
# SPDX-Security-Contact: security@coresecret.eu
|
||||||
|
|
||||||
### https://github.com/linux-audit/audit-userspace/tree/master/rules
|
### https://github.com/linux-audit/audit-userspace/tree/master/rules
|
||||||
|
|
||||||
set -C -e -u -o pipefail
|
set -Ceuo pipefail
|
||||||
|
|
||||||
|
#######################################
|
||||||
|
# Simple error terminal logger.
|
||||||
|
# Arguments:
|
||||||
|
# None
|
||||||
|
#######################################
|
||||||
|
log() { printf '[auditd-build] %s\n' "${*}" >&2; }
|
||||||
|
|
||||||
printf "\e[95m++++ ++++ ++++ ++++ ++++ ++++ ++ 🧪 '%s' starting ... \e[0m\n" "${0}"
|
printf "\e[95m++++ ++++ ++++ ++++ ++++ ++++ ++ 🧪 '%s' starting ... \e[0m\n" "${0}"
|
||||||
# sleep 1
|
|
||||||
|
|
||||||
cd /root
|
cd /root
|
||||||
|
|
||||||
apt-get install auditd -y
|
export DEBIAN_FRONTEND="noninteractive"
|
||||||
|
apt-get install -y auditd
|
||||||
|
|
||||||
cp -u /etc/audit/audit.rules /root/.ciss/dlb/backup/audit.rules.bak
|
cp -u /etc/audit/audit.rules /root/.ciss/dlb/backup/audit.rules.bak
|
||||||
cp -u /etc/audit/auditd.conf /root/.ciss/dlb/backup/auditd.conf.bak
|
cp -u /etc/audit/auditd.conf /root/.ciss/dlb/backup/auditd.conf.bak
|
||||||
@@ -50,13 +57,18 @@ EOF
|
|||||||
############################################################### /etc/audit/rules.d/20-dont-audit.rules
|
############################################################### /etc/audit/rules.d/20-dont-audit.rules
|
||||||
cat << EOF >| /etc/audit/rules.d/20-dont-audit.rules
|
cat << EOF >| /etc/audit/rules.d/20-dont-audit.rules
|
||||||
## This is for don't audit rules. We put these early because audit
|
## This is for don't audit rules. We put these early because audit
|
||||||
### is a first match wins system. Uncomment the rules you want.
|
## is a first match wins system. Uncomment the rules you want.
|
||||||
|
|
||||||
## Cron jobs fill the logs with stuff we normally don't want
|
## Cron jobs fill the logs with stuff we normally don't want
|
||||||
-a never,user -F subj_type=crond_t
|
-a never,user
|
||||||
|
|
||||||
## This prevents chrony from overwhelming the logs
|
## This prevents chrony from overwhelming the logs
|
||||||
-a never,exit -F arch=x86_64 -S adjtimex -F auid=unset -F uid=chrony -F subj_type=chronyd_t
|
-a never,exit -F arch=b64 -S adjtimex -F exe=/usr/sbin/chronyd
|
||||||
|
-a never,exit -F arch=b32 -S adjtimex -F exe=/usr/sbin/chronyd
|
||||||
|
|
||||||
|
## Human-attributable time changes
|
||||||
|
-a always,exit -F arch=b64 -S adjtimex -S settimeofday -S clock_settime -F auid>=1000 -F auid!=4294967295 -k time-change
|
||||||
|
-a always,exit -F arch=b32 -S adjtimex -S settimeofday -S clock_settime -F auid>=1000 -F auid!=4294967295 -k time-change
|
||||||
|
|
||||||
### This is not very interesting and wastes a lot of space if
|
### This is not very interesting and wastes a lot of space if
|
||||||
### the server is public facing
|
### the server is public facing
|
||||||
@@ -75,8 +87,8 @@ EOF
|
|||||||
############################################################### /etc/audit/rules.d/22-ignore-chrony.rules
|
############################################################### /etc/audit/rules.d/22-ignore-chrony.rules
|
||||||
cat << EOF >| /etc/audit/rules.d/22-ignore-chrony.rules
|
cat << EOF >| /etc/audit/rules.d/22-ignore-chrony.rules
|
||||||
## This rule suppresses the time-change event when chrony does time updates
|
## This rule suppresses the time-change event when chrony does time updates
|
||||||
-a never,exit -F arch=b64 -S adjtimex -F auid=unset -F uid=chrony -F subj_type=chronyd_t
|
-a never,exit -F arch=b64 -S adjtimex -F auid=unset -F uid=_chrony
|
||||||
-a never,exit -F arch=b32 -S adjtimex -F auid=unset -F uid=chrony -F subj_type=chronyd_t
|
-a never,exit -F arch=b32 -S adjtimex -F auid=unset -F uid=_chrony
|
||||||
EOF
|
EOF
|
||||||
|
|
||||||
############################################################### /etc/audit/rules.d/30-ospp-v42-1-create-failed.rules
|
############################################################### /etc/audit/rules.d/30-ospp-v42-1-create-failed.rules
|
||||||
@@ -325,8 +337,65 @@ cat << EOF >| /etc/audit/rules.d/99-finalize.rules
|
|||||||
-e 2
|
-e 2
|
||||||
EOF
|
EOF
|
||||||
|
|
||||||
|
shopt -s nullglob
|
||||||
|
rules=(/etc/audit/rules.d/*.rules)
|
||||||
|
if (( ${#rules[@]} == 0 )); then
|
||||||
|
log "ERROR: /etc/audit/rules.d is empty. Seed rules before this hook."
|
||||||
|
exit 127
|
||||||
|
fi
|
||||||
|
|
||||||
|
if ! /sbin/augenrules --check >/dev/null 2>&1; then
|
||||||
|
log "ERROR: augenrules --check failed. Fix the /etc/audit/rules.d/*.rules first."
|
||||||
|
exit 128
|
||||||
|
fi
|
||||||
|
|
||||||
|
# shellcheck disable=2155
|
||||||
|
declare tmp="$(mktemp)"
|
||||||
|
printf '%s\0' "${rules[@]}" \
|
||||||
|
| xargs -0 -I{} basename "{}" \
|
||||||
|
| sort -V \
|
||||||
|
| while read -r fname; do
|
||||||
|
f="/etc/audit/rules.d/${fname}"
|
||||||
|
### Normalize CRLF and strip UTF-8 BOM.
|
||||||
|
sed -e 's/\r$//' -e '1s/^\xEF\xBB\xBF//' "${f}" >> "${tmp}"
|
||||||
|
printf '\n' >> "${tmp}"
|
||||||
|
done
|
||||||
|
|
||||||
|
# shellcheck disable=2155
|
||||||
|
declare tmp_stripped="$(mktemp)"
|
||||||
|
sed -e '/^[[:space:]]*#/d' -e '/^[[:space:]]*$/d' "${tmp}" >| "${tmp_stripped}"
|
||||||
|
sed -E 's/[[:space:]]+#.*$//' -i "${tmp_stripped}"
|
||||||
|
|
||||||
|
install -m 0600 -o root -g root "${tmp_stripped}" /etc/audit/audit.rules
|
||||||
|
rm -f "${tmp}" "${tmp_stripped}"
|
||||||
|
|
||||||
|
if ! grep -Eq '(^-a|^-w|^-e[[:space:]]+1|^-e[[:space:]]+2)' /etc/audit/audit.rules; then
|
||||||
|
log "WARN: /etc/audit/audit.rules contains no -a/-w rules or '-e 1/2'; is this intended?"
|
||||||
|
fi
|
||||||
|
|
||||||
|
log "Done. /etc/audit/audit.rules generated at build-time (no kernel load)."
|
||||||
|
|
||||||
|
mkdir -p /etc/systemd/system/audit-rules.service.d
|
||||||
|
|
||||||
|
cat << EOF >| /etc/systemd/system/audit-rules.service.d/10-ciss.conf
|
||||||
|
# SPDX-Version: 3.0
|
||||||
|
# SPDX-CreationInfo: 2025-10-11; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
|
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
||||||
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
|
# SPDX-FileType: SOURCE
|
||||||
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
|
# SPDX-PackageName: CISS.debian.live.builder
|
||||||
|
# SPDX-Security-Contact: security@coresecret.eu
|
||||||
|
|
||||||
|
[Service]
|
||||||
|
ExecStart=
|
||||||
|
ExecStart=/usr/sbin/augenrules --load
|
||||||
|
|
||||||
|
EOF
|
||||||
|
|
||||||
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ '%s' applied successfully. \e[0m\n" "${0}"
|
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ '%s' applied successfully. \e[0m\n" "${0}"
|
||||||
# sleep 1
|
|
||||||
|
|
||||||
exit 0
|
exit 0
|
||||||
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=sh
|
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=sh
|
||||||
|
|||||||
@@ -1,36 +1,39 @@
|
|||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
# SPDX-Version: 3.0
|
# SPDX-Version: 3.0
|
||||||
# SPDX-CreationInfo: 2025-05-05; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-CreationInfo: 2025-10-11; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
||||||
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
# SPDX-FileCopyrightText: 2024–2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-FileType: SOURCE
|
# SPDX-FileType: SOURCE
|
||||||
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
# SPDX-PackageName: CISS.debian.live.builder
|
# SPDX-PackageName: CISS.debian.live.builder
|
||||||
# SPDX-Security-Contact: security@coresecret.eu
|
# SPDX-Security-Contact: security@coresecret.eu
|
||||||
set -C -e -u -o pipefail
|
set -Ceuo pipefail
|
||||||
|
|
||||||
printf "\e[95m++++ ++++ ++++ ++++ ++++ ++++ ++ 🧪 '%s' starting ... \e[0m\n" "${0}"
|
printf "\e[95m++++ ++++ ++++ ++++ ++++ ++++ ++ 🧪 '%s' starting ... \e[0m\n" "${0}"
|
||||||
# sleep 1
|
|
||||||
|
|
||||||
cd /root
|
cd /root
|
||||||
|
|
||||||
apt-get install --no-install-recommends debsums -y
|
export DEBIAN_FRONTEND="noninteractive"
|
||||||
|
apt-get install -y --no-install-recommends debsums
|
||||||
|
|
||||||
cp -a /etc/default/debsums /root/.ciss/dlb/backup/debsums.bak
|
cp -a /etc/default/debsums /root/.ciss/dlb/backup/debsums.bak
|
||||||
chmod 0644 /root/.ciss/dlb/backup/debsums.bak
|
chmod 0644 /root/.ciss/dlb/backup/debsums.bak
|
||||||
sed -i "s/CRON_CHECK=never/CRON_CHECK=monthly/" /etc/default/debsums
|
sed -i "s/CRON_CHECK=never/CRON_CHECK=monthly/" /etc/default/debsums
|
||||||
|
|
||||||
if debsums -g; then
|
if debsums -g > /dev/null 2>&1; then
|
||||||
|
|
||||||
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ 'debsums -g' successful. \e[0m\n"
|
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ 'debsums -g' successful. \e[0m\n"
|
||||||
|
|
||||||
else
|
else
|
||||||
|
|
||||||
# Omit false negative error output to stdout and stderr, as no problematic errors occur on startup.
|
# Omit false negative error output to stdout and stderr, as no problematic errors occur on startup.
|
||||||
printf "\e[91m++++ ++++ ++++ ++++ ++++ ++++ ++ ❌ 'debsums -g' NOT successful. \e[0m\n" > /dev/null 2>&1
|
printf "\e[91m++++ ++++ ++++ ++++ ++++ ++++ ++ ❌ 'debsums -g' NOT successful. \e[0m\n" > /dev/null 2>&1
|
||||||
|
|
||||||
fi
|
fi
|
||||||
|
|
||||||
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ '%s' applied successfully. \e[0m\n" "${0}"
|
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ '%s' applied successfully. \e[0m\n" "${0}"
|
||||||
# sleep 1
|
|
||||||
|
|
||||||
exit 0
|
exit 0
|
||||||
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=sh
|
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=sh
|
||||||
@@ -1,18 +1,20 @@
|
|||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
# SPDX-Version: 3.0
|
# SPDX-Version: 3.0
|
||||||
# SPDX-CreationInfo: 2025-05-05; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-CreationInfo: 2025-10-11; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
||||||
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
# SPDX-FileCopyrightText: 2024–2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-FileType: SOURCE
|
# SPDX-FileType: SOURCE
|
||||||
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
# SPDX-LicenseComment: This file is part of the CISS.hardened.installer framework.
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
# SPDX-PackageName: CISS.debian.live.builder
|
# SPDX-PackageName: CISS.debian.live.builder
|
||||||
# SPDX-Security-Contact: security@coresecret.eu
|
# SPDX-Security-Contact: security@coresecret.eu
|
||||||
set -C -e -u -o pipefail
|
set -Ceuo pipefail
|
||||||
|
|
||||||
printf "\e[95m++++ ++++ ++++ ++++ ++++ ++++ ++ 🧪 '%s' starting ... \e[0m\n" "${0}"
|
printf "\e[95m++++ ++++ ++++ ++++ ++++ ++++ ++ 🧪 '%s' starting ... \e[0m\n" "${0}"
|
||||||
# sleep 1
|
|
||||||
|
# shellcheck disable=SC2155
|
||||||
|
declare -r VAR_DATE="$(date +%F)"
|
||||||
|
|
||||||
cd /root
|
cd /root
|
||||||
|
|
||||||
@@ -22,14 +24,14 @@ fi
|
|||||||
|
|
||||||
cat << 'EOF' >| /etc/apt/sources.list
|
cat << 'EOF' >| /etc/apt/sources.list
|
||||||
# SPDX-Version: 3.0
|
# SPDX-Version: 3.0
|
||||||
# SPDX-CreationInfo: 2025-05-05; WEIDNER, Marc S.; <cendev@coresecret.eu>
|
# SPDX-CreationInfo: ${VAR_DATE}; WEIDNER, Marc S.; <cendev@coresecret.eu>
|
||||||
# SPDX-ExternalRef: GIT https://cendev.eu/marc.weidner/CISS.2025.debian.live.builder.git
|
# SPDX-ExternalRef: GIT https://cendev.eu/marc.weidner/CISS.2025.debian.live.builder.git
|
||||||
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
# SPDX-FileCopyrightText: 2024–2025; WEIDNER, Marc S.; <cendev@coresecret.eu>
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <cendev@coresecret.eu>
|
||||||
# SPDX-FileType: SOURCE
|
# SPDX-FileType: SOURCE
|
||||||
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
# SPDX-LicenseComment: This file is part of the CISS.2025.hardened.installer framework.
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
# SPDX-PackageName: CISS.2025.debian.live.builder
|
# SPDX-PackageName: CISS.debian.live.builder
|
||||||
# SPDX-Security-Contact: security@coresecret.eu
|
# SPDX-Security-Contact: security@coresecret.eu
|
||||||
#-----------------------------------------------------------------------------------------#
|
#-----------------------------------------------------------------------------------------#
|
||||||
# OFFICIAL DEBIAN REPOS
|
# OFFICIAL DEBIAN REPOS
|
||||||
127
config/hooks/live/9998_sources_list_trixie.chroot
Normal file
127
config/hooks/live/9998_sources_list_trixie.chroot
Normal file
@@ -0,0 +1,127 @@
|
|||||||
|
#!/bin/bash
|
||||||
|
# SPDX-Version: 3.0
|
||||||
|
# SPDX-CreationInfo: 2025-08-12; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
|
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
||||||
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
|
# SPDX-FileType: SOURCE
|
||||||
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
|
# SPDX-PackageName: CISS.debian.live.builder
|
||||||
|
# SPDX-Security-Contact: security@coresecret.eu
|
||||||
|
set -Ceuo pipefail
|
||||||
|
|
||||||
|
printf "\e[95m++++ ++++ ++++ ++++ ++++ ++++ ++ 🧪 '%s' starting ... \e[0m\n" "${0}"
|
||||||
|
|
||||||
|
# shellcheck disable=SC2155
|
||||||
|
declare -r VAR_DATE="$(date +%F)"
|
||||||
|
|
||||||
|
cd /root
|
||||||
|
|
||||||
|
mkdir -p /etc/apt/apt.conf.d
|
||||||
|
|
||||||
|
cat << EOF >| /etc/apt/apt.conf.d/00-deb822-prefer
|
||||||
|
// Make APT ignore the classic /etc/apt/sources.list entirely.
|
||||||
|
Dir::Etc {
|
||||||
|
sourcelist "/dev/null"; // classic list is ignored
|
||||||
|
sourceparts "/etc/apt/sources.list.d"; // deb822 *.sources remain authoritative
|
||||||
|
}
|
||||||
|
EOF
|
||||||
|
|
||||||
|
if [[ ! -f /etc/apt/sources.list.d/trixie.sources ]]; then
|
||||||
|
cat << EOF >| /etc/apt/sources.list.d/trixie.sources
|
||||||
|
# SPDX-Version: 3.0
|
||||||
|
# SPDX-CreationInfo: ${VAR_DATE}; WEIDNER, Marc S.; <cendev@coresecret.eu>
|
||||||
|
# SPDX-ExternalRef: GIT https://cendev.eu/marc.weidner/CISS.2025.debian.live.builder.git
|
||||||
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <cendev@coresecret.eu>
|
||||||
|
# SPDX-FileType: SOURCE
|
||||||
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
|
# SPDX-PackageName: CISS.debian.live.builder
|
||||||
|
# SPDX-Security-Contact: security@coresecret.eu
|
||||||
|
|
||||||
|
Types: deb deb-src
|
||||||
|
URIs: https://deb.debian.org/debian/
|
||||||
|
Suites: trixie
|
||||||
|
Components: main contrib non-free non-free-firmware
|
||||||
|
Signed-By: /usr/share/keyrings/debian-archive-keyring.gpg
|
||||||
|
|
||||||
|
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=conf
|
||||||
|
EOF
|
||||||
|
fi
|
||||||
|
|
||||||
|
if [[ ! -f /etc/apt/sources.list.d/trixie-security.sources ]]; then
|
||||||
|
cat << EOF >| /etc/apt/sources.list.d/trixie-security.sources
|
||||||
|
# SPDX-Version: 3.0
|
||||||
|
# SPDX-CreationInfo: ${VAR_DATE}; WEIDNER, Marc S.; <cendev@coresecret.eu>
|
||||||
|
# SPDX-ExternalRef: GIT https://cendev.eu/marc.weidner/CISS.2025.debian.live.builder.git
|
||||||
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <cendev@coresecret.eu>
|
||||||
|
# SPDX-FileType: SOURCE
|
||||||
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
|
# SPDX-PackageName: CISS.debian.live.builder
|
||||||
|
# SPDX-Security-Contact: security@coresecret.eu
|
||||||
|
|
||||||
|
Types: deb deb-src
|
||||||
|
URIs: https://security.debian.org/debian-security/
|
||||||
|
Suites: trixie-security
|
||||||
|
Components: main contrib non-free non-free-firmware
|
||||||
|
Signed-By: /usr/share/keyrings/debian-archive-keyring.gpg
|
||||||
|
|
||||||
|
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=conf
|
||||||
|
EOF
|
||||||
|
fi
|
||||||
|
|
||||||
|
if [[ ! -f /etc/apt/sources.list.d/trixie-updates.sources ]]; then
|
||||||
|
cat << EOF >| /etc/apt/sources.list.d/trixie-updates.sources
|
||||||
|
# SPDX-Version: 3.0
|
||||||
|
# SPDX-CreationInfo: ${VAR_DATE}; WEIDNER, Marc S.; <cendev@coresecret.eu>
|
||||||
|
# SPDX-ExternalRef: GIT https://cendev.eu/marc.weidner/CISS.2025.debian.live.builder.git
|
||||||
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <cendev@coresecret.eu>
|
||||||
|
# SPDX-FileType: SOURCE
|
||||||
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
|
# SPDX-PackageName: CISS.debian.live.builder
|
||||||
|
# SPDX-Security-Contact: security@coresecret.eu
|
||||||
|
|
||||||
|
Types: deb deb-src
|
||||||
|
URIs: https://deb.debian.org/debian/
|
||||||
|
Suites: trixie-updates
|
||||||
|
Components: main contrib non-free non-free-firmware
|
||||||
|
Signed-By: /usr/share/keyrings/debian-archive-keyring.gpg
|
||||||
|
|
||||||
|
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=conf
|
||||||
|
EOF
|
||||||
|
fi
|
||||||
|
|
||||||
|
|
||||||
|
if [[ ! -f /etc/apt/sources.list.d/trixie-backports.sources ]]; then
|
||||||
|
cat << EOF >| /etc/apt/sources.list.d/trixie-backports.sources
|
||||||
|
# SPDX-Version: 3.0
|
||||||
|
# SPDX-CreationInfo: ${VAR_DATE}; WEIDNER, Marc S.; <cendev@coresecret.eu>
|
||||||
|
# SPDX-ExternalRef: GIT https://cendev.eu/marc.weidner/CISS.2025.debian.live.builder.git
|
||||||
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <cendev@coresecret.eu>
|
||||||
|
# SPDX-FileType: SOURCE
|
||||||
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
|
# SPDX-PackageName: CISS.debian.live.builder
|
||||||
|
# SPDX-Security-Contact: security@coresecret.eu
|
||||||
|
|
||||||
|
Types: deb deb-src
|
||||||
|
URIs: https://deb.debian.org/debian/
|
||||||
|
Suites: trixie-backports
|
||||||
|
Components: main contrib non-free non-free-firmware
|
||||||
|
Signed-By: /usr/share/keyrings/debian-archive-keyring.gpg
|
||||||
|
|
||||||
|
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=conf
|
||||||
|
EOF
|
||||||
|
fi
|
||||||
|
|
||||||
|
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ '%s' applied successfully. \e[0m\n" "${0}"
|
||||||
|
|
||||||
|
exit 0
|
||||||
|
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=sh
|
||||||
@@ -1,28 +1,30 @@
|
|||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
# SPDX-Version: 3.0
|
# SPDX-Version: 3.0
|
||||||
# SPDX-CreationInfo: 2025-05-05; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-CreationInfo: 2025-10-11; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
||||||
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
# SPDX-FileCopyrightText: 2024–2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-FileType: SOURCE
|
# SPDX-FileType: SOURCE
|
||||||
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
# SPDX-PackageName: CISS.debian.live.builder
|
# SPDX-PackageName: CISS.debian.live.builder
|
||||||
# SPDX-Security-Contact: security@coresecret.eu
|
# SPDX-Security-Contact: security@coresecret.eu
|
||||||
set -C -e -u -o pipefail
|
set -Ceuo pipefail
|
||||||
|
|
||||||
printf "\e[95m++++ ++++ ++++ ++++ ++++ ++++ ++ 🧪 '%s' starting ... \e[0m\n" "${0}"
|
printf "\e[95m++++ ++++ ++++ ++++ ++++ ++++ ++ 🧪 '%s' starting ... \e[0m\n" "${0}"
|
||||||
# sleep 1
|
|
||||||
|
# shellcheck disable=SC2155
|
||||||
|
declare -r VAR_DATE="$(date +%F)"
|
||||||
|
|
||||||
mv /etc/network/interfaces /root/.ciss/dlb/backup/interfaces.chroot
|
mv /etc/network/interfaces /root/.ciss/dlb/backup/interfaces.chroot
|
||||||
rm -f /etc/network/interfaces
|
rm -f /etc/network/interfaces
|
||||||
|
|
||||||
cat << 'EOF' >| /etc/network/interfaces
|
cat << EOF >| /etc/network/interfaces
|
||||||
# SPDX-Version: 3.0
|
# SPDX-Version: 3.0
|
||||||
# SPDX-CreationInfo: 2025-05-05; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-CreationInfo: ${VAR_DATE}; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
||||||
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
# SPDX-FileCopyrightText: 2024–2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-FileType: SOURCE
|
# SPDX-FileType: SOURCE
|
||||||
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
@@ -32,6 +34,9 @@ cat << 'EOF' >| /etc/network/interfaces
|
|||||||
# This file describes the network interfaces available on your system
|
# This file describes the network interfaces available on your system
|
||||||
# and how to activate them. For more information, see interfaces(5).
|
# and how to activate them. For more information, see interfaces(5).
|
||||||
|
|
||||||
|
EOF
|
||||||
|
|
||||||
|
cat << 'EOF' >> /etc/network/interfaces
|
||||||
### The loopback network interface
|
### The loopback network interface
|
||||||
auto lo
|
auto lo
|
||||||
iface lo inet loopback
|
iface lo inet loopback
|
||||||
@@ -59,7 +64,6 @@ EOF
|
|||||||
chmod 0644 /etc/network/interfaces
|
chmod 0644 /etc/network/interfaces
|
||||||
|
|
||||||
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ '%s' applied successfully. \e[0m\n" "${0}"
|
printf "\e[92m++++ ++++ ++++ ++++ ++++ ++++ ++ ✅ '%s' applied successfully. \e[0m\n" "${0}"
|
||||||
# sleep 1
|
|
||||||
|
|
||||||
exit 0
|
exit 0
|
||||||
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=sh
|
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=sh
|
||||||
@@ -2,10 +2,10 @@
|
|||||||
# SPDX-CreationInfo: 2025-05-05; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-CreationInfo: 2025-05-05; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
||||||
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
# SPDX-FileCopyrightText: 2024–2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-FileType: SOURCE
|
# SPDX-FileType: SOURCE
|
||||||
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
# SPDX-LicenseComment: This file is part of the CISS.hardened.installer framework.
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
# SPDX-PackageName: CISS.debian.live.builder
|
# SPDX-PackageName: CISS.debian.live.builder
|
||||||
# SPDX-Security-Contact: security@coresecret.eu
|
# SPDX-Security-Contact: security@coresecret.eu
|
||||||
|
|
||||||
|
|||||||
15
config/includes.chroot/etc/apt/sources.list
Normal file
15
config/includes.chroot/etc/apt/sources.list
Normal file
@@ -0,0 +1,15 @@
|
|||||||
|
# SPDX-Version: 3.0
|
||||||
|
# SPDX-CreationInfo: 2025-08-12; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
|
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
||||||
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
|
# SPDX-FileType: SOURCE
|
||||||
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
|
# SPDX-PackageName: CISS.debian.live.builder
|
||||||
|
# SPDX-Security-Contact: security@coresecret.eu
|
||||||
|
|
||||||
|
# File: /etc/apt/sources.list
|
||||||
|
# Intentionally empty, disable classic sources.list generation (deb822 in use).
|
||||||
|
|
||||||
|
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=conf
|
||||||
@@ -0,0 +1,18 @@
|
|||||||
|
# SPDX-Version: 3.0
|
||||||
|
# SPDX-CreationInfo: 2025-08-11; WEIDNER, Marc S.; <cendev@coresecret.eu>
|
||||||
|
# SPDX-ExternalRef: GIT https://cendev.eu/marc.weidner/CISS.2025.debian.live.builder.git
|
||||||
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <cendev@coresecret.eu>
|
||||||
|
# SPDX-FileType: SOURCE
|
||||||
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
|
# SPDX-PackageName: CISS.debian.live.builder
|
||||||
|
# SPDX-Security-Contact: security@coresecret.eu
|
||||||
|
|
||||||
|
Types: deb deb-src
|
||||||
|
URIs: https://deb.debian.org/debian/
|
||||||
|
Suites: trixie-backports
|
||||||
|
Components: main contrib non-free non-free-firmware
|
||||||
|
Signed-By: /usr/share/keyrings/debian-archive-keyring.gpg
|
||||||
|
|
||||||
|
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=conf
|
||||||
@@ -0,0 +1,18 @@
|
|||||||
|
# SPDX-Version: 3.0
|
||||||
|
# SPDX-CreationInfo: 2025-08-11; WEIDNER, Marc S.; <cendev@coresecret.eu>
|
||||||
|
# SPDX-ExternalRef: GIT https://cendev.eu/marc.weidner/CISS.2025.debian.live.builder.git
|
||||||
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <cendev@coresecret.eu>
|
||||||
|
# SPDX-FileType: SOURCE
|
||||||
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
|
# SPDX-PackageName: CISS.debian.live.builder
|
||||||
|
# SPDX-Security-Contact: security@coresecret.eu
|
||||||
|
|
||||||
|
Types: deb deb-src
|
||||||
|
URIs: https://security.debian.org/debian-security/
|
||||||
|
Suites: trixie-security
|
||||||
|
Components: main contrib non-free non-free-firmware
|
||||||
|
Signed-By: /usr/share/keyrings/debian-archive-keyring.gpg
|
||||||
|
|
||||||
|
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=conf
|
||||||
@@ -0,0 +1,18 @@
|
|||||||
|
# SPDX-Version: 3.0
|
||||||
|
# SPDX-CreationInfo: 2025-08-11; WEIDNER, Marc S.; <cendev@coresecret.eu>
|
||||||
|
# SPDX-ExternalRef: GIT https://cendev.eu/marc.weidner/CISS.2025.debian.live.builder.git
|
||||||
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <cendev@coresecret.eu>
|
||||||
|
# SPDX-FileType: SOURCE
|
||||||
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
|
# SPDX-PackageName: CISS.debian.live.builder
|
||||||
|
# SPDX-Security-Contact: security@coresecret.eu
|
||||||
|
|
||||||
|
Types: deb deb-src
|
||||||
|
URIs: https://deb.debian.org/debian/
|
||||||
|
Suites: trixie-updates
|
||||||
|
Components: main contrib non-free non-free-firmware
|
||||||
|
Signed-By: /usr/share/keyrings/debian-archive-keyring.gpg
|
||||||
|
|
||||||
|
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=conf
|
||||||
18
config/includes.chroot/etc/apt/sources.list.d/trixie.sources
Normal file
18
config/includes.chroot/etc/apt/sources.list.d/trixie.sources
Normal file
@@ -0,0 +1,18 @@
|
|||||||
|
# SPDX-Version: 3.0
|
||||||
|
# SPDX-CreationInfo: 2025-08-11; WEIDNER, Marc S.; <cendev@coresecret.eu>
|
||||||
|
# SPDX-ExternalRef: GIT https://cendev.eu/marc.weidner/CISS.2025.debian.live.builder.git
|
||||||
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <cendev@coresecret.eu>
|
||||||
|
# SPDX-FileType: SOURCE
|
||||||
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
|
# SPDX-PackageName: CISS.debian.live.builder
|
||||||
|
# SPDX-Security-Contact: security@coresecret.eu
|
||||||
|
|
||||||
|
Types: deb deb-src
|
||||||
|
URIs: https://deb.debian.org/debian/
|
||||||
|
Suites: trixie
|
||||||
|
Components: main contrib non-free non-free-firmware
|
||||||
|
Signed-By: /usr/share/keyrings/debian-archive-keyring.gpg
|
||||||
|
|
||||||
|
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=conf
|
||||||
@@ -2,12 +2,13 @@
|
|||||||
# SPDX-CreationInfo: 2025-05-05; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-CreationInfo: 2025-05-05; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
||||||
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
# SPDX-FileCopyrightText: 2024–2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-FileType: SOURCE
|
# SPDX-FileType: SOURCE
|
||||||
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
# SPDX-PackageName: CISS.debian.live.builder
|
# SPDX-PackageName: CISS.debian.live.builder
|
||||||
# SPDX-Security-Contact: security@coresecret.eu
|
# SPDX-Security-Contact: security@coresecret.eu
|
||||||
LIVE_CONFIGS="username"
|
|
||||||
USERNAME=root
|
# LIVE_CONFIG_CMDLINE="${LIVE_CONFIG_CMDLINE} ADD PARAMETER HERE"
|
||||||
|
|
||||||
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=sh
|
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=sh
|
||||||
|
|||||||
209
config/includes.chroot/etc/login.defs
Normal file
209
config/includes.chroot/etc/login.defs
Normal file
@@ -0,0 +1,209 @@
|
|||||||
|
# SPDX-Version: 3.0
|
||||||
|
# SPDX-CreationInfo: 2025-10-11; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
|
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
||||||
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
|
# SPDX-FileType: SOURCE
|
||||||
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
|
# SPDX-PackageName: CISS.debian.live.builder
|
||||||
|
# SPDX-Security-Contact: security@coresecret.eu
|
||||||
|
|
||||||
|
#
|
||||||
|
# /etc/login.defs - Configuration control definitions for the shadow package.
|
||||||
|
#
|
||||||
|
|
||||||
|
# REQUIRED for useradd/userdel/usermod
|
||||||
|
# Directory where mailboxes reside, _or_ name of file, relative to the
|
||||||
|
# home directory. If you _do_ define MAIL_DIR and MAIL_FILE,
|
||||||
|
# MAIL_DIR takes precedence.
|
||||||
|
#
|
||||||
|
# Essentially:
|
||||||
|
# - MAIL_DIR defines the location of users mail spool files
|
||||||
|
# (for mbox use) by appending the username to MAIL_DIR as defined
|
||||||
|
# below.
|
||||||
|
# - MAIL_FILE defines the location of the users mail spool files as the
|
||||||
|
# fully-qualified filename obtained by prepending the user home
|
||||||
|
# directory before $MAIL_FILE
|
||||||
|
#
|
||||||
|
# NOTE: This is no more used for setting up users MAIL environment variable
|
||||||
|
# which is, starting from shadow 4.0.12-1 in Debian, entirely the
|
||||||
|
# job of the pam_mail PAM modules
|
||||||
|
# See default PAM configuration files provided for
|
||||||
|
# login, su, etc.
|
||||||
|
#
|
||||||
|
# This is a temporary situation: setting these variables will soon
|
||||||
|
# move to /etc/default/useradd and the variables will then be
|
||||||
|
# no more supported
|
||||||
|
MAIL_DIR /var/mail
|
||||||
|
#MAIL_FILE .mail
|
||||||
|
|
||||||
|
#
|
||||||
|
# Enable display of unknown usernames when login(1) failures are recorded.
|
||||||
|
#
|
||||||
|
# WARNING: Unknown usernames may become world readable.
|
||||||
|
# See #290803 and #298773 for details about how this could become a security
|
||||||
|
# concern
|
||||||
|
LOG_UNKFAIL_ENAB no
|
||||||
|
|
||||||
|
#
|
||||||
|
# Enable logging of successful logins
|
||||||
|
#
|
||||||
|
LOG_OK_LOGINS yes
|
||||||
|
|
||||||
|
#
|
||||||
|
# If defined, file which maps tty line to TERM environment parameter.
|
||||||
|
# Each line of the file is in a format similar to "vt100 tty01".
|
||||||
|
#
|
||||||
|
#TTYTYPE_FILE /etc/ttytype
|
||||||
|
|
||||||
|
#
|
||||||
|
# If defined, file which inhibits all the usual chatter during the login
|
||||||
|
# sequence. If a full pathname, then hushed mode will be enabled if the
|
||||||
|
# user's name or shell are found in the file. If not a full pathname, then
|
||||||
|
# hushed mode will be enabled if the file exists in the user's home directory.
|
||||||
|
#
|
||||||
|
HUSHLOGIN_FILE .hushlogin
|
||||||
|
#HUSHLOGIN_FILE /etc/hushlogins
|
||||||
|
|
||||||
|
#
|
||||||
|
# *REQUIRED* The default PATH settings, for superuser and normal users.
|
||||||
|
#
|
||||||
|
# (they are minimal, add the rest in the shell startup files)
|
||||||
|
ENV_SUPATH PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin
|
||||||
|
ENV_PATH PATH=/usr/local/bin:/usr/bin:/bin:/usr/local/games:/usr/games
|
||||||
|
|
||||||
|
#
|
||||||
|
# Terminal permissions for terminals after login(1).
|
||||||
|
# These settings are ignored for remote and other logins.
|
||||||
|
#
|
||||||
|
# TTYGROUP Login tty will be assigned this group ownership.
|
||||||
|
# TTYPERM Login tty will be set to this permission.
|
||||||
|
#
|
||||||
|
#TTYGROUP tty
|
||||||
|
TTYPERM 0600
|
||||||
|
|
||||||
|
#
|
||||||
|
# Login configuration initializations:
|
||||||
|
#
|
||||||
|
# ERASECHAR Terminal ERASE character ('\010' = backspace).
|
||||||
|
# KILLCHAR Terminal KILL character ('\025' = CTRL/U).
|
||||||
|
#
|
||||||
|
# The ERASECHAR and KILLCHAR are used only on System V machines.
|
||||||
|
#
|
||||||
|
ERASECHAR 0177
|
||||||
|
KILLCHAR 025
|
||||||
|
|
||||||
|
# HOME_MODE is used by useradd(8) and newusers(8) to set the mode for new
|
||||||
|
# home directories.
|
||||||
|
HOME_MODE 0700
|
||||||
|
|
||||||
|
#
|
||||||
|
# Password aging controls:
|
||||||
|
#
|
||||||
|
# PASS_MAX_DAYS Maximum number of days a password may be used.
|
||||||
|
# PASS_MIN_DAYS Minimum number of days allowed between password changes.
|
||||||
|
# PASS_WARN_AGE Number of days warning given before a password expires.
|
||||||
|
#
|
||||||
|
PASS_MAX_DAYS 16384
|
||||||
|
PASS_MIN_DAYS 1
|
||||||
|
PASS_WARN_AGE 128
|
||||||
|
|
||||||
|
#
|
||||||
|
# Min/max values for automatic uid selection in useradd(8)
|
||||||
|
#
|
||||||
|
UID_MIN 1000
|
||||||
|
UID_MAX 60000
|
||||||
|
# System accounts
|
||||||
|
#SYS_UID_MIN 101
|
||||||
|
#SYS_UID_MAX 999
|
||||||
|
# Extra per user uids
|
||||||
|
SUB_UID_MIN 100000
|
||||||
|
SUB_UID_MAX 600100000
|
||||||
|
SUB_UID_COUNT 65536
|
||||||
|
|
||||||
|
#
|
||||||
|
# Min/max values for automatic gid selection in groupadd(8)
|
||||||
|
#
|
||||||
|
GID_MIN 1000
|
||||||
|
GID_MAX 60000
|
||||||
|
# System accounts
|
||||||
|
#SYS_GID_MIN 101
|
||||||
|
#SYS_GID_MAX 999
|
||||||
|
# Extra per user group ids
|
||||||
|
SUB_GID_MIN 100000
|
||||||
|
SUB_GID_MAX 600100000
|
||||||
|
SUB_GID_COUNT 65536
|
||||||
|
|
||||||
|
#
|
||||||
|
# Max number of login(1) retries if password is bad
|
||||||
|
# This will most likely be overriden by PAM, since the default pam_unix module
|
||||||
|
# has it's own built in of 3 retries. However, this is a safe fallback in case
|
||||||
|
# you are using an authentication module that does not enforce PAM_MAXTRIES.
|
||||||
|
#
|
||||||
|
LOGIN_RETRIES 5
|
||||||
|
|
||||||
|
#
|
||||||
|
# Max time in seconds for login(1)
|
||||||
|
#
|
||||||
|
LOGIN_TIMEOUT 180
|
||||||
|
|
||||||
|
#
|
||||||
|
# Which fields may be changed by regular users using chfn(1) - use
|
||||||
|
# any combination of letters "frwh" (full name, room number, work
|
||||||
|
# phone, home phone). If not defined, no changes are allowed.
|
||||||
|
# For backward compatibility, "yes" = "rwh" and "no" = "frwh".
|
||||||
|
#
|
||||||
|
CHFN_RESTRICT rwh
|
||||||
|
|
||||||
|
#
|
||||||
|
# If set to MD5, MD5-based algorithm will be used for encrypting password
|
||||||
|
# If set to SHA256, SHA256-based algorithm will be used for encrypting password
|
||||||
|
# If set to SHA512, SHA512-based algorithm will be used for encrypting password
|
||||||
|
# If set to BCRYPT, BCRYPT-based algorithm will be used for encrypting password
|
||||||
|
# If set to YESCRYPT, YESCRYPT-based algorithm will be used for encrypting password
|
||||||
|
# If set to DES, DES-based algorithm will be used for encrypting password (default)
|
||||||
|
# MD5 and DES should not be used for new hashes, see crypt(5) for recommendations.
|
||||||
|
# Overrides the MD5_CRYPT_ENAB option
|
||||||
|
#
|
||||||
|
# Note: It is recommended to use a value consistent with
|
||||||
|
# the PAM modules configuration.
|
||||||
|
#
|
||||||
|
ENCRYPT_METHOD YESCRYPT
|
||||||
|
|
||||||
|
#
|
||||||
|
# Should login be allowed if we can't cd to the home directory?
|
||||||
|
# Default is no.
|
||||||
|
#
|
||||||
|
DEFAULT_HOME yes
|
||||||
|
|
||||||
|
#
|
||||||
|
# The pwck(8) utility emits a warning for any system account with a home
|
||||||
|
# directory that does not exist. Some system accounts intentionally do
|
||||||
|
# not have a home directory. Such accounts may have this string as
|
||||||
|
# their home directory in /etc/passwd to avoid a spurious warning.
|
||||||
|
#
|
||||||
|
NONEXISTENT /nonexistent
|
||||||
|
|
||||||
|
#
|
||||||
|
# If defined, this command is run when removing a user.
|
||||||
|
# It should remove any at/cron/print jobs etc. owned by
|
||||||
|
# the user to be removed (passed as the first argument).
|
||||||
|
#
|
||||||
|
#USERDEL_CMD /usr/sbin/userdel_local
|
||||||
|
|
||||||
|
#
|
||||||
|
# If set to yes, userdel(8) will remove the user's group if it contains no more
|
||||||
|
# members, and useradd(8) will create by default a group with the name of the
|
||||||
|
# user.
|
||||||
|
#
|
||||||
|
# Other former uses of this variable are not used in PAM environments, such as
|
||||||
|
# Debian.
|
||||||
|
#
|
||||||
|
USERGROUPS_ENAB yes
|
||||||
|
|
||||||
|
#
|
||||||
|
# Added by CISS.debian.live.builder for redundance
|
||||||
|
UMASK 077
|
||||||
|
|
||||||
|
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=conf
|
||||||
@@ -2,7 +2,7 @@
|
|||||||
# SPDX-CreationInfo: 2025-05-05; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-CreationInfo: 2025-05-05; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
||||||
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
# SPDX-FileCopyrightText: 2024–2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-FileType: SOURCE
|
# SPDX-FileType: SOURCE
|
||||||
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
|
|||||||
@@ -2,7 +2,7 @@
|
|||||||
# SPDX-CreationInfo: 2025-05-05; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-CreationInfo: 2025-05-05; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
||||||
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
# SPDX-FileCopyrightText: 2024–2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-FileType: SOURCE
|
# SPDX-FileType: SOURCE
|
||||||
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
|
|||||||
17
config/includes.chroot/etc/ssh/ssh_known_hosts
Normal file
17
config/includes.chroot/etc/ssh/ssh_known_hosts
Normal file
@@ -0,0 +1,17 @@
|
|||||||
|
# SPDX-Version: 3.0
|
||||||
|
# SPDX-CreationInfo: 2025-10-10; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
|
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
||||||
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
|
# SPDX-FileType: SOURCE
|
||||||
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
|
# SPDX-PackageName: CISS.debian.live.builder
|
||||||
|
# SPDX-Security-Contact: security@coresecret.eu
|
||||||
|
|
||||||
|
# Version Master V8.13.142.2025.10.14
|
||||||
|
|
||||||
|
[git.coresecret.dev]:42842 ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIGQA107AVmg1D/jnyXiqbPf38zQRl8s3c+PM1zbfpeQl
|
||||||
|
[git.coresecret.dev]:42842 ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAACAQDYD9ysmMWZlejUnxu0qOzeWcIYezoFLbYdo6ffGUL5kqOBAYb+5CF4bJLUpA93XFYVF+TbrcMV1yJh6JaHFL0VU5CvgAzruCeedx0c4qUV6lWcJUGNk5K0yb9n2Wosdy6F/zTOxL9KXBt/TV+cscsen2Dahvx0ctMKgNbu+vvUcWxHf9lOkbYoF/uA/nW5CVXy5XUPVUDFUhEeKXL85+6gid5AEMfYT8aRl5YDGvo1iMBmBYOljN4S7MnRe14qbAZG0GDGvF22eHbSU2pILcFIjc2Lo/S5Ox/MJpbLAqpFlLPTKgr6F7yVwfNMSNwl05ysUOZfrQKSXzCU6+lfqKYCwemLALyG/n1ernpp7/8W/2RYoz3fd+TQyfhW++rx3yUHpYCkTv9A4LRYZYGSAWKMHSBEYq3EcATQUxQi0xpwmcR+u0uC9F9eta5Bim+sBZD6F2hgPJ5xgYT8LFm880g1YadAwBoD4TAkqSvl+jYW0VA2GH9CknKHJ36gc/X4eeUHDC1Hf/E8M5RBj4D6NuHfeVRik/ahHmoCqKQUW7VU/EBsWFsngDiLEHcV71iMtWiUddWOHwoAPHIzn6p9HTeLCxTwsPMG5UDGK/S9HUozqDXxexRtqbcFa7DWuzRvZ1bcZ2VQsaafuzKCkkc4NjC7h1wssel7q9aeYPFg+1vS6Q==
|
||||||
|
|
||||||
|
# vim: number et ts=2 sw=2 sts=2 ai tw=128 ft=conf
|
||||||
@@ -1,15 +1,15 @@
|
|||||||
# SPDX-Version: 3.0
|
# SPDX-Version: 3.0
|
||||||
# SPDX-CreationInfo: 2025-05-05; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-CreationInfo: 2025-10-10; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
||||||
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
# SPDX-FileCopyrightText: 2024–2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-FileType: SOURCE
|
# SPDX-FileType: SOURCE
|
||||||
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
# SPDX-PackageName: CISS.debian.live.builder
|
# SPDX-PackageName: CISS.debian.live.builder
|
||||||
# SPDX-Security-Contact: security@coresecret.eu
|
# SPDX-Security-Contact: security@coresecret.eu
|
||||||
|
|
||||||
### Version Master V8.02.644.2025.05.31
|
# Version Master V8.13.142.2025.10.14
|
||||||
|
|
||||||
### https://www.ssh-audit.com/
|
### https://www.ssh-audit.com/
|
||||||
### ssh -Q cipher | cipher-auth | compression | kex | kex-gss | key | key-cert | key-plain | key-sig | mac | protocol-version | sig
|
### ssh -Q cipher | cipher-auth | compression | kex | kex-gss | key | key-cert | key-plain | key-sig | mac | protocol-version | sig
|
||||||
@@ -31,12 +31,12 @@ ListenAddress ::
|
|||||||
Port MUST_BE_CHANGED
|
Port MUST_BE_CHANGED
|
||||||
AllowUsers root
|
AllowUsers root
|
||||||
UseDNS no
|
UseDNS no
|
||||||
### Force a key exchange after transferring 1 GiB of data or 1 hour of session time,
|
### Force a key exchange after transferring 1 GiB of data or 1 hour of session time, whichever occurs first.
|
||||||
### whichever occurs first.
|
|
||||||
RekeyLimit 1G 1h
|
RekeyLimit 1G 1h
|
||||||
|
|
||||||
HostKey /etc/ssh/ssh_host_ed25519_key
|
HostKey /etc/ssh/ssh_host_ed25519_key
|
||||||
HostKey /etc/ssh/ssh_host_rsa_key
|
HostKey /etc/ssh/ssh_host_rsa_key
|
||||||
|
TrustedUserCAKeys none
|
||||||
|
|
||||||
PubkeyAuthentication yes
|
PubkeyAuthentication yes
|
||||||
PermitRootLogin prohibit-password
|
PermitRootLogin prohibit-password
|
||||||
@@ -51,7 +51,7 @@ MaxSessions 2
|
|||||||
MaxStartups 08:64:16
|
MaxStartups 08:64:16
|
||||||
### Restrict each individual source IP to only 4 unauthenticated connection slot
|
### Restrict each individual source IP to only 4 unauthenticated connection slot
|
||||||
### in the concurrent MaxStartups pool, preventing one IP from monopolizing slots.
|
### in the concurrent MaxStartups pool, preventing one IP from monopolizing slots.
|
||||||
PerSourceMaxStartups 4
|
PerSourceMaxStartups 8
|
||||||
ClientAliveInterval 300
|
ClientAliveInterval 300
|
||||||
ClientAliveCountMax 2
|
ClientAliveCountMax 2
|
||||||
|
|
||||||
@@ -65,12 +65,12 @@ GatewayPorts no
|
|||||||
### A+ Rating 100/100
|
### A+ Rating 100/100
|
||||||
RequiredRSASize 4096
|
RequiredRSASize 4096
|
||||||
Ciphers aes256-gcm@openssh.com
|
Ciphers aes256-gcm@openssh.com
|
||||||
KexAlgorithms sntrup761x25519-sha512@openssh.com,sntrup761x25519-sha512,gss-curve25519-sha256-
|
KexAlgorithms mlkem768x25519-sha256,sntrup761x25519-sha512@openssh.com,sntrup761x25519-sha512
|
||||||
HostKeyAlgorithms sk-ssh-ed25519-cert-v01@openssh.com,ssh-ed25519-cert-v01@openssh.com,sk-ssh-ed25519@openssh.com,ssh-ed25519,rsa-sha2-512-cert-v01@openssh.com,rsa-sha2-512,rsa-sha2-256-cert-v01@openssh.com,rsa-sha2-256
|
HostKeyAlgorithms ssh-ed25519-cert-v01@openssh.com,ssh-ed25519,rsa-sha2-512-cert-v01@openssh.com,rsa-sha2-512,rsa-sha2-256-cert-v01@openssh.com,rsa-sha2-256
|
||||||
MACs hmac-sha2-512-etm@openssh.com,hmac-sha2-256-etm@openssh.com
|
MACs hmac-sha2-512-etm@openssh.com,hmac-sha2-256-etm@openssh.com
|
||||||
CASignatureAlgorithms rsa-sha2-512,rsa-sha2-256,ssh-ed25519,sk-ssh-ed25519@openssh.com
|
CASignatureAlgorithms rsa-sha2-512,rsa-sha2-256,ssh-ed25519
|
||||||
GSSAPIKexAlgorithms gss-curve25519-sha256-,gss-group16-sha512-
|
GSSAPIKexAlgorithms gss-curve25519-sha256-,gss-group16-sha512-
|
||||||
HostbasedAcceptedAlgorithms sk-ssh-ed25519-cert-v01@openssh.com,ssh-ed25519-cert-v01@openssh.com,sk-ssh-ed25519@openssh.com,ssh-ed25519,rsa-sha2-512-cert-v01@openssh.com,rsa-sha2-512,rsa-sha2-256-cert-v01@openssh.com,rsa-sha2-256
|
HostbasedAcceptedAlgorithms ssh-ed25519-cert-v01@openssh.com,ssh-ed25519,rsa-sha2-512-cert-v01@openssh.com,rsa-sha2-512,rsa-sha2-256-cert-v01@openssh.com,rsa-sha2-256
|
||||||
PubkeyAcceptedAlgorithms sk-ssh-ed25519-cert-v01@openssh.com,ssh-ed25519-cert-v01@openssh.com,sk-ssh-ed25519@openssh.com,ssh-ed25519,rsa-sha2-512-cert-v01@openssh.com,rsa-sha2-512,rsa-sha2-256-cert-v01@openssh.com,rsa-sha2-256
|
PubkeyAcceptedAlgorithms sk-ssh-ed25519-cert-v01@openssh.com,ssh-ed25519-cert-v01@openssh.com,sk-ssh-ed25519@openssh.com,ssh-ed25519,rsa-sha2-512-cert-v01@openssh.com,rsa-sha2-512,rsa-sha2-256-cert-v01@openssh.com,rsa-sha2-256
|
||||||
|
|
||||||
### Change to yes to enable challenge-response passwords (beware issues with some PAM modules and threads)
|
### Change to yes to enable challenge-response passwords (beware issues with some PAM modules and threads)
|
||||||
|
|||||||
@@ -2,14 +2,14 @@
|
|||||||
# SPDX-CreationInfo: 2025-05-05; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-CreationInfo: 2025-05-05; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
||||||
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
# SPDX-FileCopyrightText: 2024–2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-FileType: SOURCE
|
# SPDX-FileType: SOURCE
|
||||||
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
# SPDX-PackageName: CISS.debian.live.builder
|
# SPDX-PackageName: CISS.debian.live.builder
|
||||||
# SPDX-Security-Contact: security@coresecret.eu
|
# SPDX-Security-Contact: security@coresecret.eu
|
||||||
|
|
||||||
### Version Master V8.02.644.2025.05.31
|
# Version Master V8.13.142.2025.10.14
|
||||||
|
|
||||||
### https://docs.kernel.org/
|
### https://docs.kernel.org/
|
||||||
### https://github.com/a13xp0p0v/kernel-hardening-checker/
|
### https://github.com/a13xp0p0v/kernel-hardening-checker/
|
||||||
|
|||||||
@@ -2,7 +2,7 @@
|
|||||||
# SPDX-CreationInfo: 2025-05-05; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-CreationInfo: 2025-05-05; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
||||||
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
# SPDX-FileCopyrightText: 2024–2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-FileType: SOURCE
|
# SPDX-FileType: SOURCE
|
||||||
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
|
|||||||
@@ -3,7 +3,7 @@
|
|||||||
# SPDX-CreationInfo: 2025-05-05; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-CreationInfo: 2025-05-05; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
||||||
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
# SPDX-FileCopyrightText: 2024–2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-FileType: SOURCE
|
# SPDX-FileType: SOURCE
|
||||||
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
|
|||||||
@@ -3,7 +3,7 @@
|
|||||||
# SPDX-CreationInfo: 2025-05-05; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-CreationInfo: 2025-05-05; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
||||||
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
# SPDX-FileCopyrightText: 2024–2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-FileType: SOURCE
|
# SPDX-FileType: SOURCE
|
||||||
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
|
|||||||
@@ -3,7 +3,7 @@
|
|||||||
# SPDX-CreationInfo: 2025-05-05; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-CreationInfo: 2025-05-05; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
||||||
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
# SPDX-FileCopyrightText: 2024–2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-FileType: SOURCE
|
# SPDX-FileType: SOURCE
|
||||||
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
|
|||||||
@@ -3,7 +3,7 @@
|
|||||||
# SPDX-CreationInfo: 2025-05-05; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-CreationInfo: 2025-05-05; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
||||||
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
# SPDX-FileCopyrightText: 2024–2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-FileType: SOURCE
|
# SPDX-FileType: SOURCE
|
||||||
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
|
|||||||
@@ -3,7 +3,7 @@
|
|||||||
# SPDX-CreationInfo: 2025-05-05; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-CreationInfo: 2025-05-05; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
# SPDX-ExternalRef: GIT https://git.coresecret.dev/msw/CISS.debian.live.builder.git
|
||||||
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
# SPDX-FileContributor: WEIDNER, Marc S.; Centurion Intelligence Consulting Agency
|
||||||
# SPDX-FileCopyrightText: 2024–2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
# SPDX-FileCopyrightText: 2024-2025; WEIDNER, Marc S.; <msw@coresecret.dev>
|
||||||
# SPDX-FileType: SOURCE
|
# SPDX-FileType: SOURCE
|
||||||
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
# SPDX-License-Identifier: EUPL-1.2 OR LicenseRef-CCLA-1.0
|
||||||
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
# SPDX-LicenseComment: This file is part of the CISS.debian.installer.secure framework.
|
||||||
|
|||||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user