Skip to content

Commit b593ba2

Browse files
committed
Merge branch 'main' into 2.0
2 parents 5b01d26 + fea7c96 commit b593ba2

40 files changed

Lines changed: 1524 additions & 392 deletions

SPECS/LICENSES-AND-NOTICES/LICENSES-MAP.md

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

SPECS/LICENSES-AND-NOTICES/data/licenses.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2150,6 +2150,7 @@
21502150
"application-gateway-kubernetes-ingress",
21512151
"asc",
21522152
"azcopy",
2153+
"azl-compliance",
21532154
"azure-iot-sdk-c",
21542155
"azure-storage-cpp",
21552156
"azurelinux-sysinfo",
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
{
2+
"Signatures": {
3+
"azl-compliance-1.0.1.tar.gz": "1d96b99ec755500383e5ff6bad01f1ac85848f067488f3ce29a99e6eb57a86b7"
4+
}
5+
}
Lines changed: 58 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,58 @@
1+
Summary: Azure Linux compliance package to meet all sorts of compliance rules
2+
Name: azl-compliance
3+
Version: 1.0.1
4+
Release: 1%{?dist}
5+
License: BSD-3-Clause
6+
Vendor: Microsoft Corporation
7+
Distribution: Mariner
8+
Group: System Environment/Base
9+
URL: https://aka.ms/mariner
10+
Source0: %{_mariner_sources_url}/%{name}-%{version}.tar.gz
11+
Requires: dnf
12+
Requires: gnutls
13+
Requires: grub2
14+
Requires: grubby
15+
Requires: rpm
16+
Requires: rsyslog
17+
Requires: sudo
18+
BuildRequires: rust
19+
20+
%description
21+
Azure Linux compliance package to configure systems to meet FIPS and FedRAMP compliance.
22+
23+
%prep
24+
%autosetup
25+
26+
%build
27+
cd azl-compliance
28+
cargo build --release --offline
29+
30+
%install
31+
mkdir -p %{buildroot}%{_sysconfdir}/azl-compliance/
32+
mkdir -p %{buildroot}%{_bindir}
33+
install -m 0755 ./azl-compliance/target/release/azl-compliance %{buildroot}%{_bindir}/azl-compliance
34+
mkdir -p %{buildroot}%{_sysconfdir}/azl-compliance/fips
35+
mkdir -p %{buildroot}%{_sysconfdir}/azl-compliance/fedramp/remediation_scripts
36+
install -m 0755 fips/*.sh %{buildroot}%{_sysconfdir}/azl-compliance/fips/
37+
install -m 0755 fedramp/*.sh %{buildroot}%{_sysconfdir}/azl-compliance/fedramp/
38+
install -m 0644 fedramp/*.txt %{buildroot}%{_sysconfdir}/azl-compliance/fedramp/
39+
install -m 0755 fedramp/remediation_scripts/* %{buildroot}%{_sysconfdir}/azl-compliance/fedramp/remediation_scripts/
40+
install -m 0644 azl-compliance-fips.json %{buildroot}%{_sysconfdir}/azl-compliance/
41+
install -m 0644 azl-compliance-fedramp.json %{buildroot}%{_sysconfdir}/azl-compliance/
42+
43+
%files
44+
%license LICENSE
45+
%{_bindir}/azl-compliance
46+
%{_sysconfdir}/azl-compliance/fips
47+
%{_sysconfdir}/azl-compliance/azl-compliance-fips.json
48+
%{_sysconfdir}/azl-compliance/fedramp
49+
%{_sysconfdir}/azl-compliance/azl-compliance-fedramp.json
50+
51+
%check
52+
cd azl-compliance
53+
cargo test --release --offline
54+
55+
%changelog
56+
* Tue Mar 19 2024 Tobias Brick <tobiasb@microsoft.com> 1.0.1-1
57+
- Original version for CBL-Mariner.
58+
- License verified

SPECS/cri-o/CVE-2021-3602.patch

Lines changed: 0 additions & 79 deletions
Original file line numberDiff line numberDiff line change
@@ -1,82 +1,3 @@
1-
From 8716daa06e9eb421438b338f18b6b650b082b208 Mon Sep 17 00:00:00 2001
2-
From: Cameron Baird <cameronbaird@microsoft.com>
3-
Date: Tue, 16 Apr 2024 22:33:46 +0000
4-
Subject: [PATCH 4/4] CVE-2021-3602
5-
6-
---
7-
.../github.com/containers/buildah/chroot/run.go | 15 +++++----------
8-
.../podman/v3/pkg/specgen/generate/security.go | 7 +++++--
9-
2 files changed, 10 insertions(+), 12 deletions(-)
10-
11-
diff --git a/vendor/github.com/containers/buildah/chroot/run.go b/vendor/github.com/containers/buildah/chroot/run.go
12-
index a93f97dcd..643f5c91d 100644
13-
--- a/vendor/github.com/containers/buildah/chroot/run.go
14-
+++ b/vendor/github.com/containers/buildah/chroot/run.go
15-
@@ -160,7 +160,7 @@ func RunUsingChroot(spec *specs.Spec, bundlePath, homeDir string, stdin io.Reade
16-
cmd := unshare.Command(runUsingChrootCommand)
17-
cmd.Stdin, cmd.Stdout, cmd.Stderr = stdin, stdout, stderr
18-
cmd.Dir = "/"
19-
- cmd.Env = append([]string{fmt.Sprintf("LOGLEVEL=%d", logrus.GetLevel())}, os.Environ()...)
20-
+ cmd.Env = []string{fmt.Sprintf("LOGLEVEL=%d", logrus.GetLevel())}
21-
22-
logrus.Debugf("Running %#v in %#v", cmd.Cmd, cmd)
23-
confwg.Add(1)
24-
@@ -206,7 +206,7 @@ func runUsingChrootMain() {
25-
os.Exit(1)
26-
}
27-
28-
- if options.Spec == nil {
29-
+ if options.Spec == nil || options.Spec.Process == nil {
30-
fmt.Fprintf(os.Stderr, "invalid options spec in runUsingChrootMain\n")
31-
os.Exit(1)
32-
}
33-
@@ -572,7 +572,7 @@ func runUsingChroot(spec *specs.Spec, bundlePath string, ctty *os.File, stdin io
34-
cmd := unshare.Command(append([]string{runUsingChrootExecCommand}, spec.Process.Args...)...)
35-
cmd.Stdin, cmd.Stdout, cmd.Stderr = stdin, stdout, stderr
36-
cmd.Dir = "/"
37-
- cmd.Env = append([]string{fmt.Sprintf("LOGLEVEL=%d", logrus.GetLevel())}, os.Environ()...)
38-
+ cmd.Env = []string{fmt.Sprintf("LOGLEVEL=%d", logrus.GetLevel())}
39-
cmd.UnshareFlags = syscall.CLONE_NEWUTS | syscall.CLONE_NEWNS
40-
requestedUserNS := false
41-
for _, ns := range spec.Linux.Namespaces {
42-
@@ -662,7 +662,7 @@ func runUsingChrootExecMain() {
43-
// Set the hostname. We're already in a distinct UTS namespace and are admins in the user
44-
// namespace which created it, so we shouldn't get a permissions error, but seccomp policy
45-
// might deny our attempt to call sethostname() anyway, so log a debug message for that.
46-
- if options.Spec == nil {
47-
+ if options.Spec == nil || options.Spec.Process == nil {
48-
fmt.Fprintf(os.Stderr, "invalid options spec passed in\n")
49-
os.Exit(1)
50-
}
51-
@@ -818,7 +818,6 @@ func runUsingChrootExecMain() {
52-
// Output debug messages when that differs from what we're being asked to do.
53-
func logNamespaceDiagnostics(spec *specs.Spec) {
54-
sawMountNS := false
55-
- sawUserNS := false
56-
sawUTSNS := false
57-
for _, ns := range spec.Linux.Namespaces {
58-
switch ns.Type {
59-
@@ -853,9 +852,8 @@ func logNamespaceDiagnostics(spec *specs.Spec) {
60-
}
61-
case specs.UserNamespace:
62-
if ns.Path != "" {
63-
- logrus.Debugf("unable to join user namespace %q, creating a new one", ns.Path)
64-
+ logrus.Debugf("unable to join user namespace, sorry about that")
65-
}
66-
- sawUserNS = true
67-
case specs.UTSNamespace:
68-
if ns.Path != "" {
69-
logrus.Debugf("unable to join UTS namespace %q, creating a new one", ns.Path)
70-
@@ -866,9 +864,6 @@ func logNamespaceDiagnostics(spec *specs.Spec) {
71-
if !sawMountNS {
72-
logrus.Debugf("mount namespace not requested, but creating a new one anyway")
73-
}
74-
- if !sawUserNS {
75-
- logrus.Debugf("user namespace not requested, but creating a new one anyway")
76-
- }
77-
if !sawUTSNS {
78-
logrus.Debugf("UTS namespace not requested, but creating a new one anyway")
79-
}
801
diff --git a/vendor/github.com/containers/podman/v3/pkg/specgen/generate/security.go b/vendor/github.com/containers/podman/v3/pkg/specgen/generate/security.go
812
index e0e4a47a4..3cda89a32 100644
823
--- a/vendor/github.com/containers/podman/v3/pkg/specgen/generate/security.go

0 commit comments

Comments
 (0)