Skip to content

Commit

Permalink
Use a wildcard in the domain name
Browse files Browse the repository at this point in the history
  • Loading branch information
f-galland committed Nov 20, 2024
1 parent 8ff89d6 commit 8ccc961
Showing 1 changed file with 111 additions and 102 deletions.
213 changes: 111 additions & 102 deletions distribution/packages/src/common/scripts/install-demo-certificates.sh
Original file line number Diff line number Diff line change
Expand Up @@ -20,133 +20,133 @@ if [ ${USE_DEMO_CERTS:-false} = "true" ]
then
cat <<'ADMIN_KEY' > $TMP_DIR/admin-key.pem
-----BEGIN PRIVATE KEY-----
MIIEvQIBADANBgkqhkiG9w0BAQEFAASCBKcwggSjAgEAAoIBAQCOsmzee/YLi+ng
6IpOAqyvRZ7ccXYMcUzY4nwLmB5rDGDpnxOIg2REPaUXXgV8gbUl10bvzeSY53Sp
udkjVVrmaWm8bB1IkspvdoUtmHR1BriilbaHjQN1y0QTlvBZKwMYfhbZKAspUHZ5
NekIoqUKcRqkuEh0yA7pyo/DooxOxuGg9IT2loDeFHsSfUsEVD+0UnMA2+dIS6Fo
Hd6fTXTUT13OSIr0msvv5EKyABXI/0GONY12qwnzG4VccHLDiX0/9G5hYVfql4hG
RatXyGXIK9jMm5x4GZ1MwJFvUcFSVG/PSaDcPMMDtRSxouxHXn9QkvsJRVHwiGoU
hkTo3jexAgMBAAECggEAC0Mo1Yx6GGI0FNS1qb+LSpAXoDVySDwfARUrDi005WUG
NxofjAw2uy4UXBpHG5MPLYvmpOGes7S83/JzoVbIxFu4hS8RRpuTT6XOkBEyy9O6
edaQH/WwurjOyC8HDDqZVXMKMZx3+QxJNXrcSBqyJPdVT3/d9B2gE7KxkxK+uS7a
DyN7yDzBzO3zxBG+8ub05AJCauaLSKX3/PjUfLT+xyv/vMUEQlvbWnTVlSthMPZs
6W/TmuBjFCHkVSIviu9/DAWewse5R/dB0VEsS3PUXZVzBWm9KV5KZNipZmFyAKu+
eLD2Tj0YWZTicfgKRV121RhgxOl4ICI8gRSasCPDCwKBgQDAylmDVsGAtnMOj7Lu
kv9yK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KCAQEAqbtN6t/RHs29r9qg4759
2R71qRmSaPU+MW3oZA4XzqTa9p/BCcmmemLIUalp+WeUCBlUB34eMEpA9vZ7cT0j
UQQNnTCx/6iWY95qAl8dIQUZeuYM6FmIMuZhzmIgdamMHh9YKYctuBBNJ2ySwnwe
G4lON+1wvBipMGM5OjXkhnYhg2lz9EfjjBdBgpAMjBgULZ2vKc8u+xX9ILk0v507
wDO4sLkXzes63wX/I98R1XJ8ttqLjUvVxxDkeFZmoNa9t2nZkweQrwYJc/NiF1u9
VqIFYJM/3MAfYR/pAaB/ma+0Aq81JkEmh0wj6HayRtIrU36SFoGP/xdip6RhGSbJ
AQIDAQABo1MwUTAdBgNVHQ4EFgQUuIrCVsvO/+Z8Vpr+93w+aUgUSXgwHwYDVR0j
BBgwFoAUuIrCVsvO/+Z8Vpr+93w+aUgUSXgwDwYDVR0TAQH/BAUwAwEB/zANBgkq
hkiG9w0BAQsFAAOCAQEAor0/yTsFn1/sd+CkcqpBharEX1Xq1FRVDN1DJYXJ/eUS
cl+Yyg72fe+cbwOHMbwhiJxWhX1nlWby6RO+vbNADXy+GCxNnpNnVe3maYk3DA2q
G5VNJtXv7OYjdIP5/4rOmbhTPoZfmsmKRGCMJEtJ0uq+VLrtPJsH10nAp8vceoMc
PQB0He59izGVDwH47iJKVJVb7AnMFALFzlSYdjA0gVSXwj4n+VnVK2inBRwQ3MFl
u2MM6NS9vE8IgX4+3X7cJkg2i6dLxGX69vTDyh6Y2obh4FgcY1PQfsUVZcWlSVvf
kV0DupKzxHxUDXX8TvzihxGEkEi8HIYOQes7pTNTiw==
-----END CERTIFICATE-----
ROOT_CA

Expand All @@ -165,8 +165,17 @@ else
# Node cert
openssl genrsa -out "$TMP_DIR/indexer-key-temp.pem" 2048
openssl pkcs8 -inform PEM -outform PEM -in "$TMP_DIR/indexer-key-temp.pem" -topk8 -nocrypt -v1 PBE-SHA1-3DES -out "$TMP_DIR/indexer-key.pem"
openssl req -new -key "$TMP_DIR/indexer-key.pem" -subj "/C=US/L=California/O=Wazuh/OU=Wazuh/CN=node-1" -out "$TMP_DIR/indexer.csr"
echo 'subjectAltName=RID:1.2.3.4.5.5,DNS:wazuh.indexer,DNS:localhost,IP:127.0.0.1,IP:0:0:0:0:0:0:0:1' > "$TMP_DIR/indexer.ext"
openssl req -new -key "$TMP_DIR/indexer-key.pem" -subj "/C=US/L=California/O=Wazuh/OU=Wazuh/CN=node-0.wazuh.indexer" -out "$TMP_DIR/indexer.csr"
cat <<'INDEXER_EXT' > $TMP_DIR/indexer.ext
subjectAltName = @alt_names
[alt_names]
DNS.1 = localhost
DNS.2 = *.wazuh.indexer
RID.1 = 1.2.3.4.5
IP.1 = 127.0.0.1
IP.2 = 0:0:0:0:0:0:0:1
INDEXER_EXT

openssl x509 -req -in "$TMP_DIR/indexer.csr" -CA "$TMP_DIR/root-ca.pem" -CAkey "$TMP_DIR/root-ca-key-temp.pem" -CAcreateserial -sha256 -out "$TMP_DIR/indexer.pem" -days 3650 -extfile "$TMP_DIR/indexer.ext"

# Cleanup temporary files
Expand Down

0 comments on commit 8ccc961

Please sign in to comment.