-
Notifications
You must be signed in to change notification settings - Fork 53
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat(24.04): add libcrack-runtime and its dependencies #329
base: ubuntu-24.04
Are you sure you want to change the base?
Changes from all commits
8bc346b
868eeb3
1ddc197
f82fbbc
19ee486
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,46 @@ | ||
package: cracklib-runtime | ||
|
||
essential: | ||
- cracklib-runtime_copyright | ||
|
||
# Cracklib runs /usr/sbin/update-cracklib on install, and this | ||
# in turns generate the cracklib caches. This is mostly possible to do | ||
# as a mutation script, and is provided here: | ||
# https://paste.ubuntu.com/p/Jc5vvgk3tN/ | ||
# however the files it writes are malformed as we cannot write raw bytes, | ||
# but instead we write files as text which results in larger files than | ||
# expected (i.e the generated cracklib_dict.hwm is 1618 bytes instead of 1024). | ||
# If we could use the above mutation script, then the contents of the 'bins' | ||
# slice would probably not be needed, together with most of the 'config' | ||
# slice. | ||
slices: | ||
# the scripts use both 'file', 'find' and 'grep' | ||
# so we ensure those dependencies are added. | ||
# furthermore, libssl3t64 is required as well | ||
bins: | ||
essential: | ||
- cracklib-runtime_config | ||
- file_bins | ||
- findutils_bins | ||
- grep_bins | ||
- libc6_libs | ||
- libcrack2_libs | ||
- libssl3t64_libs | ||
contents: | ||
/usr/sbin/cracklib-check: | ||
/usr/sbin/cracklib-format: | ||
/usr/sbin/cracklib-packer: | ||
/usr/sbin/cracklib-unpacker: | ||
/usr/sbin/create-cracklib-dict: | ||
/usr/sbin/update-cracklib: | ||
|
||
config: | ||
contents: | ||
/etc/cracklib/cracklib.conf: | ||
/etc/logcheck/ignore.d.paranoid/cracklib-runtime: | ||
/usr/share/dict/cracklib-small: | ||
/var/cache/cracklib/: { make: true, mode: 0755 } | ||
|
||
copyright: | ||
contents: | ||
/usr/share/doc/cracklib-runtime/copyright: |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
package: file | ||
|
||
essential: | ||
- file_copyright | ||
|
||
slices: | ||
bins: | ||
essential: | ||
- libc6_libs | ||
- libmagic1t64_config | ||
- libmagic1t64_libs | ||
contents: | ||
/usr/bin/file: | ||
|
||
copyright: | ||
contents: | ||
/usr/share/doc/file/copyright: |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
package: libcrack2 | ||
|
||
essential: | ||
- libcrack2_copyright | ||
|
||
slices: | ||
libs: | ||
essential: | ||
- libc6_libs | ||
contents: | ||
/usr/lib/*-linux-*/libcrack.so.2*: | ||
|
||
copyright: | ||
contents: | ||
/usr/share/doc/libcrack2/copyright: |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
package: libmagic-mgc | ||
|
||
essential: | ||
- libmagic-mgc_copyright | ||
|
||
slices: | ||
config: | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Can we call this slice |
||
contents: | ||
/usr/lib/file/magic.mgc: | ||
/usr/share/file/magic.mgc: | ||
/usr/share/misc/magic.mgc: | ||
|
||
copyright: | ||
contents: | ||
/usr/share/doc/libmagic-mgc/copyright: |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
package: libmagic1t64 | ||
|
||
essential: | ||
- libmagic1t64_copyright | ||
|
||
slices: | ||
libs: | ||
essential: | ||
- libbz2-1.0_libs | ||
- libc6_libs | ||
- liblzma5_libs | ||
- zlib1g_libs | ||
contents: | ||
/usr/lib/*-linux-*/libmagic.so.1*: | ||
|
||
config: | ||
essential: | ||
- libmagic-mgc_config | ||
contents: | ||
/etc/magic: | ||
/etc/magic.mime: | ||
/usr/share/misc/magic: | ||
|
||
copyright: | ||
contents: | ||
/usr/share/doc/libmagic1t64/copyright: |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
summary: Integration tests for cracklib-runtime | ||
|
||
systems: | ||
- -ubuntu-24.04-ppc64le | ||
- -ubuntu-24.04-s390x | ||
Comment on lines
+4
to
+5
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Curious to know why you don't need these. |
||
|
||
execute: | | ||
rootfs="$(install-slices bash_bins base-files_base coreutils_bins cracklib-runtime_bins)" | ||
|
||
chroot "$rootfs" ln -s /usr/bin/bash /bin/sh | ||
chroot "$rootfs" /usr/sbin/update-cracklib | ||
|
||
if ! [ -e "$rootfs"/var/cache/cracklib/cracklib_dict.hwm ]; then | ||
echo "expected /var/cache/cracklib/cracklib_dict.hwm to exist" | ||
exit -1 | ||
fi | ||
|
||
if ! [ -e "$rootfs"/var/cache/cracklib/cracklib_dict.pwd ]; then | ||
echo "expected /var/cache/cracklib/cracklib_dict.pwd to exist" | ||
exit -1 | ||
fi | ||
|
||
if ! [ -e "$rootfs"/var/cache/cracklib/cracklib_dict.pwi ]; then | ||
echo "expected /var/cache/cracklib/cracklib_dict.pwi to exist" | ||
exit -1 | ||
fi | ||
|
||
if ! [ -e "$rootfs"/var/cache/cracklib/src-dicts ]; then | ||
echo "expected /var/cache/cracklib/src-dicts to exist" | ||
exit -1 | ||
fi | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Can you also add smoke tests for the rest of the binaries in cracklib-runtime_bins slice? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice work there! It's a shame we cannot write raw bytes yet.
On another note, could this link expire some day? If so, I would want there to be something that does not expire, Github Gist maybe?