CMS Flags/Constants

The CMS functions make use of flags which are specified using a bitfield which can include one or more of the following values:

CMS CONSTANTS
Constant Description
OPENSSL_CMS_TEXT Adds text/plain content type headers to encrypted/signed message. If decrypting or verifying, it strips those headers from the output - if the decrypted or verified message is not of MIME type text/plain then an error will occur.
OPENSSL_CMS_BINARY Normally the input message is converted to "canonical" format which is effectively using CR and LF as end of line: as required by the CMS specification. When this option is present, no translation occurs. This is useful when handling binary data which may not be in CMS format.
OPENSSL_CMS_NOINTERN When verifying a message, certificates (if any) included in the message are normally searched for the signing certificate. With this option only the certificates specified in the untrusted_certificates_filename parameter of openssl_cms_verify() are used. The supplied certificates can still be used as untrusted CAs however.
OPENSSL_CMS_NOVERIFY Do not verify the signers certificate of a signed message.
OPENSSL_CMS_NOCERTS When signing a message the signer's certificate is normally included - with this option it is excluded. This will reduce the size of the signed message but the verifier must have a copy of the signers certificate available locally (passed using the untrusted_certificates_filename to openssl_cms_verify() for example).
OPENSSL_CMS_NOATTR Normally when a message is signed, a set of attributes are included which include the signing time and the supported symmetric algorithms. With this option they are not included.
OPENSSL_CMS_DETACHED When signing a message, use cleartext signing with the MIME type "multipart/signed". This is the default if you do not specify any flags to openssl_cms_sign(). If you turn this option off, the message will be signed using opaque signing, which is more resistant to translation by mail relays but cannot be read by mail agents that do not support S/MIME.
OPENSSL_CMS_NOSIGS Don't try and verify the signatures on a message

Here you can write a comment


Please enter at least 10 characters.
Loading... Please wait.
* Pflichtangabe
There are no comments available yet.

PHP cURL Tutorial: Using cURL to Make HTTP Requests

cURL is a powerful PHP extension that allows you to communicate with different servers using various protocols, including HTTP, HTTPS, FTP, and more. ...

TheMax

Autor : TheMax
Category: PHP-Tutorials

Midjourney Tutorial - Instructions for beginners

There is an informative video about Midjourney, the tool for creating digital images using artificial intelligence, entitled "Midjourney tutorial in German - instructions for beginners" ...

Mike94

Autor : Mike94
Category: KI Tutorials

Basics of views in MySQL

Views in a MySQL database offer the option of creating a virtual table based on the result of an SQL query. This virtual table can be queried like a normal table without changing the underlying data. ...

admin

Autor : admin
Category: mySQL-Tutorials

Publish a tutorial

Share your knowledge with other developers worldwide

Share your knowledge with other developers worldwide

You are a professional in your field and want to share your knowledge, then sign up now and share it with our PHP community

learn more

Publish a tutorial