This commit is contained in:
Josh Patterson
2025-04-03 13:44:13 -04:00
parent 3083e3bc63
commit 445afca6ee
27 changed files with 41 additions and 46 deletions

View File

@@ -235,7 +235,7 @@ function acceptminion() {
if [[ "$MINION_ID" == *"_hypervisor" ]]; then
FEATURES=$(/usr/sbin/so-yaml.py get /opt/so/saltstack/local/pillar/soc/license.sls features)
if [[ $? -ne 0 || ! "$FEATURES" =~ "hvn" ]]; then
if [[ $? -ne 0 || ! "$FEATURES" =~ "vrt" ]]; then
error_msg="Hypervisor nodes are a feature supported only for customers with a valid license.\n Contact Security Onion Solutions, LLC via our website at https://securityonionsolutions.com\n for more information about purchasing a license to enable this feature."
log "ERROR" "$error_msg"
echo -e "Error: $error_msg"
@@ -869,7 +869,7 @@ function createRECEIVER() {
function createHYPERVISOR() {
log "INFO" "Creating HYPERVISOR configuration for minion $MINION_ID"
FEATURES=$(/usr/sbin/so-yaml.py get /opt/so/saltstack/local/pillar/soc/license.sls features)
if [[ $? -ne 0 || ! "$FEATURES" =~ "hvn" ]]; then
if [[ $? -ne 0 || ! "$FEATURES" =~ "vrt" ]]; then
error_msg="Hypervisor nodes are a feature supported only for customers with a valid license.\n Contact Security Onion Solutions, LLC via our website at https://securityonionsolutions.com\n for more information about purchasing a license to enable this feature."
log "ERROR" "$error_msg"
echo -e "Error: $error_msg"
@@ -964,7 +964,7 @@ function updateMineAndApplyStates() {
# We don't want a hypervisor node to highstate until the image is downloaded and built. This will be triggered from the setup_hypervisor runner
if [[ "$NODETYPE" == "HYPERVISOR" ]]; then
FEATURES=$(/usr/sbin/so-yaml.py get /opt/so/saltstack/local/pillar/soc/license.sls features)
if [[ $? -ne 0 || ! "$FEATURES" =~ "hvn" ]]; then
if [[ $? -ne 0 || ! "$FEATURES" =~ "vrt" ]]; then
error_msg="Hypervisor nodes are a feature supported only for customers with a valid license.\n Contact Security Onion Solutions, LLC via our website at https://securityonionsolutions.com\n for more information about purchasing a license to enable this feature."
log "ERROR" "$error_msg"
echo -e "Error: $error_msg"
@@ -1058,7 +1058,7 @@ case "$OPERATION" in
"addVM")
log "INFO" "Adding VM minion $MINION_ID"
FEATURES=$(/usr/sbin/so-yaml.py get /opt/so/saltstack/local/pillar/soc/license.sls features)
if [[ $? -ne 0 || ! "$FEATURES" =~ "hvn" ]]; then
if [[ $? -ne 0 || ! "$FEATURES" =~ "vrt" ]]; then
error_msg="Hypervisor nodes are a feature supported only for customers with a valid license.\n Contact Security Onion Solutions, LLC via our website at https://securityonionsolutions.com\n for more information about purchasing a license to enable this feature."
log "ERROR" "$error_msg"
echo -e "Error: $error_msg"