| Server IP : 202.61.199.114 / Your IP : 216.73.217.139 Web Server : nginx/1.22.1 System : Linux de.arni-solutions.de 6.1.0-49-amd64 #1 SMP PREEMPT_DYNAMIC Debian 6.1.174-1 (2026-05-26) x86_64 User : web20 ( 1018) PHP Version : 8.4.23 Disable Function : NONE MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : OFF | Sudo : ON | Pkexec : ON Directory : /proc/3951573/root/tmp/ |
Upload File : |
from playwright.sync_api import sync_playwright
BASE="https://www.parkinglist.de/ParkingDashboard"
USER="service@parken-am-schiff.de"; PW="BYx63wLLxP"
UA="Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/120.0.0.0 Safari/537.36"
STEALTH="Object.defineProperty(navigator,'webdriver',{get:()=>undefined});window.chrome={runtime:{}};Object.defineProperty(navigator,'languages',{get:()=>['de-DE','de','en']});Object.defineProperty(navigator,'plugins',{get:()=>[1,2,3]});"
status={"v":None}
with sync_playwright() as p:
b=p.chromium.launch(headless=True,args=["--no-sandbox","--disable-blink-features=AutomationControlled"])
ctx=b.new_context(user_agent=UA,locale="de-DE",viewport={"width":1440,"height":960})
ctx.add_init_script(STEALTH)
pg=ctx.new_page()
def onr(r):
if r.url.endswith("login.xhtml") and r.request.method=="POST":
status["v"]=r.status; print("LOGIN POST ->",r.status)
pg.on("response",onr)
pg.goto(f"{BASE}/login.xhtml",wait_until="networkidle",timeout=60000)
print("warming up 20s..."); pg.wait_for_timeout(20000)
pg.fill("#username",USER); pg.fill("#password",PW)
for attempt in range(3):
status["v"]=None
pg.click("#login"); pg.wait_for_timeout(7000)
print(f"attempt {attempt}: post={status['v']} url={pg.url}")
if "login.xhtml" not in pg.url or (status["v"] and status["v"]==200):
break
pg.wait_for_timeout(6000)
print("FINAL url:",pg.url," title:",pg.title())
print("BODY:",pg.inner_text("body")[:400].replace("\n"," | "))
b.close()