(country, proxy, ttl=NETWORK_BAD_PROXY_TTL)
| 7209 | send_json(self, 200, {'ok': True, 'authenticated': True, 'config': public_config(config)}, extra_headers=[('Set-Cookie', 'dedsec_os_auth=' + token + '; Path=/; HttpOnly; SameSite=Lax')]) |
| 7210 | return |
| 7211 | REQUEST_CONTEXT.username = current_request_username(self) |
| 7212 | if is_auth_enabled() and not is_request_authenticated(self): |
| 7213 | send_json(self, 401, {'ok': False, 'error': 'Authentication required.'}) |
| 7214 | return |
| 7215 | if route == '/api/terminal/run': |
| 7216 | session_id = payload.get('session_id') or 'web-shell' |
| 7217 | session = run_web_shell_command(session_id, payload.get('command', '')) |
| 7218 | send_json(self, 200, {'ok': True, 'session': session}) |
| 7219 | return |
| 7220 | if route == '/api/terminal/input': |
| 7221 | session_id = payload.get('session_id') or 'web-shell' |
no test coverage detected