⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 wtls.c

📁 是一个手机功能的模拟程序
💻 C
📖 第 1 页 / 共 5 页
字号:

/*****
* SYNONYM CONTINUE_SEND_DATA
* <<SYSTEM WAP/BLOCK WTLS/PROCESS WTLS_Record>>
* #SDTREF(SDL,D:\WIP\System\SystemConfigurations\base_push_wta_wtls_co_sms\sdl\wtls\wtls_record.spr(Declarations),1937(15,105),5)
******/
#define z4B1J_CONTINUE_SEND_DATA SDL_INTEGER_LIT(4)

/*****
* SYNONYM CONTINUE_SEND_DATA_WITH_BUFFER
* <<SYSTEM WAP/BLOCK WTLS/PROCESS WTLS_Record>>
* #SDTREF(SDL,D:\WIP\System\SystemConfigurations\base_push_wta_wtls_co_sms\sdl\wtls\wtls_record.spr(Declarations),1937(15,105),6)
******/
#define z4B1K_CONTINUE_SEND_DATA_WITH_BUFFER SDL_INTEGER_LIT(5)

/*****
* SYNONYM CONTINUE_SEND_ALERT
* <<SYSTEM WAP/BLOCK WTLS/PROCESS WTLS_Record>>
* #SDTREF(SDL,D:\WIP\System\SystemConfigurations\base_push_wta_wtls_co_sms\sdl\wtls\wtls_record.spr(Declarations),1937(15,105),7)
******/
#define z4B1L_CONTINUE_SEND_ALERT SDL_INTEGER_LIT(6)

/*****
* SYNONYM CONTINUE_INSTALL_PENDING
* <<SYSTEM WAP/BLOCK WTLS/PROCESS WTLS_Record>>
* #SDTREF(SDL,D:\WIP\System\SystemConfigurations\base_push_wta_wtls_co_sms\sdl\wtls\wtls_record.spr(Declarations),1937(15,105),8)
******/
#define z4B1M_CONTINUE_INSTALL_PENDING SDL_INTEGER_LIT(7)

