Issue with Serving Custom mail/config-v1.1.xml File Due to DirectAdmin ProxyPassMatch Directive

ryny24

New member
Joined
Dec 16, 2025
Messages
1
I am attempting to set up automatic email client configuration (e.g., for K-9 Mail or Thunderbird) by placing a custom config-v1.1.xml file in the /.well-known/autoconfig/mail/ directory of my domain's public_html.

The client correctly requests the file at https://mydomain.com/.well-known/autoconfig/mail/config-v1.1.xml, but it receives a "404 page not found" response. When accessing the file directly in a browser, it returns a 404 Page Not Found error.

After much troubleshooting, I found that DirectAdmin has added a statement causing all my issues.
ProxyPassMatch "^/\.well-known/autoconfig/mail/config-v1\.1\.xml$" "unix:/usr/local/directadmin/shared/internal.sock|http://localhost"
As a result, requests for the exact filename are intercepted and proxied, leading to the 404 when no internal configuration is available or applicable.

This prevents me from serving my own custom config-v1.1.xml file.

Is there a recommended way to disable or override this ProxyPassMatch directive globally (or per-domain) in DirectAdmin, so that static files in /.well-known/autoconfig/mail/ can be served directly from the filesystem?

Thank you!!!

DirectAdmin version 1.690
 
Hello,

It seems as of now there is only one option to disable the autodiscover from DirectAdmin. You will need to

1. copy corresponding templates of used webserver from the directory /usr/local/directadmin/data/templates/ to /usr/local/directadmin/data/templates/custom/
2. update templates in /usr/local/directadmin/data/templates/custom/
3. rewrite configs

Related:

- Apache: https://docs.directadmin.com/webservices/apache/customizing.html#using-a-custom-virtualhost-template
- Nginx: https://docs.directadmin.com/webser...html#using-custom-global-templates-with-nginx
- OpenLiteSpeed: https://docs.directadmin.com/webservices/openlitespeed/customizing-ols.html
 
Back
Top