diff options
Diffstat (limited to 'source3/include/nameserv.h')
-rw-r--r-- | source3/include/nameserv.h | 80 |
1 files changed, 29 insertions, 51 deletions
diff --git a/source3/include/nameserv.h b/source3/include/nameserv.h index 1d1cf85962..e4876bac57 100644 --- a/source3/include/nameserv.h +++ b/source3/include/nameserv.h @@ -54,19 +54,6 @@ #define NB_HFLAG 0x60 /* microsoft 'hybrid' node type */ #define NB_FLGMSK 0x60 - -#define WG_BROWSE_SIGNATURE 0x017e -#define WG_BROWSE_VERSION 0xff08 - -#define HOST_BROWSE_SIGNATURE 0xaa55 -#define HOST_BROWSE_VERSION 0x010f - -#define WG_MAJOR_VERSION 0x03 -#define WG_MINOR_VERSION 0x0a - -#define HOST_MAJOR_VERSION 0x04 /* nt/as host version */ -#define HOST_MINOR_VERSION 0x01 /* one better than current nt/as version */ - #define REFRESH_TIME (15*60) #define NAME_POLL_REFRESH_TIME (5*60) #define NAME_POLL_INTERVAL 15 @@ -86,7 +73,7 @@ /* server type identifiers */ #define AM_MASTER(work) (work->ServerType & SV_TYPE_MASTER_BROWSER) #define AM_BACKUP(work) (work->ServerType & SV_TYPE_BACKUP_BROWSER) -#define AM_DMBRSE(work) (work->ServerType & SV_TYPE_DOMAIN_MASTER) +#define AM_DOMCTL(work) (work->ServerType & SV_TYPE_DOMAIN_CTRL) /* microsoft browser NetBIOS name */ #define MSBROWSE "\001\002__MSBROWSE__\002" @@ -112,19 +99,19 @@ enum master_state enum state_type { - NAME_STATUS_DOM_SRV_CHK, - NAME_STATUS_SRV_CHK, - NAME_REGISTER_CHALLENGE, - NAME_REGISTER, - NAME_RELEASE, - NAME_QUERY_CONFIRM, - NAME_QUERY_ANNOUNCE_HOST, - NAME_QUERY_SYNC_LOCAL, - NAME_QUERY_SYNC_REMOTE, - NAME_QUERY_DOM_SRV_CHK, - NAME_QUERY_SRV_CHK, - NAME_QUERY_FIND_MST, - NAME_QUERY_MST_CHK + NAME_STATUS_DOM_SRV_CHK, + NAME_STATUS_SRV_CHK, + NAME_REGISTER_CHALLENGE, + NAME_REGISTER, + NAME_RELEASE, + NAME_QUERY_CONFIRM, + NAME_QUERY_ANNOUNCE_HOST, + NAME_QUERY_SYNC_LOCAL, + NAME_QUERY_SYNC_REMOTE, + NAME_QUERY_DOM_SRV_CHK, + NAME_QUERY_SRV_CHK, + NAME_QUERY_FIND_MST, + NAME_QUERY_MST_CHK }; /* a netbios name structure */ @@ -134,14 +121,6 @@ struct nmb_name { int name_type; }; -/* A server name and comment. */ -struct server_identity -{ - char *name; - char *comment; - struct server_identity *next; -}; - /* a netbios flags + ip address structure */ /* this is used for multi-homed systems and for internet group names */ struct nmb_ip @@ -169,16 +148,16 @@ struct name_record /* browse and backup server cache for synchronising browse list */ struct browse_cache_record { - struct browse_cache_record *next; - struct browse_cache_record *prev; - - char name[17]; - int type; - char group[17]; - struct in_addr ip; - time_t sync_time; - BOOL synced; - BOOL local; + struct browse_cache_record *next; + struct browse_cache_record *prev; + + pstring name; + int type; + pstring group; + struct in_addr ip; + time_t sync_time; + BOOL synced; + BOOL local; }; /* this is used to hold the list of servers in my domain, and is */ @@ -204,7 +183,7 @@ struct work_record enum master_state state; /* work group info */ - char work_group[17]; + fstring work_group; int token; /* used when communicating with backup browsers */ int ServerType; @@ -235,18 +214,17 @@ struct response_record int fd; int quest_type; struct nmb_name name; - struct nmb_ip reply; + int nb_flags; time_t ttl; - enum name_source source; - int token; /* unique workgroup token id */ int server_type; - char my_name[17]; - char my_comment[50]; + fstring my_name; + fstring my_comment; BOOL bcast; BOOL recurse; struct in_addr send_ip; + struct in_addr reply_to_ip; int num_msgs; |