francoismichel / francoismichel/ssh3

Unable to install on Termux

Open
#119 3 comments 0 reactions 0 assignees View on GitHub
bug
Dominant language
Go
Stars
5k
Forks
118
PR merge metrics
No merged PRs in 30d

Description

Hello, I hope you're doing well.

I encountered an issue while trying to install ssh3 on Termux(aarch64) using the provided installation command(`go install github.com/francoismichel/ssh3/cmd/...@latest`), the installation fails with the following error:

`fatal error: 'shadow.h' file not found`

Complete Output on Termux

```
go: downloading github.com/francoismichel/ssh3 v0.1.6
go: downloading github.com/kevinburke/ssh_config v1.2.0
go: downloading github.com/quic-go/quic-go v0.40.1-0.20240102075208-1083d1fb8f98
go: downloading github.com/rs/zerolog v1.31.0
go: downloading golang.org/x/crypto v0.17.0
go: downloading github.com/caddyserver/certmagic v0.20.0
go: downloading github.com/creack/pty v1.1.18
go: downloading go.uber.org/zap v1.24.0
go: downloading github.com/coreos/go-oidc/v3 v3.7.0
go: downloading golang.org/x/oauth2 v0.13.0
go: downloading golang.org/x/term v0.15.0
go: downloading github.com/golang-jwt/jwt/v5 v5.0.0
go: downloading golang.org/x/exp v0.0.0-20221205204356-47842c84f3db
go: downloading github.com/klauspost/cpuid/v2 v2.2.5
go: downloading github.com/libdns/libdns v0.2.1
go: downloading github.com/mholt/acmez v1.2.0
go: downloading github.com/miekg/dns v1.1.55
go: downloading github.com/zeebo/blake3 v0.2.3
go: downloading golang.org/x/net v0.17.0
go: downloading github.com/quic-go/qpack v0.4.0
go: downloading golang.org/x/sys v0.15.0
go: downloading go.uber.org/atomic v1.11.0
go: downloading go.uber.org/multierr v1.11.0
go: downloading github.com/go-jose/go-jose/v3 v3.0.1
go: downloading github.com/mattn/go-isatty v0.0.19
go: downloading golang.org/x/text v0.14.0
# github.com/francoismichel/ssh3/util/unix_util
../../go/pkg/mod/github.com/francoismichel/ssh3@v0.1.6/util/unix_util/linux_user.go:11:10: fatal error: 'shadow.h' file not found
11 | #include
| ^~~~~~~~~~
1 error generated.
```

Attempted to resolve the issue by creating a proot-distro Alpine Linux environment using:

```bash
proot-distro install --override-alias alpine1 alpine
proot-distro login alpine1 --isolated
```

But, The installation still fails with the following error:

```
undefined: userPasswordAuthentication
undefined: passwordAuthAvailable
```

Complete Output on Termux using proot-distro command

```
go: downloading github.com/francoismichel/ssh3 v0.1.6
go: downloading github.com/creack/pty v1.1.18
go: downloading github.com/quic-go/quic-go v0.40.1-0.20240102075208-1083d1fb8f98
go: downloading github.com/rs/zerolog v1.31.0
go: downloading github.com/caddyserver/certmagic v0.20.0
go: downloading go.uber.org/zap v1.24.0
go: downloading github.com/kevinburke/ssh_config v1.2.0
go: downloading golang.org/x/crypto v0.17.0
go: downloading github.com/golang-jwt/jwt/v5 v5.0.0
go: downloading golang.org/x/exp v0.0.0-20221205204356-47842c84f3db
go: downloading github.com/klauspost/cpuid/v2 v2.2.5
go: downloading github.com/libdns/libdns v0.2.1
go: downloading github.com/mholt/acmez v1.2.0
go: downloading github.com/miekg/dns v1.1.55
go: downloading github.com/zeebo/blake3 v0.2.3
go: downloading golang.org/x/net v0.17.0
go: downloading github.com/mattn/go-colorable v0.1.13
go: downloading github.com/coreos/go-oidc/v3 v3.7.0
go: downloading golang.org/x/oauth2 v0.13.0
go: downloading golang.org/x/term v0.15.0
go: downloading go.uber.org/atomic v1.11.0
go: downloading go.uber.org/multierr v1.11.0
go: downloading golang.org/x/sys v0.15.0
go: downloading github.com/quic-go/qpack v0.4.0
go: downloading github.com/go-jose/go-jose/v3 v3.0.1
go: downloading github.com/mattn/go-isatty v0.0.19
go: downloading golang.org/x/text v0.14.0
# github.com/francoismichel/ssh3/util/unix_util
go/pkg/mod/github.com/francoismichel/ssh3@v0.1.6/util/unix_util/user.go:20:9: undefined: getUser
go/pkg/mod/github.com/francoismichel/ssh3@v0.1.6/util/unix_util/user.go:87:9: undefined: userPasswordAuthentication
go/pkg/mod/github.com/francoismichel/ssh3@v0.1.6/util/unix_util/user.go:91:9: undefined: passwordAuthAvailable
localhost:~# echo error $?
error 1
```


Contributor guide

No contributing guide indexed for this repository

Research direction

Reproduce the reported `go install github.com/francoismichel/ssh3/cmd/...@latest` command on Termux and in the Alpine proot environment. Inspect `util/unix_util/linux_user.go` and `util/unix_util/user.go`, focusing on the missing `shadow.h`, `getUser`, `userPasswordAuthentication`, and `passwordAuthAvailable` symbols. Done means the installation succeeds in the reported environments or the supported-platform limitation is documented.

Written by the indexing model from the issue text.

Assessment

Tech stack
go, linux
Domain
build-system, operating-systems
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
28/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.