| 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 : /tmp/ |
Upload File : |
from playwright.sync_api import sync_playwright
from playwright_stealth import stealth_sync
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"
st={"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})
pg=ctx.new_page()
stealth_sync(pg)
pg.on("response",lambda r:(r.url.endswith("login.xhtml") and r.request.method=="POST") and st.update(v=r.status) or (r.url.endswith("login.xhtml") and r.request.method=="POST" and print("POST->",r.status)))
pg.goto(f"{BASE}/login.xhtml",wait_until="networkidle",timeout=60000)
pg.wait_for_timeout(12000)
print("webdriver:",pg.evaluate("()=>navigator.webdriver"))
pg.fill("#username",USER); pg.fill("#password",PW)
for a in range(3):
st["v"]=None; pg.click("#login"); pg.wait_for_timeout(7000)
print("attempt",a,"post=",st["v"],"url=",pg.url)
if "login.xhtml" not in pg.url: break
pg.wait_for_timeout(5000)
print("FINAL:",pg.url,"|",pg.title())
print("BODY:",pg.inner_text("body")[:400].replace("\n"," | "))
if "login.xhtml" not in pg.url: ctx.storage_state(path="/tmp/pl_state.json")
b.close()