예제 #1
0
 private OcspReq(Asn1InputStream aIn)
 {
     try
     {
         this.req = OcspRequest.GetInstance(aIn.ReadObject());
     }
     catch (ArgumentException ex)
     {
         throw new IOException("malformed request: " + ex.Message);
     }
     catch (InvalidCastException ex2)
     {
         throw new IOException("malformed request: " + ex2.Message);
     }
 }
예제 #2
0
        private ITestResult SignedRequest()
        {
            try
            {
                OcspRequest req = OcspRequest.GetInstance(
                    Asn1Object.FromByteArray(signedReq));

                if (!Arrays.AreEqual(req.GetEncoded(), signedReq))
                {
                    return(new SimpleTestResult(false, Name + ": Ocsp signed request failed to re-encode"));
                }

                return(new SimpleTestResult(true, Name + ": Okay"));
            }
            catch (Exception e)
            {
                return(new SimpleTestResult(false, Name + ": failed signed exception - " + e.ToString(), e));
            }
        }
예제 #3
0
 private OcspReq(Asn1InputStream aIn)
 {
     //IL_001a: Expected O, but got Unknown
     //IL_002a: Unknown result type (might be due to invalid IL or missing references)
     //IL_0031: Expected O, but got Unknown
     //IL_0041: Unknown result type (might be due to invalid IL or missing references)
     try
     {
         req = OcspRequest.GetInstance(aIn.ReadObject());
     }
     catch (ArgumentException val)
     {
         ArgumentException val2 = val;
         throw new IOException("malformed request: " + ((global::System.Exception)(object) val2).get_Message());
     }
     catch (InvalidCastException val3)
     {
         InvalidCastException val4 = val3;
         throw new IOException("malformed request: " + ((global::System.Exception)(object) val4).get_Message());
     }
 }
예제 #4
0
 public OcspReq(
     OcspRequest req)
 {
     this.req = req;
 }