/*****
* PROCESS WTLS_Record
* <<SYSTEM WAP/BLOCK WTLS>>
* #SDTREF(SDL,D:\WIP\System\SystemConfigurations\base_push_wta_wtls_co_sms\sdl\wtls\wtls_record.spr,4,1)
******/
YPAD_PROTOTYPE(yPAD_z4B_WTLS_Record)
typedef struct {
    PROCESS_VARS
                /* #SDTREF(SDL,D:\WIP\System\SystemConfigurations\base_push_wta_wtls_co_sms\sdl\wtls\wtls_record.spr(Declarations),1928(15,30),2) */
    SDL_PId  z4B1N_cmProc;
                /* #SDTREF(SDL,D:\WIP\System\SystemConfigurations\base_push_wta_wtls_co_sms\sdl\wtls\wtls_record.spr(Declarations),1928(15,30),3) */
    SDL_PId  z4B1O_mainProc;
                /* #SDTREF(SDL,D:\WIP\System\SystemConfigurations\base_push_wta_wtls_co_sms\sdl\wtls\wtls_record.spr(Declarations),1928(15,30),4) */
    TDUnitdataReqType  z4B1P_dataReq;
                /* #SDTREF(SDL,D:\WIP\System\SystemConfigurations\base_push_wta_wtls_co_sms\sdl\wtls\wtls_record.spr(Declarations),1928(15,30),5) */
    z_ctypes_4_VoidStar  z4B1Q_conn;
                /* #SDTREF(SDL,D:\WIP\System\SystemConfigurations\base_push_wta_wtls_co_sms\sdl\wtls\wtls_record.spr(Declarations),1928(15,30),6) */
    SDL_Natural  z4B1R_path;
                /* #SDTREF(SDL,D:\WIP\System\SystemConfigurations\base_push_wta_wtls_co_sms\sdl\wtls\wtls_record.spr(Declarations),1928(15,30),7) */
    SDL_Boolean  z4B1S_outstandingRequest;
                /* #SDTREF(SDL,D:\WIP\System\SystemConfigurations\base_push_wta_wtls_co_sms\sdl\wtls\wtls_record.spr(Declarations),1928(15,30),8) */
    SDL_Integer  z4B1T_result;
                /* #SDTREF(SDL,D:\WIP\System\SystemConfigurations\base_push_wta_wtls_co_sms\sdl\wtls\wtls_record.spr(Declarations),1928(15,30),9) */
    SDL_PId  z4B1U_p;
                /* #SDTREF(SDL,D:\WIP\System\SystemConfigurations\base_push_wta_wtls_co_sms\sdl\wtls\wtls_record.spr(Declarations),1928(15,30),10) */
    z_ctypes_4_VoidStar  z4B1V_buf;
                /* #SDTREF(SDL,D:\WIP\System\SystemConfigurations\base_push_wta_wtls_co_sms\sdl\wtls\wtls_record.spr(Declarations),1928(15,30),11) */
    SDL_Natural  z4B1W_buflen;
                /* #SDTREF(SDL,D:\WIP\System\SystemConfigurations\base_push_wta_wtls_co_sms\sdl\wtls\wtls_record.spr(Declarations),1928(15,30),12) */
    SDL_Natural  z4B1X_constate;
                /* #SDTREF(SDL,D:\WIP\System\SystemConfigurations\base_push_wta_wtls_co_sms\sdl\wtls\wtls_record.spr(Declarations),1928(15,30),13) */
    SDL_Natural  z4B1Y_continueAt;
                /* #SDTREF(SDL,D:\WIP\System\SystemConfigurations\base_push_wta_wtls_co_sms\sdl\wtls\wtls_record.spr(Declarations),1928(15,30),14) */
    SDL_Natural  z4B1Z_msgType;
                /* #SDTREF(SDL,D:\WIP\System\SystemConfigurations\base_push_wta_wtls_co_sms\sdl\wtls\wtls_record.spr(Declarations),1928(15,30),15) */
    z_ctypes_4_VoidStar  z4B20_rec;
                /* #SDTREF(SDL,D:\WIP\System\SystemConfigurations\base_push_wta_wtls_co_sms\sdl\wtls\wtls_record.spr(Declarations),1928(15,30),16) */
    SDL_Natural  z4B21_alertLevel;
                /* #SDTREF(SDL,D:\WIP\System\SystemConfigurations\base_push_wta_wtls_co_sms\sdl\wtls\wtls_record.spr(Declarations),1928(15,30),17) */
    SDL_Natural  z4B22_alertDesc;
                /* #SDTREF(SDL,D:\WIP\System\SystemConfigurations\base_push_wta_wtls_co_sms\sdl\wtls\wtls_record.spr(Declarations),1928(15,30),18) */
    SDL_Boolean  z4B23_sameSDU;
} yVDef_z4B_WTLS_Record;
#define z4B1B_WaitForstart  1
#define z4B1C_IDLE  2
#define z4B1D_WaitPRF1  3
#define z4B1E_WaitPRF2  4
#define z4B1F_WaitPRF3  5

/*************************************************************************
**                #CODE directives, #HEADING sections                   **
*************************************************************************/
                /* #SDTREF(SDL,D:\WIP\System\SystemConfigurations\base_push_wta_wtls_co_sms\sdl\wtls\wtls_cm.spr(Declarations),2468(105,25),302) */
#include "wtlsdef.h"

                /* #SDTREF(SDL,D:\WIP\System\SystemConfigurations\base_push_wta_wtls_co_sms\sdl\wtls\wtls_me.spr(Declarations),2549(55,40),8) */
#include "wtlsdef.h"

                /* #SDTREF(SDL,D:\WIP\System\SystemConfigurations\base_push_wta_wtls_co_sms\sdl\wtls\wtls_main.spr(Declarations),2390(100,50),99) */
