wut  1.0.0-alpha
Wii U Toolchain
Typedefs | Enumerations | Functions
nssl.h File Reference
#include <wut.h>

Go to the source code of this file.

Typedefs

typedef int32_t NSSLContextHandle
 A handle to a NSSL context created with NSSLCreateContext(). More...
 
typedef int32_t NSSLConnectionHandle
 A handle to a NSSL connection created with NSSLCreateConnection(). More...
 
typedef enum NSSLServerCertId NSSLServerCertId
 The IDs of a system CA. More...
 

Enumerations

enum  NSSLServerCertId {
  NSSL_SERVER_CERT_GROUP_NINTENDO_FIRST = 100,
  NSSL_SERVER_CERT_NINTENDO_CA = 100,
  NSSL_SERVER_CERT_NINTENDO_CA_G2 = 101,
  NSSL_SERVER_CERT_NINTENDO_CA_G3 = 102,
  NSSL_SERVER_CERT_NINTENDO_CLASS2_CA = 103,
  NSSL_SERVER_CERT_NINTENDO_CLASS2_CA_G2 = 104,
  NSSL_SERVER_CERT_NINTENDO_CLASS2_CA_G3 = 105,
  NSSL_SERVER_CERT_GROUP_NINTENDO_LAST = 105,
  NSSL_SERVER_CERT_GROUP_COMMERCIAL_FIRST = 1001,
  NSSL_SERVER_CERT_BALTIMORE_CYBERTRUST_ROOT_CA = 1001,
  NSSL_SERVER_CERT_CYBERTRUST_GLOBAL_ROOT_CA = 1002,
  NSSL_SERVER_CERT_VERIZON_GLOBAL_ROOT_CA = 1003,
  NSSL_SERVER_CERT_GLOBALSIGN_ROOT_CA = 1004,
  NSSL_SERVER_CERT_GLOBALSIGN_ROOT_CA_R2 = 1005,
  NSSL_SERVER_CERT_GLOBALSIGN_ROOT_CA_R3 = 1006,
  NSSL_SERVER_CERT_VERISIGN_CLASS3_PUBLIC_PRIMARY_CA_G3 = 1007,
  NSSL_SERVER_CERT_VERISIGN_UNIVERSAL_ROOT_CA = 1008,
  NSSL_SERVER_CERT_VERISIGN_CLASS3_PUBLIC_PRIMARY_CA_G5 = 1009,
  NSSL_SERVER_CERT_THAWTE_PRIMARY_ROOT_CA_G3 = 1010,
  NSSL_SERVER_CERT_THAWTE_PRIMARY_ROOT_CA = 1011,
  NSSL_SERVER_CERT_GEOTRUST_GLOBAL_CA = 1012,
  NSSL_SERVER_CERT_GEOTRUST_GLOBAL_CA2 = 1013,
  NSSL_SERVER_CERT_GEOTRUST_PRIMARY_CA = 1014,
  NSSL_SERVER_CERT_GEOTRUST_PRIMARY_CA_G3 = 1015,
  NSSL_SERVER_CERT_ADDTRUST_EXT_CA_ROOT = 1016,
  NSSL_SERVER_CERT_COMODO_CA = 1017,
  NSSL_SERVER_CERT_UTN_DATACORP_SGC_CA = 1018,
  NSSL_SERVER_CERT_UTN_USERFIRST_HARDWARE_CA = 1019,
  NSSL_SERVER_CERT_DIGICERT_HIGH_ASSURANCE_EV_ROOT_CA = 1020,
  NSSL_SERVER_CERT_DIGICERT_ASSURED_ID_ROOT_CA = 1021,
  NSSL_SERVER_CERT_DIGICERT_GLOBAL_ROOT_CA = 1022,
  NSSL_SERVER_CERT_GTE_CYBERTRUST_GLOBAL_ROOT = 1023,
  NSSL_SERVER_CERT_VERISIGN_CLASS3_PUBLIC_PRIMARY_CA = 1024,
  NSSL_SERVER_CERT_THAWTE_PREMIUM_SERVER_CA = 1025,
  NSSL_SERVER_CERT_EQUIFAX_SECURE_CA = 1026,
  NSSL_SERVER_CERT_ENTRUST_SECURE_SERVER_CA = 1027,
  NSSL_SERVER_CERT_VERISIGN_CLASS3_PUBLIC_PRIMARY_CA_G2 = 1028,
  NSSL_SERVER_CERT_ENTRUST_CA_2048 = 1029,
  NSSL_SERVER_CERT_ENTRUST_ROOT_CA = 1030,
  NSSL_SERVER_CERT_ENTRUST_ROOT_CA_G2 = 1031,
  NSSL_SERVER_CERT_DIGICERT_ASSURED_ID_ROOT_CA_G2 = 1032,
  NSSL_SERVER_CERT_DIGICERT_GLOBAL_ROOT_CA_G2 = 1033,
  NSSL_SERVER_CERT_GROUP_COMMERCIAL_LAST = 1033,
  NSSL_SERVER_CERT_GROUP_COMMERCIAL_4096_FIRST = 1900,
  NSSL_SERVER_CERT_COMODO_RSA_CA = 1900,
  NSSL_SERVER_CERT_USERTRUST_RSA_CA = 1901,
  NSSL_SERVER_CERT_GROUP_COMMERCIAL_4096_LAST = 1901
}
 The IDs of a system CA. More...
 

Functions

int32_t NSSLInit ()
 Initialises the NSSL library for use. More...
 
int32_t NSSLFinish ()
 Cleans up and finishes use of the NSSL library. More...
 
NSSLContextHandle NSSLCreateContext (int32_t unk)
 Creates a context to use with the NSSL library. More...
 
int32_t NSSLDestroyContext (NSSLContextHandle context)
 Destroys a NSSL context. More...
 
int32_t NSSLAddServerPKIExternal (NSSLContextHandle context, const void *cert, int32_t length, int32_t unk)
 Add a custom root CA to the given NSSL context. More...
 
int32_t NSSLAddServerPKI (NSSLContextHandle context, NSSLServerCertId pki)
 Add a system root CA (one of NSSLServerCertId) to the given NSSL context. More...
 
NSSLConnectionHandle NSSLCreateConnection (NSSLContextHandle context, const char *host, int32_t hostLength, int32_t options, int32_t socket, int32_t block)
 Open an SSL connection. More...
 
int32_t NSSLDestroyConnection (NSSLConnectionHandle connection)
 Close and destroy a NSSL connection. More...
 
int32_t NSSLRead (NSSLConnectionHandle connection, const void *buffer, int32_t length, int32_t *outBytesRead)
 Read data from an open NSSL connection into a given buffer. More...
 
int32_t NSSLWrite (NSSLConnectionHandle connection, const void *buffer, int32_t length, int32_t *outBytesWritten)
 Write data to an open NSSL connection from a given buffer. More...