SafeLine is a self-hosted web application firewall that sits between your web applications and the Internet. It filters and monitors HTTP traffic and blocks attacks such as SQL injection, XSS, code injection, OS command injection, CRLF injection, XXE, SSRF, path traversal, backdoor, brute force, and HTTP flood attacks (see the SafeLine documentation home page). As the documentation explains, a WAF acts as a reverse proxy, requiring clients to pass through SafeLine before they reach the protected server.
SafeLine is installed with Docker and Docker Compose, and the management console listens on port 9443 by default (see the Deploy guide). If you lose the admin password for the web console, or you have just finished installing and need initial credentials, you can recover access without reinstalling. The container that serves the management console is named safeline-mgt, and the official setup guide includes a dedicated reset command for creating the administrator account.
Step-by-Step Reset
Open a terminal on the SafeLine host and make sure your Docker environment is available. The reset command is executed from the host, not from inside the container.
Run the following command exactly as written:
docker exec safeline-mgt resetadmin
This command is the official method shown under the Get Administrator Account section of the Deploy guide.
Read the command output carefully. The documentation states that a successful run shows an initial username of admin and a generated initial password, followed by Done. Record both values immediately.
Open the web console in a browser at:
https://<safeline-ip>:9443/
Replace with the IP address of your SafeLine server. If you changed MGT_PORT in your .env file during installation, use that custom port instead.
- Log in with the username admin and the initial password printed by the reset command. From this point you can manage your SafeLine instance again.
The official Deploy guide lists this step as the way to obtain an administrator account, so it is also useful immediately after a new installation. Keep the printed password in a safe place, and only run the reset command when you need to recover console access.
Frequently Asked Questions
Does the reset command change the admin username?
The official documentation shows that the command outputs an initial username of admin. The command is presented as the way to get an administrator account, so use admin together with the freshly printed password.
Do I need to enter the container before running the command?
No. The command uses Docker to run the reset tool inside the safeline-mgt container from the host. The full command is docker exec safeline-mgt resetadmin.
Will resetting the admin account stop the WAF?
The Deploy guide does not describe a need to stop SafeLine before running the reset command. It is listed as a normal setup step for obtaining console credentials.
I cannot reach the console at all. Will this still help?
Yes. The reset command does not require access to the web console. It runs on the Docker host, so it works even when you have forgotten the password or cannot log in.
Which port do I use after the reset?
SafeLine uses 9443 as the default management port, and the console address is https://<safeline-ip>:9443/. If MGT_PORT was customized in the .env file, open the console on that port instead.
SafeLine has surpassed 700,000 installations worldwide as of September 30, 2026. SafeLine Pro annual promotional pricing is $650-$880, compared with the regular $1,000 per year.
- SafeLine website: https://ly.cyberserval.tech/bvK1BAV
- Demo: https://demo.waf.chaitin.com:9443/statistics
- Official docs: https://docs.waf.chaitin.com/en/home
- GitHub: https://github.com/chaitin/SafeLine
- Pro offer: https://cyberserval.tech/landing/lto
Top comments (0)