static u_long body_StreamMessage (int v, u_char *b) { u_char *b_org = b; u_int nx,n2,n6; n2 = outBit_Sx_NL (v,"objectInfo_length: ", b, 0, 16); b += 2; nx = BIOP_DSM_Stream_Info_T (v, b); // $$$ Warning: Standards documents may describe wrong length calculation! print_databytes (v,"ObjectInfo_byte:", b+nx, n2-nx); b += n2; nx = do_ServiceContentList (v, b); b += nx; outBit_Sx_NL (v,"messageBody_length: ", b, 0, 32); n6 = outBit_Sx_NL (v,"tap_count: ", b, 32, 8); b += 5; indent (+1); for (; n6 > 0; n6--) { int ny; ny = BIOP_TAP (v, "", b); b += ny; } indent (-1); return (u_long) (b - b_org); }
int BIOP_ModuleInfo (int v, u_char *b, u_int len_org) { int len = len_org; int n1, i; // -- due to some misbehavior of some service providers // -- we do a simple plausi check for tap_counts_min_bytes > len i = getBits (b, 0, 96, 8); // tap_counts i = i * 7; if (i > len_org) { // this is no ModuleInfo print_databytes (v,"Data Bytes (non-standard):", b, len_org); return len_org; } out_nl (v, "BIOP::ModuleInfo:"); indent (+1); outBit_S2Tx_NL (v,"ModuleTimeOut: ", b, 0, 32, "(ms)"); outBit_S2Tx_NL (v,"BlockTimeOut: ", b, 32, 32, "(ms)"); outBit_S2Tx_NL (v,"MinBlockTime: ", b, 64, 32, "(ms)"); n1 = outBit_Sx_NL (v,"taps_count: ", b, 96, 8); b += 13, len -= 13; indent (+1); while (n1-- > 0) { int n2; // BIOP_OBJECT_USE n2 = BIOP_TAP (v, "DSM", b); b += n2; len -= n2; } indent (-1); out_NL (v); n1 = outBit_Sx_NL (v,"userInfoLength: ", b, 0, 8); // print_databytes (v,"UserInfoData:", b, n1); dsmcc_CarouselDescriptor_Loop ("userInfo", b+1, n1); b += 1+n1; len -= 1+n1; indent (-1); return len_org; }
static u_long body_StreamEventMessage (int v, u_char *b) { u_char *b_org = b; u_int nx,ny,n2,n8,n4; n2 = outBit_Sx_NL (v,"objectInfo_length: ", b, 0, 16); b += 2; nx = BIOP_DSM_Stream_Info_T (v, b); ny = BIOP_DSM_Event_EventList_T (v, b+nx); print_databytes (v,"ObjectInfo_byte:", b+nx, n2-nx-ny); b += n2; nx = do_ServiceContentList (v, b); b += nx; outBit_Sx_NL (v,"messageBody_length: ", b, 0, 32); n8 = outBit_Sx_NL (v,"tap_count: ", b, 32, 8); b += 5; indent (+1); for (; n8 > 0; n8--) { int nz; nz = BIOP_TAP (v, "", b); b += nz; } indent (-1); n4 = outBit_Sx_NL (v,"eventIds_count: ", b, 0, 8); b += 1; indent (+1); for (; n4 > 0; n4--) { outBit_Sx_NL (v,"eventId: ", b, 0, 16); b += 2; } indent (-1); return (u_long) (b - b_org); }