[Solved] Bug? Nginx reverse proxy basic auth

Started by Dgd, August 04, 2022, 02:54:03 PM

Previous topic - Next topic
August 04, 2022, 02:54:03 PM Last Edit: August 04, 2022, 06:18:11 PM by Dgd
Hi

with the opnsense version "OPNsense 22.7_4-amd64" I can't create users for basic auth for a Nginx reverse proxy configuration (with Opnsense versions 22.1x all works fine). Here some details: On the GUI and within config.xml all looks fine, but the users won't created within /var/db/nginx/auth (the file will be created, but without users).

For trouble shooting I started the following script manually: /usr/local/opnsense/scripts/nginx/setup.php
Output:
Fatal error: Uncaught ArgumentCountError: crypt() expects exactly 2 arguments, 1 given in /usr/local/opnsense/scripts/nginx/setup.php:231
Stack trace:
#0 /usr/local/opnsense/scripts/nginx/setup.php(231): crypt('PASSWORD')
#1 {main}
  thrown in /usr/local/opnsense/scripts/nginx/setup.php on line 231

It seems that the PHP crypt function now needs two arguments mandatory.

regards

giancarlo