我正在尝试获取rsa.PublicKey的对象,并执行了以下步骤:----BEGINRSAPUBLICKEY----....----ENDRSAPUBLICKEY----packagemainimport("crypto/rand""crypto/rsa""crypto/x509""encoding/pem""fmt""io/ioutil")funcmain(){key,err:=ioutil.ReadFile("./new_public.pem")iferr!=nil{fmt.Println(err.Error())}block,_:=pem.Decode([]byte(key))i
我正在尝试获取rsa.PublicKey的对象,并执行了以下步骤:----BEGINRSAPUBLICKEY----....----ENDRSAPUBLICKEY----packagemainimport("crypto/rand""crypto/rsa""crypto/x509""encoding/pem""fmt""io/ioutil")funcmain(){key,err:=ioutil.ReadFile("./new_public.pem")iferr!=nil{fmt.Println(err.Error())}block,_:=pem.Decode([]byte(key))i