Classes

Method HttpEndpoint():setCertificateFromFile() Professional

Binds a server certificate from a file for SSL connections.

Syntax
:setCertificateFromFile( <cFilename>[, cPassword] ) --> lSuccess
Parameters
<cFilename>
<cFilename> is a character string containing the name of the certificate file to be loaded
<cPassword>
<cPassword> is the password required to decrypt the certificate file.
Return

The logical value true (.T.), if a server certificate is successfully loaded. Otherwise, the value false (.F.) is returned.

Description

The method :setCertificateFromFile() binds a server certificate to this HttpEndPoint instance and allows clients to connect via SSL.

The certificate file cFilename must be in PKCS #12 format (Personal Information Exchange Syntax v1.1) and usually has the file extension .pfx or .p12. The method :setCertificateFromFile() selects the first certificate which is suitable for server authentication.

If the certificate was created without a password, the parameter <cPassword> can be ignored. Otherwise, the password that was used to protect the certificate file must be passed in the parameter <cPassword>.

Feedback

If you see anything in the documentation that is not correct, does not match your experience with the particular feature or requires further clarification, please use this form to report a documentation issue.