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

📄 ss7trace.h

📁 基于NMS的ss7 4.3写的信令跟踪程序 log到文件 用ethereal可打开
💻 H
字号:
/*************************************************************************
**                                                                      **
**                         PROPRIETARY NOTICE                           **
**                                                                      **
**                        Copyright (c) 2001                            **
**                      by Natural MicroSystems, Inc.                   **
**                                                                      **
**  The following is licensed program material and is considered        **
**  proprietary and confidential.  No part of this program may be       **
**  reproduced or used in any form or by any means without the express  **
**  written permission of Natural MicroSystems, Inc.                    **
**                                                                      **
*************************************************************************/

/*************************************************************************
**                                                                      **
**    ISUP trace definition. See file: isupmgmt.h & apidef.h            **
**                                                                      **
*************************************************************************/

#ifdef UNIX
#pragma pack(1)
#endif

typedef struct _entityId           /* entity id */

{
   U8 ent;                       /* entity */
   U8 inst;                     /* instance */
   U16 spare1;
} EntityId;

typedef struct _elmntId            /* element id */

{
   S16   elmnt;                   /* element */
   S16   elmntInst1;              /* element instance 1 */
   S16   elmntInst2;              /* element instance 2 */
   S16   elmntInst3;              /* element instance 3 */
} ElmntId;

typedef struct _mgmtHeader       /* header */

{
   U16 msgLen;                  /* message length   - optional */
   U8 msgType;                  /* message type     - mandatory */
   U8 version;                  /* version          - optional */
   U16 seqNmb;                  /* sequence number  - optional */
   U16 spare1;
   EntityId entId;              /* entity id        - mandatory */
   ElmntId elmId;               /* element id       - mandatory */
} MgmtHeader;

typedef struct _IsupTrc
{
    DateTime dt;
    U16 evnt;
    U8 sapType;
    U8 fill1;
    U32 dpc;
    S16 length;
    S16 fill2;
    U8 evntParm[280];
} IsupTrc;                    /* trace */

#define TRCMSGTX         11          /* trace - message transmitted */
#define TRCMSGRX         12          /* trace- message received */

typedef struct _IsupMgmtReq
{
  DPRH          dprh;
  S16           start;
  S16           end;
  U8            event;
  U8            fill1;
  U16           fill2;
  MgmtHeader    hdr;

  union
  {
    IsupTrc         trc;
  } req;
}IsupMgmtReq;

/*************************************************************************
**                                                                      **
**    TCAP trace definition                                             **
**                                                                      **
*************************************************************************/

typedef struct _TcapTrc             /* See File: lst.x : struct stMngmt */
{
     DateTime dt;                   /* date and time */
     U16      evnt;                 /* event */
     U16      len;                  /* trace length */
     U8       evntParm[280];        /* event parameters */
} TcapTrc;

typedef struct _TcapMgmtTrace
{
  DPRH          dprh;
  S16           start;
  S16           end;
  U8            event;
  U8            fill;
  U8            fill2;
  U8            fill3;
  MgmtHeader    hdr;

  union
  {
    TcapTrc     trc;
  } req;

} TcapMgmtTrace;

#define LST_MSG_RECVD      1    /* Message received    File: lst.h */
#define LST_MSG_TXED       2    /* Message transmitted File: lst.h */

/*************************************************************************
**                                                                      **
**    SCCP trace definition                                             **
**                                                                      **
*************************************************************************/

typedef struct _SccpTrc             /* See File: lsp.x : struct spMngmt */
{
     DateTime dt;                   /* date and time */
     U16      evnt;                 /* event */
     U16      len;                  /* trace length */
     U8       evntParm[280];        /* event parameters */
} SccpTrc;

typedef struct _SccpMgmtTrace
{
  DPRH          dprh;
  S16           start;
  S16           end;
  U8            event;
  U8            fill;
  U8            fill2;
  U8            fill3;
  MgmtHeader    hdr;

  union
  {
    SccpTrc     trc;
  } req;

} SccpMgmtTrace;

