MongoDB\Driver\ClientEncryption::encrypt

(mongodb >=1.7.0)

MongoDB\Driver\ClientEncryption::encryptEncrypt a value

Beschreibung

final public MongoDB\Driver\ClientEncryption::encrypt(mixed $value, array $options = ?): MongoDB\BSON\Binary

Encrypts the value.

Parameter-Liste

value

The value to be encrypted. Any value that can be inserted into MongoDB can be encrypted using this method.

options

Encryption options
Option Type Description
algorithm string

The encryption algorithm to be used. This option is required. Specify one of the following ClientEncryption constants:

  • MongoDB\Driver\ClientEncryption::AEAD_AES_256_CBC_HMAC_SHA_512_DETERMINISTIC
  • MongoDB\Driver\ClientEncryption::AEAD_AES_256_CBC_HMAC_SHA_512_RANDOM
  • MongoDB\Driver\ClientEncryption::ALGORITHM_INDEXED
  • MongoDB\Driver\ClientEncryption::ALGORITHM_UNINDEXED
contentionFactor int

The contention factor for evaluating queries with indexed, encrypted payloads.

This option only applies and may only be specified when algorithm is MongoDB\Driver\ClientEncryption::ALGORITHM_INDEXED.

Hinweis: Queryable Encryption is in public preview and available for evaluation purposes. It is not yet recommended for production deployments as breaking changes may be introduced. See the » Queryable Encryption Preview blog post for more information.

keyAltName string

Identifies a key vault collection document by keyAltName. This option is mutually exclusive with keyId and exactly one is required.

keyId MongoDB\BSON\Binary

Identifies a data key by _id. The value is a UUID (binary subtype 4). This option is mutually exclusive with keyAltName and exactly one is required.

queryType int

The query type for evaluating queries with indexed, encrypted payloads. Specify one of the following ClientEncryption constants:

  • MongoDB\Driver\ClientEncryption::QUERY_TYPE_EQUALITY

This option only applies and may only be specified when algorithm is MongoDB\Driver\ClientEncryption::ALGORITHM_INDEXED.

Hinweis: Queryable Encryption is in public preview and available for evaluation purposes. It is not yet recommended for production deployments as breaking changes may be introduced. See the » Queryable Encryption Preview blog post for more information.

Rückgabewerte

Returns the encrypted value as MongoDB\BSON\Binary object with subtype 6.

Fehler/Exceptions

Changelog

Version Beschreibung
PECL mongodb 1.14.0 Added the "contentionFactor" and "queryType" options.

Siehe auch

Hier Kannst Du einen Kommentar verfassen


Bitte gib mindestens 10 Zeichen ein.
Wird geladen... Bitte warte.
* Pflichtangabe
Es sind noch keine Kommentare vorhanden.

PHP cURL-Tutorial: Verwendung von cURL zum Durchführen von HTTP-Anfragen

cURL ist eine leistungsstarke PHP-Erweiterung, die es Ihnen ermöglicht, mit verschiedenen Servern über verschiedene Protokolle wie HTTP, HTTPS, FTP und mehr zu kommunizieren. ...

TheMax

Autor : TheMax
Kategorie: PHP-Tutorials

Midjourney Tutorial - Anleitung für Anfänger

Über Midjourney, dem Tool zur Erstellung digitaler Bilder mithilfe von künstlicher Intelligenz, gibt es ein informatives Video mit dem Titel "Midjourney Tutorial auf Deutsch - Anleitung für Anfänger" ...

Mike94

Autor : Mike94
Kategorie: KI Tutorials

Grundlagen von Views in MySQL

Views in einer MySQL-Datenbank bieten die Möglichkeit, eine virtuelle Tabelle basierend auf dem Ergebnis einer SQL-Abfrage zu erstellen. ...

admin

Autor : admin
Kategorie: mySQL-Tutorials

Tutorial veröffentlichen

Tutorial veröffentlichen

Teile Dein Wissen mit anderen Entwicklern weltweit

Du bist Profi in deinem Bereich und möchtest dein Wissen teilen, dann melde dich jetzt an und teile es mit unserer PHP-Community

mehr erfahren

Tutorial veröffentlichen

Daten einer Abfrage mit Hilfe von Thumbnails nebeneinander ausgeben

Also den Fehler habe ich gefunden und abgestellt. Warum soll ich float meiden?

Geschrieben von Malchor am 17.05.2024 20:54:01
Forum: PHP Developer Forum
Daten einer Abfrage mit Hilfe von Thumbnails nebeneinander ausgeben

Dein HTML-Code ist definitiv kaputt und float solltest du auch vergessen. Beschäftige dich mit Flex-Box oder Grid

Geschrieben von scatello am 17.05.2024 20:43:50
Forum: PHP Developer Forum
Daten einer Abfrage mit Hilfe von Thumbnails nebeneinander ausgeben

Da ich viele unterschiedliche Tabellen benötige mache ich das so umständlich. Aber ist das der Grund warum das Floaten nicht funktioniert?

Geschrieben von Malchor am 17.05.2024 17:15:03
Forum: PHP Developer Forum
Daten einer Abfrage mit Hilfe von Thumbnails nebeneinander ausgeben

Du möchtest dir bestimmt mal ansehen, wie eine HTML-Tabelle richtig aufgebaut wird: https://www.w3schools.com/tags/tag_th.asp align solltest du ...

Geschrieben von scatello am 17.05.2024 17:12:34
Forum: PHP Developer Forum