亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關于我們
? 蟲蟲下載站

?? ftpp_ui_config.c

?? 著名的入侵檢測系統snort的最新版本的源碼
?? C
字號:
/* * ftpp_ui_config.c * * Copyright (C) 2004 Sourcefire,Inc * Steven A. Sturges <ssturges@sourcefire.com> * Daniel J. Roelker <droelker@sourcefire.com> * Marc A. Norton <mnorton@sourcefire.com> * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License Version 2 as * published by the Free Software Foundation.  You may not use, modify or * distribute this program under any other version of the GNU General * Public License. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. * * Description: * * This file contains library calls to configure FTPTelnet. * * This file deals with configuring FTPTelnet processing.  It contains * routines to set a default configuration, add client configurations, etc. * * NOTES: * - 16.09.04:  Initial Development.  SAS * */#include <stdlib.h>#include <stdio.h>#include <string.h>#include <sys/types.h>#ifndef WIN32#include <sys/socket.h>#include <netinet/in.h>#include <arpa/inet.h>#endif#include "ftpp_return_codes.h"#include "ftpp_ui_client_lookup.h"#include "ftpp_ui_server_lookup.h"#include "ftp_cmd_lookup.h"#include "ftp_bounce_lookup.h"#include "ftpp_ui_config.h"/* * Function: ftpp_ui_config_init_global_conf(FTPTELNET_GLOBAL_CONF *GlobalConf) * * Purpose: Initialize the FTPTelnet global configuration. *          The main point of this function is to initialize the client *          lookup type.  We also do things like memset, etc. * * Arguments: GlobalConf    => pointer to the global configuration * * Returns: int => return code indicating error or success * */int ftpp_ui_config_init_global_conf(FTPTELNET_GLOBAL_CONF *GlobalConf){    int iRet;    memset(GlobalConf, 0x00, sizeof(FTPTELNET_GLOBAL_CONF));    iRet = ftpp_ui_client_lookup_init(&GlobalConf->client_lookup);    if (iRet)    {        return iRet;    }    iRet = ftpp_ui_server_lookup_init(&GlobalConf->server_lookup);    if (iRet)    {        return iRet;    }    return FTPP_SUCCESS;}/* * Function: ftpp_ui_config_default(FTPTELNET_GLOBAL_CONF *GlobalConf) * * Purpose: This function sets the global and the global_client default *          configuration.  In order to change the default configuration *          of FTPTelnet, you must change this function. * * Arguments: GlobalConf    => pointer to the global configuration structure *  * Returns: int => return code indicating error or success * */int ftpp_ui_config_default(FTPTELNET_GLOBAL_CONF *GlobalConf){    if(GlobalConf == NULL)    {        return FTPP_INVALID_ARG;    }    /*     * Set Global Client Configurations     */    ftpp_ui_config_reset_ftp_client(&GlobalConf->global_ftp_client, 0);    ftpp_ui_config_reset_ftp_server(&GlobalConf->global_ftp_server, 0);    ftpp_ui_config_reset_telnet_proto(&GlobalConf->global_telnet);    return FTPP_SUCCESS;}/* * Function: ftpp_ui_config_reset_global(FTPTELNET_GLOBAL_CONF *GlobalConf) * * Purpose: This function resets the global parameters. *          THIS IS NOT THE GLOBAL FTP CLIENT CONFIGURATION. * * Arguments: GlobalConf    => pointer to the global configuration structure * * Returns: int => return code indicating error or success * */int ftpp_ui_config_reset_global(FTPTELNET_GLOBAL_CONF *GlobalConf){    int iRet;    /* Clean these up before mem setting */    ftp_bounce_lookup_cleanup(&(GlobalConf->global_ftp_client.bounce_lookup));    ftp_cmd_lookup_cleanup(&(GlobalConf->global_ftp_server.cmd_lookup));    ftpp_ui_client_lookup_cleanup(&GlobalConf->client_lookup);    ftpp_ui_server_lookup_cleanup(&GlobalConf->server_lookup);    memset(GlobalConf, 0x00, sizeof(FTPTELNET_GLOBAL_CONF));    iRet = ftpp_ui_client_lookup_init(&GlobalConf->client_lookup);    if (iRet)    {        return iRet;    }    iRet = ftpp_ui_server_lookup_init(&GlobalConf->server_lookup);    if (iRet)    {        return iRet;    }    return FTPP_SUCCESS;}    /* * Function: ftpp_ui_config_reset_telnet_proto(TELNET_PROTO_CONF *TelnetConf) * * Purpose: This function resets a telnet construct. * * Arguments: TelnetConf    => pointer to the TELNET_PROTO_CONF structure * * Returns: int => return code indicating error or success * */int ftpp_ui_config_reset_telnet_proto(TELNET_PROTO_CONF *TelnetConf){    memset(TelnetConf, 0x00, sizeof(TELNET_PROTO_CONF));    TelnetConf->ayt_threshold = FTPP_UI_CONFIG_TELNET_DEF_AYT_THRESHOLD;    TelnetConf->proto_ports.port_count = 1;    TelnetConf->proto_ports.ports[23] = 1;    return FTPP_SUCCESS;}/* * Function: ftpp_ui_config_reset_ftp_cmd_date_format(FTP_DATE_FMT *DateFmt) * * Purpose: This function resets an FTP date parameter construct. * * Arguments: ThisFmt   => pointer to the FTP_DATE_FMT structure * * Returns: void * */void ftpp_ui_config_reset_ftp_cmd_date_format(FTP_DATE_FMT *DateFmt){    if (DateFmt->optional)    {        ftpp_ui_config_reset_ftp_cmd_date_format(DateFmt->optional);    }    if (DateFmt->next)    {        ftpp_ui_config_reset_ftp_cmd_date_format(DateFmt->next);    }    if (DateFmt->format_string)    {        free(DateFmt->format_string);    }    free(DateFmt);}/* * Function: ftpp_ui_config_reset_ftp_cmd_format(FTP_PARAM_FMT *ThisFmt) * * Purpose: This function resets an FTP parameter construct. * * Arguments: ThisFmt   => pointer to the FTP_PARAM_FMT structure * * Returns: void * */void ftpp_ui_config_reset_ftp_cmd_format(FTP_PARAM_FMT *ThisFmt){    if (ThisFmt->optional_fmt)    {        ftpp_ui_config_reset_ftp_cmd_format(ThisFmt->optional_fmt);    }    if (ThisFmt->numChoices)    {        int i;        for (i=0;i<ThisFmt->numChoices;i++)        {            ftpp_ui_config_reset_ftp_cmd_format(ThisFmt->choices[i]);        }        free(ThisFmt->choices);    }    if (ThisFmt->next_param_fmt)    {        /* Don't free this one twice if its after an optional */        FTP_PARAM_FMT *next = ThisFmt->next_param_fmt;        ThisFmt->next_param_fmt->prev_param_fmt->next_param_fmt = NULL;        ThisFmt->next_param_fmt = NULL;        ftpp_ui_config_reset_ftp_cmd_format(next);    }    if (ThisFmt->type == e_date)    {        ftpp_ui_config_reset_ftp_cmd_date_format(ThisFmt->format.date_fmt);    }    memset(ThisFmt, 0, sizeof(FTP_PARAM_FMT));    free(ThisFmt);}/* * Function: ftpp_ui_config_reset_ftp_cmd(FTP_CMD_CONF *FTPCmd) * * Purpose: This function resets a FTP command construct. * * Arguments: FTPCmd    => pointer to the FTP_CMD_CONF structure * * Returns: int => return code indicating error or success * */int ftpp_ui_config_reset_ftp_cmd(FTP_CMD_CONF *FTPCmd){    FTP_PARAM_FMT *NextCmdFormat = FTPCmd->param_format;    if (NextCmdFormat)    {        ftpp_ui_config_reset_ftp_cmd_format(NextCmdFormat);    }    return FTPP_SUCCESS;}/* * Function: ftpp_ui_config_reset_ftp_server(FTP_SERVER_PROTO_CONF *ServerConf, *                                  char first) * * Purpose: This function resets a ftp server construct. * * Arguments: ServerConf    => pointer to the FTP_SERVER_PROTO_CONF structure *            first         => indicator whether this is a new conf * * Returns: int => return code indicating error or success * */int ftpp_ui_config_reset_ftp_server(FTP_SERVER_PROTO_CONF *ServerConf,                                    char first){    int iRet = FTPP_SUCCESS;    //FTP_CMD_CONF *NextFTPCmd = NULL;    if (first == 0)    {        ftp_cmd_lookup_cleanup(&ServerConf->cmd_lookup);    }    if (ServerConf->serverAddr)    {        free(ServerConf->serverAddr);    }    memset(ServerConf, 0x00, sizeof(FTP_SERVER_PROTO_CONF));    ServerConf->proto_ports.port_count = 1;    ServerConf->proto_ports.ports[21] = 1;    ftp_cmd_lookup_init(&ServerConf->cmd_lookup);    ServerConf->def_max_param_len = FTPP_UI_CONFIG_FTP_DEF_CMD_PARAM_MAX;    return iRet;}/* * Function: ftpp_ui_config_add_ftp_server( *                          FTPTELNET_GLOBAL_CONF *GlobalConf, *                          unsigned long ServerIP, *                          FTP_SERVER_PROTO_CONF *ServerConf) * * Purpose: Add a server config to the FTPTelnet configuration. *          This function takes an IP address of a server and an FTP *          Server configuration, and assigns the configuration to *          the IP address in a lookup table. * * Arguments: GlobalConf    => pointer to the global configuration *            ServerIp      => the IP address of the server *            ServerConf    => pointer to the server configuration * * Returns: int => return code indicating error or success * */int ftpp_ui_config_add_ftp_server(FTPTELNET_GLOBAL_CONF *GlobalConf,                            ip_p ServerIP, FTP_SERVER_PROTO_CONF *ServerConf){    int iRet;    iRet = ftpp_ui_server_lookup_add(GlobalConf->server_lookup, ServerIP, ServerConf);    if (iRet)    {        /*         * Already added key will return a generic non-fatal         * error.         */        return iRet;    }    return FTPP_SUCCESS;}/* * Function: ftpp_ui_config_reset_ftp_client(FTP_CLIENT_PROTO_CONF *ClientConf, *                                  char first) * * Purpose: This function resets a ftp client construct. * * Arguments: ClientConf    => pointer to the FTP_CLIENT_PROTO_CONF structure *            first         => indicator whether this is a new conf * * * Returns: int => return code indicating error or success * */int ftpp_ui_config_reset_ftp_client(FTP_CLIENT_PROTO_CONF *ClientConf,                                    char first){    int iRet = FTPP_SUCCESS;    //FTP_BOUNCE_TO *NextBounceTo = NULL;    if (first == 0)    {        ftp_bounce_lookup_cleanup(&ClientConf->bounce_lookup);    }    if (ClientConf->clientAddr)    {        free(ClientConf->clientAddr);    }    memset(ClientConf, 0x00, sizeof(FTP_CLIENT_PROTO_CONF));    ftp_bounce_lookup_init(&ClientConf->bounce_lookup);    ClientConf->max_resp_len = (unsigned int)FTPP_UI_CONFIG_FTP_DEF_RESP_MSG_MAX;    return iRet;}/* * Function: ftpp_ui_config_add_ftp_client( *                          FTPTELNET_GLOBAL_CONF *GlobalConf, *                          unsigned long ClientIP, *                          FTP_SERVER_PROTO_CONF *ClientConf) * * Purpose: Add a client config to the FTPTelnet configuration. *          This function takes an IP address of a client and an FTP *          Client configuration, and assigns the configuration to *          the IP address in a lookup table. * * Arguments: GlobalConf    => pointer to the global configuration *            ClientIP      => the IP address of the client *            ClientConf    => pointer to the client configuration * * Returns: int => return code indicating error or success * */int ftpp_ui_config_add_ftp_client(FTPTELNET_GLOBAL_CONF *GlobalConf,                            ip_p ClientIP, FTP_CLIENT_PROTO_CONF *ClientConf){    int iRet;    iRet = ftpp_ui_client_lookup_add(GlobalConf->client_lookup, ClientIP, ClientConf);    if (iRet)    {        /*         * Already added key will return a generic non-fatal         * error.         */        return iRet;    }    return FTPP_SUCCESS;}

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
亚洲精品国产第一综合99久久| 国内不卡的二区三区中文字幕| 日本少妇一区二区| 在线观看91av| 国产尤物一区二区| 国产精品电影院| 欧美性猛交一区二区三区精品| 亚洲国产成人在线| 91网站在线播放| 国产欧美日韩三区| 欧美专区日韩专区| 极品美女销魂一区二区三区免费| 91行情网站电视在线观看高清版| 久久亚洲欧美国产精品乐播| 成人国产在线观看| 性久久久久久久久| 久久看人人爽人人| 欧美午夜宅男影院| 国产呦萝稀缺另类资源| 亚洲免费在线视频| 日韩欧美一二三四区| 懂色av中文一区二区三区| 亚洲欧美日韩精品久久久久| 欧美日本韩国一区| 成人精品小蝌蚪| 亚洲国产精品av| 欧美日韩国产小视频在线观看| 成人免费在线观看入口| 成人美女视频在线观看| 一区二区三区高清| 久久九九全国免费| 欧美剧情电影在线观看完整版免费励志电影 | 国产精品久久久久久久午夜片| 国产乱人伦精品一区二区在线观看| 欧美一级片在线| 日本v片在线高清不卡在线观看| 欧美日韩综合在线| 五月天婷婷综合| 国产精品国产三级国产aⅴ中文 | 日韩中文字幕亚洲一区二区va在线| 欧美性大战久久久久久久蜜臀| 亚洲日穴在线视频| 久久久久久久综合| 欧美一区二区三区色| 奇米影视一区二区三区| 亚洲欧美一区二区三区极速播放| 91极品视觉盛宴| 国产 欧美在线| 奇米色一区二区| 亚洲福利电影网| 亚洲人成网站在线| 欧美日韩国产另类一区| 日本欧美加勒比视频| 亚洲乱码国产乱码精品精可以看| 91久久久免费一区二区| 午夜精品久久久久久久99樱桃| 日韩一区二区三区电影 | 91精品国产91久久综合桃花| 色综合久久综合网97色综合| 国产91精品在线观看| 亚洲精品视频在线| 欧美一级午夜免费电影| 国产99久久精品| 中文字幕佐山爱一区二区免费| 欧美性感一区二区三区| 久久成人免费电影| 日本不卡视频一二三区| 午夜日韩在线电影| 亚洲成人免费av| 午夜久久久久久久久久一区二区| 精品国产一区二区亚洲人成毛片 | 午夜精品久久久久久久99水蜜桃 | 欧美日韩免费电影| 在线观看中文字幕不卡| 在线免费观看成人短视频| 色综合天天综合网国产成人综合天| 午夜亚洲国产au精品一区二区| 欧美xxx久久| 精品久久一二三区| 国产亚洲污的网站| 国产精品不卡在线| 91精品国产91久久久久久一区二区| 成人国产精品免费| 99视频超级精品| 色www精品视频在线观看| 欧洲一区在线观看| 制服丝袜国产精品| 91老司机福利 在线| 欧美在线一二三| 日韩一区二区三区精品视频| 日韩精品在线一区二区| 精品粉嫩超白一线天av| 国产欧美一区视频| 日韩免费一区二区| 欧美乱妇15p| 精品99一区二区| 国产精品高清亚洲| 亚洲国产欧美在线| 亚洲精品视频观看| 奇米色777欧美一区二区| 国产伦精品一区二区三区视频青涩| 午夜精品成人在线| 国产毛片精品视频| 色婷婷国产精品| 成人av手机在线观看| 欧美写真视频网站| 久久天堂av综合合色蜜桃网| 亚洲色图制服诱惑| 另类小说欧美激情| 99久久99久久精品免费看蜜桃| 国产xxx精品视频大全| 91成人免费网站| 欧美一区二区精品久久911| 日韩免费观看高清完整版| 成人欧美一区二区三区1314| 日日摸夜夜添夜夜添国产精品 | 国产亚洲一区字幕| 亚洲一区二区欧美激情| 久久99精品久久久久| 99国产一区二区三精品乱码| 91麻豆精品国产自产在线| 欧美日韩一区二区三区不卡| wwww国产精品欧美| 成人精品电影在线观看| 欧美美女直播网站| 国产精品免费看片| 视频一区中文字幕| 色综合久久综合中文综合网| 久久免费精品国产久精品久久久久 | 欧美日韩高清影院| 中文字幕一区二区不卡| 免费观看在线综合| 欧美性色黄大片| 中文字幕制服丝袜成人av | 欧美年轻男男videosbes| 久久精品欧美一区二区三区麻豆| 国产亚洲成年网址在线观看| 国产欧美一区二区精品性色| 日本网站在线观看一区二区三区 | 韩国一区二区视频| 欧美日韩在线观看一区二区| 91麻豆精品国产91久久久使用方法| 欧美日韩电影在线播放| 综合网在线视频| 成人av电影在线观看| 亚洲精品在线观看视频| 日本女优在线视频一区二区| 国产麻豆精品95视频| 日韩一区二区影院| 国产精品美女一区二区在线观看| 亚洲欧美色一区| 成人免费毛片高清视频| 久久这里只有精品6| 裸体健美xxxx欧美裸体表演| 欧美无砖专区一中文字| 亚洲一区在线观看免费观看电影高清| 日本不卡一区二区| 欧美精品国产精品| 日日骚欧美日韩| 欧美一区二区三区人| 视频一区在线播放| 欧美精品免费视频| 日本欧美在线观看| 日韩欧美aaaaaa| 韩国精品主播一区二区在线观看| 99久久伊人久久99| 国产精品初高中害羞小美女文| 欧美aa在线视频| 精品久久一区二区三区| 久久99精品久久久久久久久久久久| 99久久99久久综合| 中文字幕综合网| 国产一区久久久| 久久蜜桃香蕉精品一区二区三区| 亚洲一二三四久久| 欧美人与z0zoxxxx视频| 国产精品久久久久久久久图文区| 日本 国产 欧美色综合| 91精品国产综合久久精品性色 | 一本大道久久a久久综合| 国产精品二区一区二区aⅴ污介绍| 免费精品视频最新在线| 久久噜噜亚洲综合| 成人av网址在线观看| 免费观看日韩av| 成人黄色在线网站| 最好看的中文字幕久久| 日日噜噜夜夜狠狠视频欧美人| 成人精品小蝌蚪| 一区二区三区在线免费| 在线播放视频一区| 亚洲乱码中文字幕综合| 91久久久免费一区二区| 日韩精品欧美精品| 国产欧美精品一区aⅴ影院| 色综合色综合色综合色综合色综合| 国产亚洲福利社区一区| 99久久综合色| 青娱乐精品视频| 国产精品午夜久久|