コード例 #1
0
ファイル: KeyEncoder.cs プロジェクト: hellwolf/openchain
 public bool IsP2pkh(string address)
 {
     try
     {
         byte[] pubKeyHash = Base58CheckEncoding.Decode(address);
         if (pubKeyHash.Length != 21 || pubKeyHash[0] != versionByte)
         {
             return(false);
         }
         else
         {
             return(true);
         }
     }
     catch (FormatException)
     {
         return(false);
     }
 }