summaryrefslogtreecommitdiffstats
path: root/private/nw/svcdlls/nwwks/inc/sapcmn.h
blob: fa8f8449e7a8e1e10b1812b3bdd6db9c04fc7e45 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
/*++

Copyright (c) 1992-1993  Microsoft Corporation

Module Name:

    sapcmn.h.h

Abstract:

    Header containing the most basic common SAP definitions. This
    was derived from the larger file, nwmisc.h in order to
    be available to either the old RNR or the new RNR routines.

Author:

    Arnold Miller (ArnoldM)     8-Dec-95

Revision History:

    ArnoldM 8-Dec-95 Created from pieces of nwmisc.h
--*/

#ifndef __SAPCMN_H__
#define __SAPCMN_H__
//
// Definitions common to client and server side files (getaddr.c and service.c)
//

#define IPX_ADDRESS_LENGTH         12
#define IPX_ADDRESS_NETNUM_LENGTH  4
#define SAP_ADDRESS_LENGTH         15
#define SAP_ADVERTISE_FREQUENCY    60000  // 60 seconds
#define SAP_MAXRECV_LENGTH         544
#define SAP_OBJECT_NAME_MAX_LENGTH 48

//
// N.B. Keep the following defines in synch.
//
#define NW_RDR_PREFERRED_SERVER   L"\\Device\\Nwrdr\\*"
#define NW_RDR_NAME               L"\\Device\\Nwrdr\\"
#define NW_RDR_PREFERRED_SUFFIX    L"*"
//
// Sap server identification packet format
//

typedef struct _SAP_IDENT_HEADER {
    USHORT ServerType;
    UCHAR  ServerName[48];
    UCHAR  Address[IPX_ADDRESS_LENGTH];
    USHORT HopCount;
} SAP_IDENT_HEADER, *PSAP_IDENT_HEADER;


//
// Sap server identification packet format - Extended
//

typedef struct _SAP_IDENT_HEADER_EX {
    USHORT ResponseType;
    USHORT ServerType;
    UCHAR  ServerName[SAP_OBJECT_NAME_MAX_LENGTH];
    UCHAR  Address[IPX_ADDRESS_LENGTH];
    USHORT HopCount;
} SAP_IDENT_HEADER_EX, *PSAP_IDENT_HEADER_EX;
#endif