mirror of
https://github.com/Security-Onion-Solutions/securityonion.git
synced 2025-12-06 17:22:49 +01:00
Convert ES cert to p12
This commit is contained in:
@@ -244,7 +244,7 @@ miniokeyperms:
|
|||||||
# Will trigger 5 days (432000 sec) from cert expiration
|
# Will trigger 5 days (432000 sec) from cert expiration
|
||||||
- 'enddate=$(date -d "$(openssl x509 -in /etc/pki/elasticsearch.crt -enddate -noout | cut -d= -f2)" +%s) ; now=$(date +%s) ; expire_date=$(( now + 432000)); [ $enddate -gt $expire_date ]'
|
- 'enddate=$(date -d "$(openssl x509 -in /etc/pki/elasticsearch.crt -enddate -noout | cut -d= -f2)" +%s) ; now=$(date +%s) ; expire_date=$(( now + 432000)); [ $enddate -gt $expire_date ]'
|
||||||
cmd.run:
|
cmd.run:
|
||||||
- name: "/usr/bin/openssl pkcs12 -inkey /etc/pki/elasticsearch.key -in /etc/pki/elasticsearch.crt -export -out /etc/pki/elasticsearch.p12 -nocrypt"
|
- name: "/usr/bin/openssl pkcs12 -inkey /etc/pki/elasticsearch.key -in /etc/pki/elasticsearch.crt -export -out /etc/pki/elasticsearch.p12 -nodes -passout pass:"
|
||||||
- onchanges:
|
- onchanges:
|
||||||
- x509: /etc/pki/elasticsearch.key
|
- x509: /etc/pki/elasticsearch.key
|
||||||
|
|
||||||
@@ -526,7 +526,7 @@ fleetkeyperms:
|
|||||||
# Will trigger 5 days (432000 sec) from cert expiration
|
# Will trigger 5 days (432000 sec) from cert expiration
|
||||||
- 'enddate=$(date -d "$(openssl x509 -in /etc/pki/elasticsearch.crt -enddate -noout | cut -d= -f2)" +%s) ; now=$(date +%s) ; expire_date=$(( now + 432000)); [ $enddate -gt $expire_date ]'
|
- 'enddate=$(date -d "$(openssl x509 -in /etc/pki/elasticsearch.crt -enddate -noout | cut -d= -f2)" +%s) ; now=$(date +%s) ; expire_date=$(( now + 432000)); [ $enddate -gt $expire_date ]'
|
||||||
cmd.run:
|
cmd.run:
|
||||||
- name: "/usr/bin/openssl pkcs12 -inkey /etc/pki/elasticsearch.key -in /etc/pki/elasticsearch.crt -export -out /etc/pki/elasticsearch.p12"
|
- name: "/usr/bin/openssl pkcs12 -inkey /etc/pki/elasticsearch.key -in /etc/pki/elasticsearch.crt -export -out /etc/pki/elasticsearch.p12 -nodes -passout pass:"
|
||||||
- onchanges:
|
- onchanges:
|
||||||
- x509: /etc/pki/elasticsearch.key
|
- x509: /etc/pki/elasticsearch.key
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user