Skip to content

Commit

Permalink
IP validation
Browse files Browse the repository at this point in the history
  • Loading branch information
tmachyshyn committed Apr 3, 2024
1 parent 0d4e8c1 commit cebb095
Show file tree
Hide file tree
Showing 10 changed files with 37 additions and 1 deletion.
4 changes: 4 additions & 0 deletions apache/docker-daemon.sh
Original file line number Diff line number Diff line change
Expand Up @@ -174,6 +174,10 @@ isQuoteValue() {
return true;
}
if (filter_var(\$value, FILTER_VALIDATE_IP)) {
return true;
}
if (!preg_match('/[^0-9.]+/', \$value)) {
return false;
}
Expand Down
2 changes: 1 addition & 1 deletion apache/docker-entrypoint.sh
Original file line number Diff line number Diff line change
Expand Up @@ -172,7 +172,7 @@ isQuoteValue() {
return true;
}
if (filter_var(\$value, FILTER_VALIDATE_IP)) {
if (filter_var(\$value, FILTER_VALIDATE_IP)) {
return true;
}
Expand Down
4 changes: 4 additions & 0 deletions apache/docker-websocket.sh
Original file line number Diff line number Diff line change
Expand Up @@ -174,6 +174,10 @@ isQuoteValue() {
return true;
}
if (filter_var(\$value, FILTER_VALIDATE_IP)) {
return true;
}
if (!preg_match('/[^0-9.]+/', \$value)) {
return false;
}
Expand Down
4 changes: 4 additions & 0 deletions entrypoint-utils.sh
Original file line number Diff line number Diff line change
Expand Up @@ -167,6 +167,10 @@ isQuoteValue() {
return true;
}
if (filter_var(\$value, FILTER_VALIDATE_IP)) {
return true;
}
if (!preg_match('/[^0-9.]+/', \$value)) {
return false;
}
Expand Down
4 changes: 4 additions & 0 deletions fpm-alpine/docker-daemon.sh
Original file line number Diff line number Diff line change
Expand Up @@ -174,6 +174,10 @@ isQuoteValue() {
return true;
}
if (filter_var(\$value, FILTER_VALIDATE_IP)) {
return true;
}
if (!preg_match('/[^0-9.]+/', \$value)) {
return false;
}
Expand Down
4 changes: 4 additions & 0 deletions fpm-alpine/docker-entrypoint.sh
Original file line number Diff line number Diff line change
Expand Up @@ -172,6 +172,10 @@ isQuoteValue() {
return true;
}
if (filter_var(\$value, FILTER_VALIDATE_IP)) {
return true;
}
if (!preg_match('/[^0-9.]+/', \$value)) {
return false;
}
Expand Down
4 changes: 4 additions & 0 deletions fpm-alpine/docker-websocket.sh
Original file line number Diff line number Diff line change
Expand Up @@ -174,6 +174,10 @@ isQuoteValue() {
return true;
}
if (filter_var(\$value, FILTER_VALIDATE_IP)) {
return true;
}
if (!preg_match('/[^0-9.]+/', \$value)) {
return false;
}
Expand Down
4 changes: 4 additions & 0 deletions fpm/docker-daemon.sh
Original file line number Diff line number Diff line change
Expand Up @@ -174,6 +174,10 @@ isQuoteValue() {
return true;
}
if (filter_var(\$value, FILTER_VALIDATE_IP)) {
return true;
}
if (!preg_match('/[^0-9.]+/', \$value)) {
return false;
}
Expand Down
4 changes: 4 additions & 0 deletions fpm/docker-entrypoint.sh
Original file line number Diff line number Diff line change
Expand Up @@ -172,6 +172,10 @@ isQuoteValue() {
return true;
}
if (filter_var(\$value, FILTER_VALIDATE_IP)) {
return true;
}
if (!preg_match('/[^0-9.]+/', \$value)) {
return false;
}
Expand Down
4 changes: 4 additions & 0 deletions fpm/docker-websocket.sh
Original file line number Diff line number Diff line change
Expand Up @@ -174,6 +174,10 @@ isQuoteValue() {
return true;
}
if (filter_var(\$value, FILTER_VALIDATE_IP)) {
return true;
}
if (!preg_match('/[^0-9.]+/', \$value)) {
return false;
}
Expand Down

0 comments on commit cebb095

Please sign in to comment.