author | Alberto Bertogli
<albertito@blitiri.com.ar> 2015-10-24 23:55:46 UTC |
committer | Alberto Bertogli
<albertito@blitiri.com.ar> 2015-10-25 00:01:01 UTC |
parent | bcdf947e1d75c1f71a0a80c06a876e9dbcb5969c |
remoteu2f-cli/main.go | +5 | -2 |
diff --git a/remoteu2f-cli/main.go b/remoteu2f-cli/main.go index d66123c..3c4a156 100644 --- a/remoteu2f-cli/main.go +++ b/remoteu2f-cli/main.go @@ -334,8 +334,11 @@ func PAM(ctx *cli.Context) { c := mustGRPCClient(conf.Addr, conf.Token, ctx.GlobalString("ca_file")) - user, hostname := mustUserInfo() - msg := fmt.Sprintf("%s@%s", user, hostname) + hostname, err := os.Hostname() + if err != nil { + fatalf("Error getting hostname: %v", err) + } + msg := fmt.Sprintf("%s@%s", username, hostname) pa, err := c.PrepareAuthentication( msg, conf.AppID, conf.RegistrationValues())