ui icon indicating copy to clipboard operation
ui copied to clipboard

Error displaying UI after logon

Open T-Felm-Lee opened this issue 3 years ago • 5 comments

Error is using v1.3.0 of the UI, kali linux 2022.3 installed direct. Local tested on KALI machine, online tested on my Windows machine using Chrome.

Local and online versions of the UI have the same error. It persists and repeats until the program is terminated or crashes.

ERROR TypeError: Cannot read properties of undefined (reading 'devices')
    at n.updateSession (main.ec83a59338123ba3bb5d.js:1:727637)
    at new n (main.ec83a59338123ba3bb5d.js:1:726698)
    at ji (main.ec83a59338123ba3bb5d.js:1:130429)
    at Ai (main.ec83a59338123ba3bb5d.js:1:129156)
    at po (main.ec83a59338123ba3bb5d.js:1:140679)
    at Object.oo [as createEmbeddedView] (main.ec83a59338123ba3bb5d.js:1:139389)
    at t.createEmbeddedView (main.ec83a59338123ba3bb5d.js:1:123753)
    at n.createEmbeddedView (main.ec83a59338123ba3bb5d.js:1:120435)
    at n._updateView (main.ec83a59338123ba3bb5d.js:1:184730)
    at n.set [as ngIf] (main.ec83a59338123ba3bb5d.js:1:184135)

I have done a full removal and re-install of bettercap and the ui caplet 3 times using CLI to make sure it was uncorrupted.

I am using CLI apt install bettercap after updating the list of available programs to install it. Then using sudo bettercap -eval "caplets.update; ui.update; q" to install the ui caplet.

I also tried ui.update while bettercap was already running no difference.

Let me know if you need any more info or need me to run tests.

Attached is a screen snip of the webpage after logon. error-bettercap-ui

T-Felm-Lee avatar Nov 09 '22 18:11 T-Felm-Lee

I'm facing the same issue on every-end-device I tried, thanks for opening this issue thread. Idk what's behind it but I'm guessing its might be caused by a certificate error issue coz at the ternminal end, it says - TLS handshake error, EOF and request : bad certificate - like these things.

My machine - Kali v2022.4 Bettercap - v2.32.0 UI - v1.3.0

Commands I used - sudo apt install bettercap caplets.update, ui.update (within bettercap) sudo bettercap -caplet http-ui/https-ui (both UI lands on the same above posted page)

whitefight18 avatar Nov 19 '22 09:11 whitefight18

So found a fix for this, provided by @konsumer & @AryanHere71 at - https://github.com/bettercap/ui/issues/81#issuecomment-1280048215 https://github.com/bettercap/bettercap/issues/958#issuecomment-1281476445

So it seems like the bettercap version found in the official Kali repo have some issues, and the current workaround is to manually build/compile the binary and run its web-ui.

whitefight18 avatar Nov 19 '22 10:11 whitefight18

You can also use the older (v2.31.1) pre-built binary here, if you don't want to build it with go.

konsumer avatar Nov 19 '22 10:11 konsumer

Yeah, that also works, but i did follow the manual compile method, and its working fine for now. Anyways, thank you man.

whitefight18 avatar Nov 19 '22 10:11 whitefight18

Good to see there is a workaround, thank you all for the information. I will update if I find anything else that works with the current build.

T-Felm-Lee avatar Nov 19 '22 13:11 T-Felm-Lee