| SYSTEM INFORMATION | |
|---|---|
| OS type and version | Debian Linux 12 |
| Webmin version | 2.621 |
| Virtualmin version | 8.1.0 Professional |
| Webserver version | Apache 2.4.66 |
| Related packages | N/A |
Had some issues with WebSockets & Redirects in this topic. The patch worked great. Sometime between now and the previous VMIN/WMIN updates I’ve run into an issue with the redirect rules. It’s probably something I messed up, but I need help troubleshooting it as WebSockets are now not functioning on any new sub-server I create.
Current template for sub-servers has “Redirect all HTTP requests to HTTPS” checked. However, when I create a new sub-server, the radio button in the new server’s Website Options is set to No:
However, the RewriteRule appears to be there:
RewriteRule ^/(?!.well-known).....
ProxyPass /.well-known !
RemoveHandler .php
RemoveHandler .php8.4
RewriteEngine on
RewriteRule ^/(?!.well-known)(.)$(.)$ https://%{HTTP_HOST}/$1$1 [R]
<FilesMatch .php$>
SetHandler proxy:unix:/run/php/177402375032753.sock|fcgi://127.0.0.1
If I check the radio button yes and click save, the radio button once again reverts to no, but the rewrite rule gets written to the directives twice. Sbbsequent checking of the radio button just adds the additional line as shown:
Duplicate RewriteRule ^/(?!.well-known).....
ProxyPass /.well-known !
RemoveHandler .php
RemoveHandler .php8.4
RewriteEngine on
RewriteRule ^/(?!.well-known)(.)$(.)$ https://%{HTTP_HOST}/$1$1 [R]
<FilesMatch .php$>
SetHandler proxy:unix:/run/php/177402375032753.sock|fcgi://127.0.0.1
RewriteRule ^/(?!.well-known)(.)$(.)$ https://%{HTTP_HOST}/$1$1 [R]
RewriteRule ^/(?!.well-known)(.)$(.)$ https://%{HTTP_HOST}/$1$1 [R]
RewriteRule ^/(?!.well-known)(.)$(.)$ https://%{HTTP_HOST}/$1$1 [R]
Also, is this rewrite directive correct? in troubleshooting I noticed that sub-domains I created prior to the patching / upgrade show one standard, while the sub-domains I created after show another:
Before Patch / Upgrade: RewriteRule ^/(?!.well-known)(.*)$ https://%{HTTP_HOST}/$1 [R]
After Patch / Upgrade: RewriteRule ^/(?!.well-known)(.*)$(.*)$ https://%{HTTP_HOST}/$1$1 [R]
