The app authenticates you directly against your OpenWrt router’s LuCI interface over HTTP. Before checking your credentials it first verifies the router is reachable, so any network problem is surfaced immediately. On success, the app stores a session cookie and the LuCIDocumentation Index
Fetch the complete documentation index at: https://mintlify.com/KevinCruz-cell/Redes-de-comunicaciones-/llms.txt
Use this file to discover all available pages before exploring further.
sysauth token so subsequent requests to protected routes work without re-authentication.
Session lifecycle
All routes except/login check for session('router_logged_in'). If that session key is absent or falsy, the request is redirected to /login. After a successful login the session holds:
| Key | Value |
|---|---|
router_logged_in | true |
router_ip | Router IP from ROUTER_IP env var (default 192.168.10.1) |
router_user | Username that was used to log in |
router_sysauth | LuCI sysauth cookie value |
router_location | Redirect Location header returned by LuCI |
POST /login
Authenticates the user against the router’s LuCI interface and creates a server-side session.The app first sends a
GET request to http://{ROUTER_IP}/cgi-bin/luci/ to confirm the router is online. If this probe fails, login is rejected with an error before credentials are even checked.Request
Submit as an HTML form (application/x-www-form-urlencoded) or include the fields in a JSON request body.
Username to authenticate with on the OpenWrt router. Typically
root.Password for the router account.
Responses
Success — redirects to/dhcp with the session established.
Router not reachable — redirects back with a validation error on the router key:
password key:
How authentication works internally
The app forwards credentials to the LuCI endpoint using the form fieldsluci_username and luci_password. LuCI responds with HTTP 302 and sets a sysauth cookie if the credentials are correct. The app extracts that cookie and stores it in the Laravel session for use in subsequent SSH-authenticated requests.
POST /logout
Clears all router session data and redirects to/login.
No request body is required. The following session keys are removed:
router_logged_inrouter_iprouter_userrouter_sysauthrouter_location
/login.
Protected route guard
Every protected view route uses an inline session check:/api/router/*, /api/router3/*, /sistema/*, and /administracion/* rely on the same session being present because the SSH connection is established server-side using the credentials stored at login time.