HomeAssistant-PeugeotIntegration icon indicating copy to clipboard operation
HomeAssistant-PeugeotIntegration copied to clipboard

After adding DuckDsn, psa control no longer works, gives certificate error in add-on

Open wingmanx opened this issue 1 year ago • 17 comments

After adding DuckDsn, psa control no longer works, gives certificate error in add-on. I can see the Summary, Trips, Charge, but the "Control" where is the battery state and other sensors no longer works. Everything worked before, and also a few days after having DuckDns. To check for connection, used to place the address in address bar like this: https://192.168.0.10:5000/get_vehicleinfo/<VIN>

Now it says in the browser:

Secure Connection Failed

An error occurred during a connection to 192.168.0.10:5000. SSL received a record that exceeded the maximum permissible length.

Error code: SSL_ERROR_RX_RECORD_TOO_LONG

The page you are trying to view cannot be shown because the authenticity of the received data could not be verified.

wingmanx avatar Nov 24 '23 09:11 wingmanx

Have you tried http://192.168.0.10:5000/get_vehicleinfo/ You won't be able to use https with an IP unless your certificate is also named 192.168.0.10

HTH

iendicott avatar Nov 24 '23 15:11 iendicott

Seems the entire integration has gone down?  From RobertSent from my iPhone On 24 Nov 2023, at 15:09, Ivan Endicott @.***> wrote: Have you tried http://192.168.0.10:5000/get_vehicleinfo/ You won't be able to use https with an IP unless your certificate is also named 192.168.0.10 HTH

—Reply to this email directly, view it on GitHub, or unsubscribe.You are receiving this because you are subscribed to this thread.Message ID: @.***>

boab21mac avatar Nov 24 '23 15:11 boab21mac

Capture Yes just looked on my dashboard seems mine has gone as well.

iendicott avatar Nov 24 '23 15:11 iendicott

From RobertSent from my iPhone On 24 Nov 2023, at 15:23, Ivan Endicott @.***> wrote: Yes just looked on my dashboard seems mine has gone as well.

—Reply to this email directly, view it on GitHub, or unsubscribe.You are receiving this because you commented.Message ID: @.***>

boab21mac avatar Nov 24 '23 15:11 boab21mac

