OSDN Git Service

Update to current version of Go library.
[pf3gnuchains/gcc-fork.git] / libgo / go / crypto / rsa / pkcs1v15_test.go
index 30a4824..d69bacf 100644 (file)
@@ -197,12 +197,6 @@ func TestVerifyPKCS1v15(t *testing.T) {
        }
 }
 
-func bigFromString(s string) *big.Int {
-       ret := new(big.Int)
-       ret.SetString(s, 10)
-       return ret
-}
-
 // In order to generate new test vectors you'll need the PEM form of this key:
 // -----BEGIN RSA PRIVATE KEY-----
 // MIIBOgIBAAJBALKZD0nEffqM1ACuak0bijtqE2QrI/KLADv7l3kK3ppMyCuLKoF0
@@ -216,10 +210,12 @@ func bigFromString(s string) *big.Int {
 
 var rsaPrivateKey = &PrivateKey{
        PublicKey: PublicKey{
-               N: bigFromString("9353930466774385905609975137998169297361893554149986716853295022578535724979677252958524466350471210367835187480748268864277464700638583474144061408845077"),
+               N: fromBase10("9353930466774385905609975137998169297361893554149986716853295022578535724979677252958524466350471210367835187480748268864277464700638583474144061408845077"),
                E: 65537,
        },
-       D: bigFromString("7266398431328116344057699379749222532279343923819063639497049039389899328538543087657733766554155839834519529439851673014800261285757759040931985506583861"),
-       P: bigFromString("98920366548084643601728869055592650835572950932266967461790948584315647051443"),
-       Q: bigFromString("94560208308847015747498523884063394671606671904944666360068158221458669711639"),
+       D: fromBase10("7266398431328116344057699379749222532279343923819063639497049039389899328538543087657733766554155839834519529439851673014800261285757759040931985506583861"),
+       Primes: []*big.Int{
+               fromBase10("98920366548084643601728869055592650835572950932266967461790948584315647051443"),
+               fromBase10("94560208308847015747498523884063394671606671904944666360068158221458669711639"),
+       },
 }