Open calestyo opened 3 days ago
Way back in older OS versions there have been the two Services WANIPConn1
and WANIPConnection1
with partly overlapping functionality. So it could be that the description for WANIPConn1
has been silently removed in OS 8 by AVM. If this is the case there should be a fix, because this is a breaking change in FritzOS. This is not to hard, so hopefully I can care about it soon.
Would a complete dump of fritzconnection -c
help you?
It also seems that some of the properties might have changed. In some small Python test prog using the lib, I couldn’t find the external IPv6 address at all, and the IPv4 only in WANPPPConnection1
not WANIPConnection1
.
$ ptpython3
>>> import fritzconnection
>>> fc = fritzconnection.FritzConnection(address="foo",password="bar",user="baz")
I think currently in the code you use X_AVM_DE_GetExternalIPv6Address
,... but that no longer seems to exist:
>>> fc.call_action(service_name="WANIPConnection1",action_name="X_AVM_DE_GetExternalIPv6Address")
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "/usr/lib/python3/dist-packages/fritzconnection/core/fritzconnection.py", line 456, in call_action
return self.soaper.execute(service, action_name, arguments)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/lib/python3/dist-packages/fritzconnection/core/soaper.py", line 286, in execute
return handle_response(response)
^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/lib/python3/dist-packages/fritzconnection/core/soaper.py", line 268, in handle_response
raise_fritzconnection_error(response)
File "/usr/lib/python3/dist-packages/fritzconnection/core/soaper.py", line 191, in raise_fritzconnection_error
raise exception(message)
fritzconnection.core.exceptions.FritzActionError: UPnPError:
errorCode: 401
errorDescription: Invalid Action
Neither that:
>>> fc.call_action(service_name="WANIPConnection1",action_name="GetExternalIPAddress")
{'NewExternalIPAddress': ''}
I found the external IPv4 in WANPPPConnection1
:
>>> fc.call_action(service_name="WANPPPConnection1",action_name="GetInfo")
{'NewEnable': True, 'NewConnectionStatus': 'Connected', 'NewPossibleConnectionTypes': 'IP_Routed, IP_Bridged', 'NewConnectionType': 'IP_Routed', 'NewName': 'internet', 'NewUptime': 161144, 'NewUpstreamMaxBitRate': 36294339, 'NewDownstreamMaxBitRate': 29347045, 'NewLastConnectionError': 'ERROR_NONE', 'NewIdleDisconnectTime': 0, 'NewRSIPAvailable': False, 'NewUserName': 'foobar@setup.t-online.de', 'NewNATEnabled': True, 'NewExternalIPAddress': '1.2.3.4', 'NewDNSServers': '2003:180:2:7000::53, 2003:180:2:9000::53,217.237.151.115,217.237.148.102', 'NewMACAddress': '11:22:33:44:55:66', 'NewConnectionTrigger': 'AlwaysOn', 'NewLastAuthErrorInfo': '', 'NewMaxCharsUsername': 128, 'NewMinCharsUsername': 3, 'NewAllowedCharsUsername': '0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz-._@()#/%[]{}*+§$&=?!:;,', 'NewMaxCharsPassword': 64, 'NewMinCharsPassword': 3, 'NewAllowedCharsPassword': '0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz-._@()#/%[]{}*+§$&=?!:;,', 'NewTransportType': 'PPPoE', 'NewRouteProtocolRx': 'Off', 'NewPPPoEServiceName': '', 'NewRemoteIPAddress': '', 'NewPPPoEACName': 'MUNJ10', 'NewDNSEnabled': True, 'NewDNSOverrideAllowed': True}
But not in the counterpart in WANIPConnection1
:
>>> fc.call_action(service_name="WANIPConnection1",action_name="GetInfo")
{'NewEnable': True, 'NewConnectionStatus': 'Connecting', 'NewPossibleConnectionTypes': 'IP_Routed, IP_Bridged', 'NewConnectionType': 'IP_Routed', 'NewName': 'mstv', 'NewUptime': 0, 'NewLastConnectionError': 'ERROR_NONE', 'NewRSIPAvailable': False, 'NewNATEnabled': True, 'NewExternalIPAddress': '', 'NewDNSServers': '0.0.0.0, 0.0.0.0', 'NewMACAddress': '11:22:33:99:88:77', 'NewConnectionTrigger': 'AlwaysOn', 'NewRouteProtocolRx': 'Off', 'NewDNSEnabled': True, 'NewDNSOverrideAllowed': False}
Hey.
At least on my 7590 AX with version 8.0 it says:
There are however the following commands shown in introspection:
So I guess
WANIPConn1
was simply renamed toWANIPConnection1
?Similarly:
Looking in the code, these seem to use
WANIPConn
(**note that here the code doesn't have the trailing1
as above) but my FritzBox shows e.g. the following commands in introspection, e.g. for the external IP:So might be named differently in newer firmwares?
Thanks, Chris.