Yup. Mine too :(

BrunoN17 avatar Nov 24 '23 15:11 BrunoN17

http://192.168.0.10:5000/get_vehicleinfo/ shows the car summary without any values.

http://192.168.0.10:5000/get_vehicleinfo/<VIN> gives: Internal Server Error The server encountered an internal error and was unable to complete your request. Either the server is overloaded or there is an error in the application.

With DuckDns I can no longer access http in the home network, only through https.

wingmanx avatar Nov 24 '23 23:11 wingmanx

Well, just updated PSA Car Controller from version 3.1.0 to the new 3.2.0 and it working again!!!

wingmanx avatar Nov 25 '23 23:11 wingmanx

I too can confirm 3.2.0 fixes the issue. Massive thanks to the developer for fixing this.

iendicott avatar Nov 26 '23 16:11 iendicott

Agreed working!!Great job!!From RobertSent from my iPhone On 26 Nov 2023, at 16:05, Ivan Endicott @.***> wrote: I too can confirm 3.2.0 fixes the issue. Massive thanks to the developer for fixing this.

—Reply to this email directly, view it on GitHub, or unsubscribe.You are receiving this because you commented.Message ID: @.***>

boab21mac avatar Nov 26 '23 16:11 boab21mac

Hi guys. Is your PSA add-on still working? Since yesterday, I've lost access to the PSA info in the add on. When I try to configure again it says:Traceback (most recent call last): File "/usr/local/lib/python3.9/dist-packages/psa_car_controller/psa/setup/app_decoder.py", line 50, in firstLaunchConfig token = res.json()["accessToken"] KeyError: 'accessToken' HOST_BRANDID : https://id-dcr.peugeot.com/mobile-services sitecode: AP_PT_ESP{"session":"332325c85601d6b849db5353b03b4c0d","returnCode":"NEED_AUTHORIZATION"," ..................

wingmanx avatar Jan 04 '24 09:01 wingmanx

Yes working for me. I am guessing it might be worth re-running through the user config within the "PSA Car Controller" plugin based on the last part of the message "NEED_AUTHORIZATION" ?

iendicott avatar Jan 04 '24 09:01 iendicott

This message I've shared, appears when I run the add-on, user config, insert the login data and click "submit" ... So, this time instead of selecting PT, I've selected GB and it worked! So, all working again.

wingmanx avatar Jan 04 '24 21:01 wingmanx

Hi guys ... Yesterday I've lost access to PSA in HA. I've tried again to login with GB option, but now it says: "400 - server_error : Internal Server Error"

All the other options don't work, FR, PT, PL, and a few more ... They all give this error: Traceback (most recent call last): File "/usr/local/lib/python3.9/dist-packages/psa_car_controller/psa/setup/app_decoder.py", line 50, in firstLaunchConfig token = res.json()["accessToken"] KeyError: 'accessToken' HOST_BRANDID : https://id-dcr.peugeot.com/mobile-services sitecode: AP_PT_ESP{"session":"6c2808580c93d727871bb4a84fee4e0e","returnCode":"NEED_AUTHORIZATION","token":"92757xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx","fields":{"USR_PASSWORD":"SETPWD_LABEL_8"}}

I believe this happened after the last HA Core update to 2024.2.2

wingmanx avatar Feb 19 '24 20:02 wingmanx

Guys, are you PSA Add-on working? My says this in the log:

File "/usr/local/lib/python3.9/dist-packages/psa_car_controller/psa/connected_car_api/api/vehicles_api.py", line 1229, in get_vehicle_status (data) = self.get_vehicle_status_with_http_info(id, **kwargs) # noqa: E501 File "/usr/local/lib/python3.9/dist-packages/psa_car_controller/psa/connected_car_api/api/vehicles_api.py", line 1293, in get_vehicle_status_with_http_info return self.api_client.call_api( File "/usr/local/lib/python3.9/dist-packages/psa_car_controller/psa/oauth.py", line 109, in call_api return self._ApiClient__call_api(resource_path, method, File "/usr/local/lib/python3.9/dist-packages/psa_car_controller/psa/connected_car_api/api_client.py", line 147, in __call_api self.update_params_for_auth(header_params, query_params, auth_settings) File "/usr/local/lib/python3.9/dist-packages/psa_car_controller/psa/connected_car_api/api_client.py", line 504, in update_params_for_auth auth_setting = self.configuration.auth_settings().get(auth) File "/usr/local/lib/python3.9/dist-packages/psa_car_controller/psa/connected_car_api/configuration.py", line 241, in auth_settings 'value': 'Bearer ' + self.access_token TypeError: can only concatenate str (not "NoneType") to str

wingmanx avatar Feb 24 '24 18:02 wingmanx

Nope still not working, some people have had luck doing a work around but way over my head!From RobertSent from my iPhone On 24 Feb 2024, at 18:59, wingmanx @.***> wrote: Guys, are you PSA Add-on working? My says this in the log: File "/usr/local/lib/python3.9/dist-packages/psa_car_controller/psa/connected_car_api/api/vehicles_api.py", line 1229, in get_vehicle_status (data) = self.get_vehicle_status_with_http_info(id, **kwargs) # noqa: E501 File "/usr/local/lib/python3.9/dist-packages/psa_car_controller/psa/connected_car_api/api/vehicles_api.py", line 1293, in get_vehicle_status_with_http_info return self.api_client.call_api( File "/usr/local/lib/python3.9/dist-packages/psa_car_controller/psa/oauth.py", line 109, in call_api return self._ApiClient__call_api(resource_path, method, File "/usr/local/lib/python3.9/dist-packages/psa_car_controller/psa/connected_car_api/api_client.py", line 147, in __call_api self.update_params_for_auth(header_params, query_params, auth_settings) File "/usr/local/lib/python3.9/dist-packages/psa_car_controller/psa/connected_car_api/api_client.py", line 504, in update_params_for_auth auth_setting = self.configuration.auth_settings().get(auth) File "/usr/local/lib/python3.9/dist-packages/psa_car_controller/psa/connected_car_api/configuration.py", line 241, in auth_settings 'value': 'Bearer ' + self.access_token TypeError: can only concatenate str (not "NoneType") to str

—Reply to this email directly, view it on GitHub, or unsubscribe.You are receiving this because you commented.Message ID: @.***>

boab21mac avatar Feb 24 '24 19:02 boab21mac

Even when I risk to say the same thing again and again... This is nothing @Flodu31 can help you. If you want to report these problems to the right person, go to flobz' repo. But on this case I hope this one will fix our problems. https://github.com/flobz/psa_car_controller/pull/772

dreimer1986 avatar Feb 25 '24 01:02 dreimer1986

Thanks, working now.

wingmanx avatar Feb 29 '24 19:02 wingmanx