[Mono-bugs] [Bug 457658] New: signcode cannot handle p7b certificates that contain a header/footer

bugzilla_noreply at novell.com bugzilla_noreply at novell.com
Tue Dec 9 11:36:28 EST 2008


           Summary: signcode cannot handle p7b certificates that contain a
           Product: Mono: Tools
           Version: 1.9
          Platform: All
        OS/Version: RHEL 5
            Status: NEW
          Severity: Normal
          Priority: P5 - None
         Component: tools
        AssignedTo: mono-bugs at lists.ximian.com
        ReportedBy: matthew.gertner at gmail.com
         QAContact: mono-bugs at lists.ximian.com
          Found By: ---

Some p7b certificates contain the text -----BEGIN PKCS7----- and -----END
PKCS7----- surrounding the base64 database. I tried to run signcode on a
certificate of this type with the following command:

signcode -spc <path to my p7b>

The following error was reported:

Unhandled Exception: System.FormatException: Invalid length.
 at <0x00000> <unknown method>
 at (wrapper managed-to-native)
System.Convert:InternalFromBase64String (string,bool)
 at System.Convert.FromBase64String (System.String s) [0x00000]
 at Mono.Security.Authenticode.SoftwarePublisherCertificate.CreateFromFile
(System.String filename) [0x00000]
 at Mono.Tools.SignCode.GetCertificates (System.String spcfile) [0x00000]
 at Mono.Tools.SignCode.Main (System.String[] args) [0x00000]

When the header/footer are removed, it works fine, but I think it should be
tolerant enough to handle certificates with the header/footer.

Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the QA contact for the bug.
You are the assignee for the bug.

More information about the mono-bugs mailing list