#include "wtlsdef.h"
#include "capiclnt.h"

                /* #SDTREF(SDL,D:\WIP\System\SystemConfigurations\base_push_wta_wtls_co_sms\sdl\wtls\wtls_record.spr(Declarations),1934(105,45),159) */
#include "wtlsdef.h"


/*************************************************************************
**                  #CODE directives, #BODY sections                    **
*************************************************************************/

/*************************************************************************
**                  SECTION Variables and Functions                     **
*************************************************************************/

/*****
* PROCESS WTLS_CM
* <<SYSTEM WAP/BLOCK WTLS>>
* #SDTREF(SDL,D:\WIP\System\SystemConfigurations\base_push_wta_wtls_co_sms\sdl\wtls\wtls_cm.spr,4,1)
******/

/*++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
** Tables for process WTLS_CM
** #SDTREF(SDL,D:\WIP\System\SystemConfigurations\base_push_wta_wtls_co_sms\sdl\wtls\wtls_cm.spr,4,1)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++*/

/*--------------Instance Data---------------*/
#define X_MAX_INST_z48_WTLS_CM 15
static yVDef_z48_WTLS_CM *yINSTD_z48_WTLS_CM[X_MAX_INST_z48_WTLS_CM];

/*--------------Process State---------------*/
static xSTATE yPSTATETBL_z48_WTLS_CM[X_MAX_INST_z48_WTLS_CM] = {
  XDORMANT,
  XDORMANT,
  XDORMANT,
  XDORMANT,
  XDORMANT,
  XDORMANT,
  XDORMANT,
  XDORMANT,
  XDORMANT,
  XDORMANT,
  XDORMANT,
  XDORMANT,
  XDORMANT,
  XDORMANT,
  XDORMANT
};

/*---------------State Index----------------*/
static XCONST xSITBL xSTATE_INDEX_z48_WTLS_CM[28] = {0, 3, 6, 9, 12, 15, 19,
    25, 31, 35, 39, 43, 47, 51, 55, 58, 61, 65, 69, 73, 77, 81, 85, 89, 93, 98,
    103, 106};

