Example #1
0
        private bool verifyuser(ucommit ucom)
        {
            rsakey upbkey = ucom.getcert().getukey();
            string mess = ucom.getvendor() + "," + ucom.getcert().ToString() + "," + ucom.getc0().ToString() + "," + ucom.getD().ToString() + "," + ucom.getinfo();
            BigInteger messh = hashf.hash(mess);

            return rsa.verifySig(messh, ucom.getsigU(), upbkey);
        }
Example #2
0
        private bool verifyuser(ucommit ucom)
        {
            foreach(var it in clist)
                if (it.getuser() == ucom.getcert().getuser())
                {
                    rsakey upbkey = ucom.getcert().getukey();
                    string mess = ucom.getvendor() + "," + ucom.getcert().ToString() + "," + ucom.getc0().ToString() + "," + ucom.getD().ToString() + "," + ucom.getinfo();
                    BigInteger messh = hashf.hash(mess);

                    return rsa.verifySig(messh, ucom.getsigU(), upbkey);
                }
            return false;
        }