Qt
Internal/Contributor docs for the Qt SDK. Note: These are NOT official API docs; those are found at https://doc.qt.io/
Loading...
Searching...
No Matches
fx_crypt.cpp File Reference

(813d9ae984a99e739b99cf694a9d5b24d0a6b7a7)

#include "core/fdrm/fx_crypt.h"
#include <utility>
#include "core/fxcrt/span_util.h"
+ Include dependency graph for fx_crypt.cpp:

Go to the source code of this file.

Macros

#define GET_UINT32(n, b, i)
 
#define PUT_UINT32(n, b, i)
 
#define S(x, n)
 
#define P(a, b, c, d, k, s, t)
 
#define F(x, y, z)
 
#define F(x, y, z)
 
#define F(x, y, z)
 
#define F(x, y, z)
 

Functions

void CRYPT_ArcFourSetup (CRYPT_rc4_context *context, pdfium::span< const uint8_t > key)
 
void CRYPT_ArcFourCrypt (CRYPT_rc4_context *context, pdfium::span< uint8_t > data)
 
void CRYPT_ArcFourCryptBlock (pdfium::span< uint8_t > data, pdfium::span< const uint8_t > key)
 
CRYPT_md5_context CRYPT_MD5Start ()
 
void CRYPT_MD5Update (CRYPT_md5_context *context, pdfium::span< const uint8_t > data)
 
void CRYPT_MD5Finish (CRYPT_md5_context *context, uint8_t digest[16])
 
void CRYPT_MD5Generate (pdfium::span< const uint8_t > data, uint8_t digest[16])
 

Macro Definition Documentation

◆ F [1/4]

#define F ( x,
y,
z )
Value:
(z ^ (x & (y ^ z)))
GLuint GLfloat GLfloat GLfloat GLfloat GLfloat z
GLint GLint GLint GLint GLint x
[0]
GLint y

◆ F [2/4]

#define F ( x,
y,
z )
Value:
(y ^ (z & (x ^ y)))

◆ F [3/4]

#define F ( x,
y,
z )
Value:
(x ^ y ^ z)

◆ F [4/4]

#define F ( x,
y,
z )
Value:
(y ^ (x | ~z))

◆ GET_UINT32

#define GET_UINT32 ( n,
b,
i )
Value:
{ \
(n) = (uint32_t)((uint8_t*)b)[(i)] | \
(((uint32_t)((uint8_t*)b)[(i) + 1]) << 8) | \
(((uint32_t)((uint8_t*)b)[(i) + 2]) << 16) | \
(((uint32_t)((uint8_t*)b)[(i) + 3]) << 24); \
}
GLboolean GLboolean GLboolean b
GLfloat n
[4]

Definition at line 13 of file fx_crypt.cpp.

◆ P

#define P ( a,
b,
c,
d,
k,
s,
t )
Value:
{ \
a += F(b, c, d) + X[k] + t; \
a = S(a, s) + b; \
}
#define S(x, n)
#define F(x, y, z)
GLboolean GLboolean GLboolean GLboolean a
[7]
GLdouble s
[6]
Definition qopenglext.h:235
const GLubyte * c
GLdouble GLdouble t
Definition qopenglext.h:243
double d
[1]

◆ PUT_UINT32

#define PUT_UINT32 ( n,
b,
i )
Value:
{ \
(((uint8_t*)b)[(i)]) = (uint8_t)(((n)) & 0xFF); \
(((uint8_t*)b)[(i) + 1]) = (uint8_t)(((n) >> 8) & 0xFF); \
(((uint8_t*)b)[(i) + 2]) = (uint8_t)(((n) >> 16) & 0xFF); \
(((uint8_t*)b)[(i) + 3]) = (uint8_t)(((n) >> 24) & 0xFF); \
}

Definition at line 20 of file fx_crypt.cpp.

◆ S

#define S ( x,
n )
Value:
((x << n) | ((x & 0xFFFFFFFF) >> (32 - n)))

Function Documentation

◆ CRYPT_ArcFourCrypt()

void CRYPT_ArcFourCrypt ( CRYPT_rc4_context * context,
pdfium::span< uint8_t > data )

Definition at line 158 of file fx_crypt.cpp.

◆ CRYPT_ArcFourCryptBlock()

void CRYPT_ArcFourCryptBlock ( pdfium::span< uint8_t > data,
pdfium::span< const uint8_t > key )

Definition at line 169 of file fx_crypt.cpp.

◆ CRYPT_ArcFourSetup()

void CRYPT_ArcFourSetup ( CRYPT_rc4_context * context,
pdfium::span< const uint8_t > key )

◆ CRYPT_MD5Finish()

void CRYPT_MD5Finish ( CRYPT_md5_context * context,
uint8_t digest[16] )

Definition at line 214 of file fx_crypt.cpp.

References CRYPT_md5_context::state, and CRYPT_md5_context::total.

Referenced by CRYPT_MD5Generate(), CFDETextOutTest::GetBitmapChecksum(), EmbedderTest::HashBitmap(), CPDF_SecurityHandler::OnCreate(), TEST(), TEST(), and TEST().

+ Here is the caller graph for this function:

◆ CRYPT_MD5Generate()

void CRYPT_MD5Generate ( pdfium::span< const uint8_t > data,
uint8_t digest[16] )

Definition at line 228 of file fx_crypt.cpp.

References CRYPT_MD5Finish(), and CRYPT_MD5Start().

+ Here is the call graph for this function:

◆ CRYPT_MD5Start()

CRYPT_md5_context CRYPT_MD5Start ( )

Definition at line 176 of file fx_crypt.cpp.

References CRYPT_md5_context::state, and CRYPT_md5_context::total.

Referenced by CRYPT_MD5Generate(), CFDETextOutTest::GetBitmapChecksum(), EmbedderTest::HashBitmap(), CPDF_SecurityHandler::OnCreate(), TEST(), TEST(), and TEST().

+ Here is the caller graph for this function:

◆ CRYPT_MD5Update()

void CRYPT_MD5Update ( CRYPT_md5_context * context,
pdfium::span< const uint8_t > data )

Definition at line 187 of file fx_crypt.cpp.

References CRYPT_md5_context::buffer, and CRYPT_md5_context::total.