Discuss this help topic in SecureBlackbox Forum

TElX509Certificate.DetectCertFileFormat

TElX509Certificate     See also     


Filter: C#  VB.NET  Pascal  C++  PHP  Java  


Detects certificate format.

Declaration

[C#]
    static int DetectCertFileFormat(string FileName);
    static int DetectCertFileFormat(System.IO.Stream Stream);
    static int DetectCertFileFormat(byte[] Buffer, int Index, int Size);

[VB.NET]
    Shared Function DetectCertFileFormat(ByVal FileName As String) As Integer
    Shared Function DetectCertFileFormat(ByVal Stream As System.IO.Stream) As Integer
    Shared Function DetectCertFileFormat(ByVal Buffer As Byte(), ByVal Index As Integer, ByVal Size As Integer) As Integer

[Pascal]
    class function DetectCertFileFormat(FileName : string): TSBCertFileFormat;
    class function DetectCertFileFormat(Stream : TStream): TSBCertFileFormat;
    class function DetectCertFileFormat(Buffer : pointer; Size: integer): TSBCertFileFormat;

[C++]
    static TSBCertFileFormat DetectCertFileFormat(const std::string &FileName);
    static TSBCertFileFormat DetectCertFileFormat(TStream &Stream);
    static TSBCertFileFormat DetectCertFileFormat(TStream *Stream);
    static TSBCertFileFormat DetectCertFileFormat(void * Buffer, int32_t Size);

[PHP]
    integer DetectCertFileFormat(string $FileName)
    integer DetectCertFileFormat(TStream $Stream)
    integer DetectCertFileFormat(TSBPointer|array of byte|string|NULL $Buffer, integer $Size)

[Java]
    static int detectCertFileFormat(String FileName);
    static int detectCertFileFormat(InputStream Stream);
    static int detectCertFileFormat(byte[] Buffer, int Index, int Size);
    static int detectCertFileFormat(TElX509Certificate> this, TElStream Stream);

Parameters

  • FileName - name of the file containing certificate
  • Stream - stream containing certificate
  • Buffer - buffer containing certificate
  • Index - starting index of the certificate in Buffer
  • Size - size of the Buffer

Return value

    Returns the file format.

Possible values:

Description

    This method detects format of the certificate (PFX, PEM, DER, SPC).

See also:     DetectKeyFileFormat    

Discuss this help topic in SecureBlackbox Forum