MHEG5  15.3.0
source/core/src/mh5access.c File Reference

Functions relating to HTTPS Server Access. More...

#include <assert.h>
#include <stdlib.h>
#include <string.h>
#include <stdio.h>
#include "mh5profile.h"
#include "mh5gate.h"
#include "mh5memory.h"
#include "mh5base.h"
#include "mh5access.h"
#include "mh5fileorm.h"
#include "mh5misc.h"
#include "glue_dsmcc.h"
#include "stb_os.h"

Defines

#define SERVER_AUTH_FILE   "DSM://auth.servers"
#define ACCESS_FILE_TIMEOUT_MS   (1000 * 60 * 60 * 4)
#define MAX_CALLBACKS   5

Enumerations

enum  AccessFileState_t {
  ACCESS_FILE_NOTLOADED, ACCESS_FILE_LOADED, ACCESS_FILE_MISSING, ACCESS_FILE_LOADING_SYNC,
  ACCESS_FILE_LOADING_ASYNC
}

Functions

MHEG5ServerAccess_t MHEG5CheckServerPermitted (U8BIT *url)
void MHEG5ResetServerAccess (void)
 Reset the cachedserver access permission file.
void MHEG5AddServerAccessCallback (void(*LoadNotifyCallback)(void))
 Add callback function to be called when the server access permission file is loaded.

Detailed Description

Functions relating to HTTPS Server Access.

Date:
22/02/2010
Author:
Omri Barel

Function Documentation

void MHEG5AddServerAccessCallback ( void(*)(void)  LoadNotifyCallback)

Add callback function to be called when the server access permission file is loaded.

Parameters:
LoadCallbackPointer to the callback function
Returns:
void
MHEG5ServerAccess_t MHEG5CheckServerPermitted ( U8BIT *  url)
Parameters:
urlURL to be checked
Returns:
SERVER_ACCESS_BLOCKED if url is not allowed by auth.servers SERVER_ACCESS_PERMITTED_NO_AUTH if it is allowed and no authentication is needed SERVER_ACCESS_PERMITTED_AUTH if it is allowed and authentication is needed or SERVER_ACCESS_PENDING if the auth.servers file is being loaded
void MHEG5ResetServerAccess ( void  )

Reset the cachedserver access permission file.

Returns:
void
 All Data Structures Files Functions Variables Typedefs Defines