Bettercap: Installation Problems

Created on 16 Mar 2020  路  6Comments  路  Source: bettercap/bettercap

Description of the bug or feature request

Environment

Please provide:

Version: Github Master Branch
OS: ElementaryOS
Go: 1.13.8
Cmd: go get -u github.com/bettercap/bettercap

Steps to Reproduce

run go "get -u github.com/bettercap/bettercap"

Expected behavior: What you expected to happen

Get Bettercap Compiled

Actual behavior: What actually happened

*# github.com/elazarl/goproxy
go/src/github.com/elazarl/goproxy/ctx.go:46:2: not enough arguments to return
go/src/github.com/elazarl/goproxy/ctx.go:46:12: ctx.proxy undefined (type *ProxyCtx has no field or method proxy, but does have Proxy)
go/src/github.com/elazarl/goproxy/ctx.go:50:5: ctx.proxy undefined (type *ProxyCtx has no field or method proxy, but does have Proxy)
go/src/github.com/elazarl/goproxy/ctx.go:62:8: ctx.proxy undefined (type *ProxyCtx has no field or method proxy, but does have Proxy)
go/src/github.com/elazarl/goproxy/https.go:76:69: unknown field 'proxy' in struct literal of type ProxyCtx (but does have Proxy)
go/src/github.com/elazarl/goproxy/https.go:199:77: unknown field 'proxy' in struct literal of type ProxyCtx (but does have Proxy)
go/src/github.com/elazarl/goproxy/proxy.go:105:70: unknown field 'proxy' in struct literal of type ProxyCtx (but does have Proxy)
*

I was compiled the master branch a weak ago with success. It's seems some compatibility problem with go proxy. Any hint?

Most helpful comment

The goproxy github shows that ctx.go was updated yesterday.

```shell script
certStore CertStorage
proxy *ProxyHttpServer
Proxy *ProxyHttpServer
}

Change in proxy to Proxy. 

**Edit:
Temporary band-aid fix:
```shell script
rm -rf ~/go/src/github.com/elazarl
go get github.com/elazarl/goproxy
vim ~/go/src/github.com/elazarl/goproxy/ctx.go
# :25
# Change Proxy to proxy

Then install bettercap

go get -u github.com/bettercap/bettercap

All 6 comments

The goproxy github shows that ctx.go was updated yesterday.

```shell script
certStore CertStorage
proxy *ProxyHttpServer
Proxy *ProxyHttpServer
}

Change in proxy to Proxy. 

**Edit:
Temporary band-aid fix:
```shell script
rm -rf ~/go/src/github.com/elazarl
go get github.com/elazarl/goproxy
vim ~/go/src/github.com/elazarl/goproxy/ctx.go
# :25
# Change Proxy to proxy

Then install bettercap

go get -u github.com/bettercap/bettercap

Thank you very much for your help!

I am not a go programmer, but I in the furture i will pay more attention to the changes made when using dev version.

Thanks!

Am I doing something incorrectly? When I do the second command you gave go get github.com/elazarl/goproxy @almostssh , I get the exact same errors that was given in the original post.

Any help would be really appreciated!

Thanks, @JJ5475 even with the same error, as @almostssh mentioned edit the ctx.go file and change Proxy to proxy in line #25, then launch again the go get with this time runs correctly.... then continue the install.

Hello, I have the same problem. I changed line 25 (proxy -> Proxy) but I still get the same error message.

  1. kali@kali:~$ sudo git clone https://github.com/elazarl/goproxy.git
  2. cd goproxy
  3. sudo nano ctx.go
    certStore CertStorage
    proxy *ProxyHttpServer
    Proxy *ProxyHttpServer
    }
  4. kali@kali:~/goproxy$ sudo go get -u github.com/bettercap/bettercap
    go: downloading github.com/bettercap/bettercap v2.24.1+incompatible
    go: github.com/bettercap/bettercap upgrade => v2.24.1+incompatible
    go: finding module for package github.com/evilsocket/islazy/str
    go: finding module for package github.com/evilsocket/islazy/tui

thnx.

Was this page helpful?
0 / 5 - 0 ratings