Skip to content

Inner exception: 401 insufficient permissions #512

@lacerated

Description

@lacerated

I have LG C5 OLED firmware: 33.20.60
Everything worked fine for few months, but this week i reinstalled windows11 and updated TV to 33.20.60 after that installed CC again. Most of the functions work fine like Remote control, Game Bar and expert options, but not the power options like "Power off when locking the pc".
This is what log shows when click on "Test power on/off":

2025-07-04 11:48:46.6769|ERROR|LgTv.LgTvApiCoreCws|HandleMessage: status: Closed, exception: Cannot perform runtime binding on a null reference
   at CallSite.Target(Closure, CallSite, Object)
   at System.Dynamic.UpdateDelegates.UpdateAndExecute1[T0,TRet](CallSite site, T0 arg0)
   at CallSite.Target(Closure, CallSite, Object)
   at LgTv.LgTvApiCoreCws.HandleMessage(String message) in .\LgTv\LgTvConnectionCws.cs:line 203
2025-07-04 11:48:46.6769|DEBUG|LgTv.LgTvApiCoreCws|taskCompletion.Task.Status: Faulted
2025-07-04 11:48:46.6769|ERROR|LgTv.LgTvApiCoreCws|SetExceptionOnAllTokens: An attempt was made to transition a task to a final state when it had already completed.
2025-07-04 11:48:46.6769|DEBUG|LgTv.LgTvApi|Trying to connect with websocket uri: wss://192.168.88.237:3001
2025-07-04 11:48:50.4932|ERROR|ColorControl.Services.LG.LgDevice|Error while connecting to 192.168.88.237: Can't send message
Inner exception: 401 insufficient permissions
   at LgTv.LgTvApiCoreCws.SendCommandAsync(String id, String message) in .\LgTv\LgTvConnectionCws.cs:line 130
   at LgTv.LgTvApiCoreCws.SendCommandAsync(RequestMessage message) in .\LgTv\LgTvConnectionCws.cs:line 142
   at LgTv.LgTvApi.GetSystemInfo(String[] keys) in .\LgTv\LgTvApi.cs:line 605
   at ColorControl.Services.LG.LgDevice.Connect(Int32 retries) in .\Services\LG\LgDevice.cs:line 510
   at LgTv.LgTvApi.GetSystemInfo(String[] keys) in .\LgTv\LgTvApi.cs:line 605
   at LgTv.LgTvApiCoreCws.SendCommandAsync(RequestMessage message) in .\LgTv\LgTvConnectionCws.cs:line 142
   at LgTv.LgTvApiCoreCws.SendCommandAsync(String id, String message) in .\LgTv\LgTvConnectionCws.cs:line 126
   at LgTv.LgTvApiCoreCws.HandleMessage(String message) in .\LgTv\LgTvConnectionCws.cs:line 225
   at LgTv.LgTvApiCoreCws.Receive(Boolean singleResponse) in .\LgTv\LgTvConnectionCws.cs:line 182
   at ColorControl.MainWorker.DoWork() in .\MainWorker.cs:line 70
   at ColorControl.Program.RunApp(String[] args) in .\Program.cs:line 161
   at ColorControl.Program.MainAsync(String[] args) in .\Program.cs:line 77
   at ColorControl.Program.Main(String[] args) in .\Program.cs:line 56
2025-07-04 11:48:50.4932|DEBUG|ColorControl.Services.LG.LgDevice|Cannot apply LG-preset: no connection could be made
2025-07-04 11:49:02.2166|DEBUG|ColorControl.Shared.Services.WolService|Sending WOL packet to MAC-address E0-85-4D-8B-68-F2
2025-07-04 11:49:02.2269|DEBUG|ColorControl.Shared.Services.WolService|Broadcast WOL in network: Ethernet (Intel(R) Ethernet Controller I226-V), local address: 192.168.88.247, destination IP-address: 192.168.88.237

Tried different options like "Network IP control" on or off. Mobile TV On and can power on/off TV from smartphone. Quick Start+ is also on. If i'm using unsecure connection it shows:
2025-07-04 12:02:29.8371|ERROR|LgTv.LgTvApiCoreCws|Connect to ws://192.168.88.237:3000/: Unable to connect to the remote server

Any idea how to fix it?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions