]> Cypherpunks.ru repositories - govpn.git/blobdiff - src/govpn/cmd/govpn-verifier/main.go
Raise copyright years
[govpn.git] / src / govpn / cmd / govpn-verifier / main.go
index 1757e1e183976a6e16b36dbb3c6cf21373689b0e..5a62b220f34efade316e812f0aa914bca22bee88 100644 (file)
@@ -1,6 +1,6 @@
 /*
 GoVPN -- simple secure free software virtual private network daemon
-Copyright (C) 2014-2015 Sergey Matveev <stargrave@stargrave.org>
+Copyright (C) 2014-2016 Sergey Matveev <stargrave@stargrave.org>
 
 This program is free software: you can redistribute it and/or modify
 it under the terms of the GNU General Public License as published by
@@ -55,6 +55,9 @@ func main() {
        if err != nil {
                log.Fatalln("Can not decode verifier", err)
        }
+       if v.Pub == nil {
+               log.Fatalln("Verifier does not contain public key")
+       }
        pub := *v.Pub
        v.PasswordApply(govpn.StringFromFile(*keyPath))
        fmt.Println(subtle.ConstantTimeCompare(v.Pub[:], pub[:]) == 1)