CS318 - Pintos
Pintos source browser for JHU CS318 course
Functions
arc4.c File Reference
#include <stdint.h>
#include "tests/arc4.h"
Include dependency graph for arc4.c:

Go to the source code of this file.

Functions

static void swap_byte (uint8_t *a, uint8_t *b)
 Swap bytes. More...
 
void arc4_init (struct arc4 *arc4, const void *key_, size_t size)
 
void arc4_crypt (struct arc4 *arc4, void *buf_, size_t size)
 tests/arc4.h More...
 

Function Documentation

◆ arc4_crypt()

void arc4_crypt ( struct arc4 arc4,
void *  buf_,
size_t  size 
)

tests/arc4.h

Definition at line 35 of file arc4.c.

References buf, arc4::i, arc4::j, arc4::s, s, ustar_header::size, and swap_byte().

Referenced by init(), main(), and test_main().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ arc4_init()

void arc4_init ( struct arc4 arc4,
const void *  key_,
size_t  size 
)

Definition at line 14 of file arc4.c.

References arc4::i, arc4::j, arc4::s, s, ustar_header::size, and swap_byte().

Referenced by init(), main(), and test_main().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ swap_byte()

static void swap_byte ( uint8_t a,
uint8_t b 
)
inlinestatic

Swap bytes.

Definition at line 6 of file arc4.c.

Referenced by arc4_crypt(), and arc4_init().

Here is the caller graph for this function: