Skip to content
This repository has been archived by the owner on Mar 9, 2021. It is now read-only.

Authetication fail #6

Open
exylian opened this issue Jan 29, 2018 · 2 comments
Open

Authetication fail #6

exylian opened this issue Jan 29, 2018 · 2 comments

Comments

@exylian
Copy link

exylian commented Jan 29, 2018

Leider schlägt die Authentifizierung mit der FB fehl.

FB Login aktuell mit Passwort (Macht keinen Unterschied ob nur PW oder PW+User)
Beim versuch des Verbindungsaufbaus bekommt man jedoch eine 401 Antwort von der FB.

`
Service service = fritzConnection.getService("X_AVM-DE_OnTel:1");
Action action = service.getAction("GetPhonebookList");
try {
Response response = action.execute();

        System.out.println(response.getData());
    } catch (IOException e) {
        logger.error("IO Fehler", e);
    }

`

Löst folgende Exception aus
java.io.IOException: HTTP/1.1 401 Unauthorized at de.mapoll.javaAVMTR064.FritzConnection.httpRequest(FritzConnection.java:167) at de.mapoll.javaAVMTR064.FritzConnection.getSOAPXMLIS(FritzConnection.java:192) at de.mapoll.javaAVMTR064.Action.execute(Action.java:185) at de.mapoll.javaAVMTR064.Action.execute(Action.java:131)

Sobald der Login auf der FB deaktiviert wird, funktioniert alles Problemlos. Dies kann jedoch kein Zustand sein. Verständlicherweise.

@Zixxl
Copy link

Zixxl commented Feb 21, 2018

Es scheint so, dass die Anmeldung seit FRITZ!OS 5.50 jetzt über eine SessionID anstatt über Basic Authentication gelöst wird. Hier müssten ein par Dinge an der API geändert werden.

@Zixxl
Copy link

Zixxl commented Feb 22, 2018

Ich habe die API etwas abgeändert, so dass sie mit dem neuen Login verfahren arbeitet. Allerdings erhalte ich immer die Fehlermeldung "Invalid Action":

<?xml version="1.0"?>
<s:Envelope xmlns:s="http://schemas.xmlsoap.org/soap/envelope/" s:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/">
<s:Body>
<s:Fault>
<faultcode>s:Client</faultcode>
<faultstring>UPnPError</faultstring>
<detail>
<UPnPError xmlns="urn:schemas-upnp-org:control-1-0">
<errorCode>401</errorCode>
<errorDescription>Invalid Action</errorDescription>
</UPnPError>
</detail>
</s:Fault>
</s:Body>
</s:Envelope>

Bei anderen Projekten scheint es ähnliche Probleme zu geben, anscheinend ist die API bei der neuen Firmware nicht funktionsfähig.

/edit: In Verwendung eine vom Provider bereitgestellte FritzBox. Vielleicht ist die Funktion daher gesperrt.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants