filipre / dualis-request

Script that logs into Dualis and checks, whether something changed.
0 stars 0 forks source link

Link to thw script has changed: #1

Open lExplLicit opened 4 years ago

lExplLicit commented 4 years ago

Replace it with https://dualis.dhbw.de/scripts/mgrqispi.dll?

filipre commented 4 years ago

Yes, you are right. You probably want to rewrite the whole script since I don't have access to dualis anymore and there are more also convient ways to get notified than email (for example via Telegram). The browser's network debugger comes quite handy.

Curl command:

curl 'https://dualis.dhbw.de/scripts/mgrqispi.dll' -H 'User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.14; rv:69.0) Gecko/20100101 Firefox/69.0' -H 'Accept: text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8' -H 'Accept-Language: en-US,en;q=0.5' --compressed -H 'Referer: https://dualis.dhbw.de/' -H 'Content-Type: application/x-www-form-urlencoded' -H 'DNT: 1' -H 'Connection: keep-alive' -H 'Upgrade-Insecure-Requests: 1' --data 'usrname=admin&pass=admin&APPNAME=CampusNet&PRGNAME=LOGINCHECK&ARGUMENTS=clino%2Cusrname%2Cpass%2Cmenuno%2Cmenu_type%2Cbrowser%2Cplatform&clino=000000000000001&menuno=000324&menu_type=classic&browser=&platform='

Request Headers

POST /scripts/mgrqispi.dll HTTP/1.1
Host: dualis.dhbw.de
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.14; rv:69.0) Gecko/20100101 Firefox/69.0
Accept: text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8
Accept-Language: en-US,en;q=0.5
Accept-Encoding: gzip, deflate, br
Referer: https://dualis.dhbw.de/
Content-Type: application/x-www-form-urlencoded
Content-Length: 209
DNT: 1
Connection: keep-alive
Upgrade-Insecure-Requests: 1

JS Fetch

await fetch("https://dualis.dhbw.de/scripts/mgrqispi.dll", {
    "credentials": "omit",
    "headers": {
        "User-Agent": "Mozilla/5.0 (Macintosh; Intel Mac OS X 10.14; rv:69.0) Gecko/20100101 Firefox/69.0",
        "Accept": "text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8",
        "Accept-Language": "en-US,en;q=0.5",
        "Content-Type": "application/x-www-form-urlencoded",
        "Upgrade-Insecure-Requests": "1"
    },
    "referrer": "https://dualis.dhbw.de/",
    "body": "usrname=admin&pass=admin&APPNAME=CampusNet&PRGNAME=LOGINCHECK&ARGUMENTS=clino%2Cusrname%2Cpass%2Cmenuno%2Cmenu_type%2Cbrowser%2Cplatform&clino=000000000000001&menuno=000324&menu_type=classic&browser=&platform=",
    "method": "POST",
    "mode": "cors"
});