#define LSP_MSG_RECVD      1    /* Message received    File: lsp.h */
#define LSP_MSG_TXED       2    /* Message transmitted File: lsp.h */

/*************************************************************************
**                                                                      **
**    MTP3 trace definition                                             **
**                                                                      **
*************************************************************************/

typedef struct _mtp3Trc             /* See File: lsn.x : struct stMngmt */
{
         DateTime dt;            /* date and time */
         U16      evnt;          /* event */
         U16      len;                  /* trace length */
         U8       evntParm[280];  /* event parameters (Maximum packet is 273 with SIO byte but length is in 1st byte only */
} mtp3Trc;

typedef struct _mtp3MgmtTrace
{
  DPRH          dprh;
  S16           start;
  S16           end;
  U8            event;
  U8            fill;
  U8            fill2;
  U8            fill3;
  MgmtHeader    hdr;

  union
  {
         mtp3Trc     trc;
  } req;

} mtp3MgmtTrace;

/*************************************************************************
**                                                                      **
**    IUP trace definition                                             **
**                                                                      **
*************************************************************************/
typedef struct _iupHdrM {
    DPRH    dpr;
    U16     start;
    U16     end;
    U8 event;
    U8 spare1;                          /* Spare for alignment */
    U8 spare2;                          /* Spare for alignment */
    U8 spare3;                          /* Spare for alignment */
    MgmtHeader    mgmthdr;
    U32     id;

#define SDUID_      0x21534455      /* !SDU */
#define MDUID_      0x214d4455      /* !MDU */
#define PDUID_      0x21504455      /* !PDU */
    void   *flink;
    void   *blink;
    S16     ccode;
    S16     fill1;
    U32     rvalu;
} IupHdrM;

typedef struct _IUPTrc
{
    DateTime dt;
    U16 evnt;
    /*U16 spare1;*/
    U8 sapType;
    U8 fill1;                            /* Spare for alignment */
    U32 dpc;
    S16 length;
    S16 fill4;                          /* Spare for alignment */
    U8 evntParm[64];
} IUPTrc;                    /* trace */

/* Management Data Unit structure */
typedef struct _iupMgmtTrace
{
    IupHdrM  hdr;
    U16     sapId;
    U16     groupId;
    U32     circId;
    U16     circCnt;
    /*U16     fill1;*/
    U8      evntType;
    U8      entType;
    IUPTrc         trc;
} IupMgmtTrace;

#ifdef UNIX
#pragma pack()
#endif

/*************************************************************************
**                                                                      **
**    TUP trace definition                                             **
**                                                                      **
*************************************************************************/
typedef struct _TUPTrace
{
    DateTime dt;
    U16 evnt;
    U8 sapType;
    U8 fill;                            /* Spare for alignment */
    U32 dpc;
    S16 length;
    S16 fill1;
#ifndef MAX_LSI_TRC
#define MAX_LSI_TRC      280
#endif                              /* Spare for alignment */
    U8 evntParm[MAX_LSI_TRC];
} TUPTrace;                    /* trace */


typedef struct _tupMgmtTrace
{
    DPRH    dpr;
    U16     start;
    U16     end;
    U8 event;
    U8 spare1;                          /* Spare for alignment */
    U8 spare2;                          /* Spare for alignment */
    U8 spare3;                          /* Spare for alignment */
    U32     id;
  #ifndef SDUID_
  #define SDUID_      0x21534455      /* !SDU */
  #endif

  #ifndef MDUID_
  #define MDUID_      0x214d4455      /* !MDU */
  #endif

  #ifndef PDUID_
  #define PDUID_      0x21504455      /* !PDU */
  #endif
    S16     ccode;
    S16     fill1;                      /* Spare for alignment */
    U32     rvalu;
    U16     sapId;
    U16     groupId;
    U32     circId;
    U16     circCnt;
    U8      evntType;
    U8      entType;

    union
    {
      TUPTrace         trc;
    } data;
} TupMgmtTrace;

#define LSN_MSG_RX           0        /* event - message received */
#define LSN_MSG_TX           1        /* event - message transmitted */

⌨️ 快捷键说明

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