/*---------------Transition-----------------*/
#define XMAX_TRANS_z48_WTLS_CM 106
static XCONST xTR_TABLE_ENTRY yTRTBL_z48_WTLS_CM[XMAX_TRANS_z48_WTLS_CM] = {

    /* WaitStartCM */
  XMK_B z_WTLS_0B_StartCM, 1 XMK_E,
  XMK_B z_WTLS_0G_TerminateReq, 44 XMK_E,
  XMK_B z_WTLS_0U_ErrorIndication, 45 XMK_E

    /* NULL */,
  XMK_B z_WTLS_0D_StartHandshake, 2 XMK_E,
  XMK_B z_WTLS_0G_TerminateReq, 44 XMK_E,
  XMK_B z_WTLS_0U_ErrorIndication, 45 XMK_E

    /* WaitSessionFetch1 */,
  XMK_B z_WTLS_0G_TerminateReq, 44 XMK_E,
  XMK_B SessionFetchResponse, 3 XMK_E,
  XMK_B z_WTLS_0U_ErrorIndication, 45 XMK_E

    /* WaitPeerLookup */,
  XMK_B z_WTLS_0G_TerminateReq, 44 XMK_E,
  XMK_B PeerLookupResponse, 4 XMK_E,
  XMK_B z_WTLS_0U_ErrorIndication, 45 XMK_E

    /* WaitSessionFetch2 */,
  XMK_B z_WTLS_0G_TerminateReq, 44 XMK_E,
  XMK_B SessionFetchResponse, 5 XMK_E,
  XMK_B z_WTLS_0U_ErrorIndication, 45 XMK_E

    /* WaitGetMethods */,
  XMK_B z_WTLS_0G_TerminateReq, 44 XMK_E,
  XMK_B GetMethodsResponse, 6 XMK_E,
  XMK_B z_WTLS_0U_ErrorIndication, 45 XMK_E,
  XMK_B XASTERISK, XSAVEID XMK_E

    /* WaitServerHello */,
  XMK_B z_WTLS_0G_TerminateReq, 44 XMK_E,
  XMK_B z_WTLS_0K_AlertIndication, 12 XMK_E,
  XMK_B z_WTLS_0S_MessageIndication, 11 XMK_E,
  XMK_B z_WTLS_0U_ErrorIndication, 45 XMK_E,
  XMK_B z_WTLS_0V_TimeRequired, 9 XMK_E,
  XMK_B z482Z_ConnectionTimer, 7 XMK_E

    /* WaitCCSFull */,
  XMK_B z_WTLS_0G_TerminateReq, 44 XMK_E,
  XMK_B z_WTLS_0K_AlertIndication, 27 XMK_E,
  XMK_B z_WTLS_0S_MessageIndication, 26 XMK_E,
  XMK_B z_WTLS_0U_ErrorIndication, 45 XMK_E,
  XMK_B z_WTLS_0V_TimeRequired, 10 XMK_E,
  XMK_B z482Z_ConnectionTimer, 8 XMK_E

    /* WaitNextHandshakeMessage1 */,
  XMK_B z_WTLS_0G_TerminateReq, 44 XMK_E,
  XMK_B z_WTLS_0K_AlertIndication, 14 XMK_E,
  XMK_B z_WTLS_0S_MessageIndication, 13 XMK_E,
  XMK_B z_WTLS_0U_ErrorIndication, 45 XMK_E

    /* WaitNextHandshakeMessage2 */,
  XMK_B z_WTLS_0G_TerminateReq, 44 XMK_E,
  XMK_B z_WTLS_0K_AlertIndication, 16 XMK_E,
  XMK_B z_WTLS_0S_MessageIndication, 15 XMK_E,
  XMK_B z_WTLS_0U_ErrorIndication, 45 XMK_E

    /* WaitNextHandshakeMessage3 */,
  XMK_B z_WTLS_0G_TerminateReq, 44 XMK_E,
  XMK_B z_WTLS_0K_AlertIndication, 18 XMK_E,
  XMK_B z_WTLS_0S_MessageIndication, 17 XMK_E,
  XMK_B z_WTLS_0U_ErrorIndication, 45 XMK_E

    /* WaitNextHandshakeMessage4 */,
  XMK_B z_WTLS_0G_TerminateReq, 44 XMK_E,
  XMK_B z_WTLS_0K_AlertIndication, 20 XMK_E,
  XMK_B z_WTLS_0S_MessageIndication, 19 XMK_E,
  XMK_B z_WTLS_0U_ErrorIndication, 45 XMK_E

    /* WaitVerifyCertResponse */,
  XMK_B z_WTLS_0G_TerminateReq, 44 XMK_E,
  XMK_B VerifyCertificateChainResponse, 21 XMK_E,
  XMK_B z_WTLS_0U_ErrorIndication, 45 XMK_E,
  XMK_B XASTERISK, XSAVEID XMK_E

    /* WaitKeyExchange */,
  XMK_B z_WTLS_0G_TerminateReq, 44 XMK_E,
  XMK_B KeyExchangeResponse, 22 XMK_E,
  XMK_B z_WTLS_0U_ErrorIndication, 45 XMK_E,
  XMK_B XASTERISK, XSAVEID XMK_E

    /* WaitClientCertificate */,
  XMK_B z_WTLS_0G_TerminateReq, 44 XMK_E,
  XMK_B GetClientCertificateResponse, 23 XMK_E,
  XMK_B z_WTLS_0U_ErrorIndication, 45 XMK_E

    /* WaitComputeSignature */,
  XMK_B z_WTLS_0G_TerminateReq, 44 XMK_E,
  XMK_B ComputeSignatureResponse, 24 XMK_E,
  XMK_B z_WTLS_0U_ErrorIndication, 45 XMK_E

    /* WaitPRFResponseFull1 */,
  XMK_B z_WTLS_0G_TerminateReq, 44 XMK_E,
  XMK_B PRFResponse, 25 XMK_E,
  XMK_B z_WTLS_0U_ErrorIndication, 45 XMK_E,
  XMK_B XASTERISK, XSAVEID XMK_E

    /* WaitFinishedFull */,
  XMK_B z_WTLS_0G_TerminateReq, 44 XMK_E,
  XMK_B z_WTLS_0K_AlertIndication, 29 XMK_E,
  XMK_B z_WTLS_0S_MessageIndication, 28 XMK_E,
  XMK_B z_WTLS_0U_ErrorIndication, 45 XMK_E

    /* WaitPRFResponseFull2 */,
  XMK_B z_WTLS_0G_TerminateReq, 44 XMK_E,
  XMK_B PRFResponse, 30 XMK_E,
  XMK_B z_WTLS_0U_ErrorIndication, 45 XMK_E,
  XMK_B XASTERISK, XSAVEID XMK_E

    /* WaitKeyExchange2 */,
  XMK_B z_WTLS_0G_TerminateReq, 44 XMK_E,
  XMK_B KeyExchangeResponse, 31 XMK_E,
  XMK_B z_WTLS_0U_ErrorIndication, 45 XMK_E,
  XMK_B XASTERISK, XSAVEID XMK_E

    /* WaitCCSAbbr */,
  XMK_B z_WTLS_0G_TerminateReq, 44 XMK_E,
  XMK_B z_WTLS_0K_AlertIndication, 33 XMK_E,
  XMK_B z_WTLS_0S_MessageIndication, 32 XMK_E,
  XMK_B z_WTLS_0U_ErrorIndication, 45 XMK_E

    /* WaitFinishedAbbr */,
  XMK_B z_WTLS_0G_TerminateReq, 44 XMK_E,
  XMK_B z_WTLS_0K_AlertIndication, 35 XMK_E,
  XMK_B z_WTLS_0S_MessageIndication, 34 XMK_E,
  XMK_B z_WTLS_0U_ErrorIndication, 45 XMK_E

    /* WaitPRFResponseAbbr1 */,
  XMK_B z_WTLS_0G_TerminateReq, 44 XMK_E,
  XMK_B PRFResponse, 36 XMK_E,
  XMK_B z_WTLS_0U_ErrorIndication, 45 XMK_E,
  XMK_B XASTERISK, XSAVEID XMK_E

    /* WaitPRFResponseAbbr2 */,
  XMK_B z_WTLS_0G_TerminateReq, 44 XMK_E,
  XMK_B PRFResponse, 37 XMK_E,
  XMK_B z_WTLS_0U_ErrorIndication, 45 XMK_E,
  XMK_B XASTERISK, XSAVEID XMK_E

    /* Opening */,
  XMK_B z_WTLS_0E_OutboundMsgs, 38 XMK_E,
  XMK_B z_WTLS_0G_TerminateReq, 44 XMK_E,
  XMK_B z_WTLS_0K_AlertIndication, 39 XMK_E,
  XMK_B z_WTLS_0S_MessageIndication, 40 XMK_E,
  XMK_B z_WTLS_0U_ErrorIndication, 45 XMK_E

    /* Open */,
  XMK_B z_WTLS_0E_OutboundMsgs, 43 XMK_E,
  XMK_B z_WTLS_0G_TerminateReq, 44 XMK_E,
  XMK_B z_WTLS_0K_AlertIndication, 42 XMK_E,
  XMK_B z_WTLS_0S_MessageIndication, 41 XMK_E,
  XMK_B z_WTLS_0U_ErrorIndication, 45 XMK_E

    /* WaitTerminateInd */,
  XMK_B z_WTLS_0G_TerminateReq, 44 XMK_E,
  XMK_B z_WTLS_0F_TerminateInd, 46 XMK_E,
  XMK_B z_WTLS_0U_ErrorIndication, 45 XMK_E
};

/*-----------Process-PID-Values-------------*/
#ifdef XMK_USE_PID_ADDRESSING
static xPIDTable yPID_TBL_z48_WTLS_CM[X_MAX_INST_z48_WTLS_CM];
#endif

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -