Beispiel #1
0
/**
**  This function resets a server construct.
**
**  @param ServerConf pointer to the HTTPINSPECT_CONF structure
**
**  @return integer
**
**  @return HI_SUCCESS function successful
*/
int hi_ui_config_reset_server(HTTPINSPECT_CONF *ServerConf)
{
    http_cmd_lookup_cleanup(&ServerConf->cmd_lookup);
    memset(ServerConf, 0x00, sizeof(HTTPINSPECT_CONF));
    http_cmd_lookup_init(&ServerConf->cmd_lookup);

    return HI_SUCCESS;
}
Beispiel #2
0
/**
**  This function resets a server construct.
**
**  @param ServerConf pointer to the HTTPINSPECT_CONF structure
**
**  @return integer
**
**  @return HI_SUCCESS function successful
*/
int hi_ui_config_reset_server(HTTPINSPECT_CONF *ServerConf)
{
    int i;

    for( i=0; i<HTTP_MAX_XFF_FIELDS; i++ )
        if( ServerConf->xff_headers[i] != NULL )
        {
            free( ServerConf->xff_headers[i] );
            ServerConf->xff_headers[i] = NULL;
        }

    http_cmd_lookup_cleanup(&ServerConf->cmd_lookup);
    memset(ServerConf, 0x00, sizeof(HTTPINSPECT_CONF));
    http_cmd_lookup_init(&ServerConf->cmd_lookup);

    return HI_SUCCESS;
}
Beispiel #3
0
/**
**  This function resets the cmd lookup for http_methods
**
**  @param ServerConf pointer to the HTTPINSPECT_CONF structure
**
**  @return integer
**
**  @return None
*/
void hi_ui_config_reset_http_methods(HTTPINSPECT_CONF *ServerConf)
{
    http_cmd_lookup_cleanup(&ServerConf->cmd_lookup);
    http_cmd_lookup_init(&ServerConf->cmd_lookup);
}