gcgi  0.9.5
About: GCGI implements NCSA's Common Gateway Interface along with the extensions to that interface defined in RFC2388.
  Fossies Dox: gcgi-0.9.5.tar.gz  ("inofficial" and yet experimental doxygen-generated source code documentation)  

code.c File Reference
#include "gcgi_private.h"
Include dependency graph for code.c:

Go to the source code of this file.

Functions

static char hextochar (char *hex)
 
static void chartohex (char c, char *hex, int size)
 
static void plustospace (char *string)
 
gcgiReturnType gcgiDecodeBaseSixtyFourString (char *text, char **decodedText, int *numBytes)
 
gcgiReturnType gcgiEncodeBaseSixtyFourString (char *text, int numBytes, char **encodedText)
 
gcgiReturnType gcgiDecodeQuotedPrintableString (char *text, char **decodedText, int *size)
 
gcgiReturnType gcgiEncodeQuotedPrintableString (char *text, char **encodedText, int *size)
 
gcgiReturnType gcgiDecodeRfc2047String (char *text, char **charset, char **decodedText)
 
gcgiReturnType gcgiDecodeUrlEncodedString (char *text, char **decodedText, int *size)
 
gcgiReturnType gcgiEncodeUrlString (char *text, char **encodedText, int *size)
 

Variables

static const char mimeBase64 []
 

Function Documentation

◆ chartohex()

void chartohex ( char  c,
char *  hex,
int  size 
)
static

Definition at line 382 of file code.c.

Referenced by gcgiEncodeQuotedPrintableString(), and gcgiEncodeUrlString().

◆ gcgiDecodeBaseSixtyFourString()

gcgiReturnType gcgiDecodeBaseSixtyFourString ( char *  text,
char **  decodedText,
int *  numBytes 
)

Definition at line 41 of file code.c.

References GCGISUCCESS, text, and XMALLOC.

Referenced by gcgiDecodeRfc2047String(), and gcgiParseCookie().

◆ gcgiDecodeQuotedPrintableString()

gcgiReturnType gcgiDecodeQuotedPrintableString ( char *  text,
char **  decodedText,
int *  size 
)

Definition at line 133 of file code.c.

References GCGISUCCESS, text, and XMALLOC.

Referenced by gcgiDecodeRfc2047String().

◆ gcgiDecodeRfc2047String()

gcgiReturnType gcgiDecodeRfc2047String ( char *  text,
char **  charset,
char **  decodedText 
)

◆ gcgiDecodeUrlEncodedString()

gcgiReturnType gcgiDecodeUrlEncodedString ( char *  text,
char **  decodedText,
int *  size 
)

Definition at line 290 of file code.c.

References GCGISUCCESS, hextochar(), plustospace(), text, and XMALLOC.

Referenced by decodeUrl().

◆ gcgiEncodeBaseSixtyFourString()

gcgiReturnType gcgiEncodeBaseSixtyFourString ( char *  text,
int  numBytes,
char **  encodedText 
)

Definition at line 96 of file code.c.

References GCGISUCCESS, mimeBase64, text, and XMALLOC.

Referenced by gcgiSendCookie().

◆ gcgiEncodeQuotedPrintableString()

gcgiReturnType gcgiEncodeQuotedPrintableString ( char *  text,
char **  encodedText,
int *  size 
)

Definition at line 175 of file code.c.

References chartohex(), GCGISUCCESS, text, and XMALLOC.

◆ gcgiEncodeUrlString()

gcgiReturnType gcgiEncodeUrlString ( char *  text,
char **  encodedText,
int *  size 
)

Definition at line 318 of file code.c.

References chartohex(), GCGISUCCESS, text, and XMALLOC.

◆ hextochar()

char hextochar ( char *  hex)
static

Definition at line 361 of file code.c.

Referenced by gcgiDecodeUrlEncodedString().

◆ plustospace()

void plustospace ( char *  string)
static

Definition at line 417 of file code.c.

Referenced by gcgiDecodeUrlEncodedString().

Variable Documentation

◆ mimeBase64

const char mimeBase64[]
static
Initial value:
= {
'A', 'B', 'C', 'D', 'E', 'F', 'G', 'H',
'I', 'J', 'K', 'L', 'M', 'N', 'O', 'P',
'Q', 'R', 'S', 'T', 'U', 'V', 'W', 'X',
'Y', 'Z', 'a', 'b', 'c', 'd', 'e', 'f',
'g', 'h', 'i', 'j', 'k', 'l', 'm', 'n',
'o', 'p', 'q', 'r', 's', 't', 'u', 'v',
'w', 'x', 'y', 'z', '0', '1', '2', '3',
'4', '5', '6', '7', '8', '9', '+', '/'
}

Definition at line 28 of file code.c.

Referenced by gcgiEncodeBaseSixtyFourString().