Compare commits
4 Commits
v1.2.0-sta
...
master
Author | SHA1 | Date | |
---|---|---|---|
|
56f0a8dd64 | ||
|
c85e21231b | ||
|
6146f74c72 | ||
|
c2a03bfdcf |
13
Main.go
13
Main.go
@ -3,14 +3,17 @@ package main
|
||||
import (
|
||||
"fmt"
|
||||
"github.com/SommerEngineering/SSHTunnel/Tunnel"
|
||||
"github.com/howeyc/gopass"
|
||||
"golang.org/x/crypto/ssh"
|
||||
"log"
|
||||
"os"
|
||||
"runtime"
|
||||
)
|
||||
|
||||
func main() {
|
||||
|
||||
// Show the current version:
|
||||
fmt.Println(`SSHTunnel v1.2.0`)
|
||||
log.Println(`SSHTunnel v1.3.0`)
|
||||
|
||||
// Allow Go to use all CPUs:
|
||||
runtime.GOMAXPROCS(runtime.NumCPU())
|
||||
@ -23,7 +26,13 @@ func main() {
|
||||
if password == `` {
|
||||
// Promt for the password:
|
||||
fmt.Println(`Please provide the password for the connection:`)
|
||||
fmt.Scanln(&password)
|
||||
if pass, errPass := gopass.GetPasswd(); errPass != nil {
|
||||
log.Println(`There was an error reading the password securely: ` + errPass.Error())
|
||||
os.Exit(1)
|
||||
return
|
||||
} else {
|
||||
password = string(pass)
|
||||
}
|
||||
} else {
|
||||
break
|
||||
}
|
||||
|
@ -22,6 +22,7 @@ SSHTunnel is a tiny small program to tunnel something through a SSH without any
|
||||
- At the moment, SSHTunnel uses only the password authentication methods. Therefore, it is currently not possible to use e.g. a certificate, etc. Nevertheless, the implementation of this feature is possible.
|
||||
- The configuration must be provided by using the command-line arguments. It is currently not possible to use e.g. a configuration file.
|
||||
- You can avoid the password argument if you prefer to provide the password on demand.
|
||||
- [Ocean Remote Connections](https://github.com/SommerEngineering/OceanRemoteConnections) is a simple GUI for SSH Tunnel, PuTTY, RDP and WinSCP.
|
||||
|
||||
### Download
|
||||
Go and get the latest release from the [release page](https://github.com/SommerEngineering/SSHTunnel/releases).
|
||||
|
Loading…
Reference in New Issue
Block a user