~zulcss/samba/server-dailies-3.4

« back to all changes in this revision

Viewing changes to source4/libnet/libnet_rpc.h

  • Committer: Chuck Short
  • Date: 2010-09-28 20:38:39 UTC
  • Revision ID: zulcss@ubuntu.com-20100928203839-pgjulytsi9ue63x1
Initial version

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
/* 
 
2
   Unix SMB/CIFS implementation.
 
3
   
 
4
   Copyright (C) Stefan Metzmacher      2004
 
5
   
 
6
   This program is free software; you can redistribute it and/or modify
 
7
   it under the terms of the GNU General Public License as published by
 
8
   the Free Software Foundation; either version 3 of the License, or
 
9
   (at your option) any later version.
 
10
   
 
11
   This program is distributed in the hope that it will be useful,
 
12
   but WITHOUT ANY WARRANTY; without even the implied warranty of
 
13
   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 
14
   GNU General Public License for more details.
 
15
   
 
16
   You should have received a copy of the GNU General Public License
 
17
   along with this program.  If not, see <http://www.gnu.org/licenses/>.
 
18
*/
 
19
 
 
20
 
 
21
#include "librpc/rpc/dcerpc.h"
 
22
 
 
23
/*
 
24
 * struct definition for connecting to a dcerpc inferface
 
25
 */
 
26
 
 
27
enum libnet_RpcConnect_level {
 
28
        LIBNET_RPC_CONNECT_SERVER,          /* connect to a standalone rpc server */
 
29
        LIBNET_RPC_CONNECT_SERVER_ADDRESS,  /* connect to a standalone rpc server, 
 
30
                                               knowing both name and address */
 
31
        LIBNET_RPC_CONNECT_PDC,             /* connect to a domain pdc (resolves domain
 
32
                                               name to a pdc address before connecting) */
 
33
        LIBNET_RPC_CONNECT_DC,              /* connect to any DC (resolves domain
 
34
                                               name to a DC address before connecting) */
 
35
        LIBNET_RPC_CONNECT_BINDING,         /* specified binding string */
 
36
        LIBNET_RPC_CONNECT_DC_INFO          /* connect to a DC and provide basic domain
 
37
                                               information (name, realm, sid, guid) */
 
38
};
 
39
 
 
40
struct libnet_RpcConnect {
 
41
        enum libnet_RpcConnect_level level;
 
42
 
 
43
        struct {
 
44
                const char *name;
 
45
                const char *address;
 
46
                const char *binding;
 
47
                const struct ndr_interface_table *dcerpc_iface;
 
48
        } in;
 
49
        struct {
 
50
                struct dcerpc_pipe *dcerpc_pipe;
 
51
                
 
52
                /* parameters provided in LIBNET_RPC_CONNECT_DC_INFO level, null otherwise */
 
53
                const char *domain_name;
 
54
                struct dom_sid *domain_sid;
 
55
                const char *realm;           /* these parameters are only present if */
 
56
                struct GUID *guid;           /* the remote server is known to be AD */
 
57
 
 
58
                const char *error_string;
 
59
        } out;
 
60
};
 
61
 
 
62
 
 
63
/*
 
64
 * Monitor messages sent from libnet_rpc.c functions
 
65
 */
 
66
 
 
67
struct msg_net_rpc_connect {
 
68
        const char *host;
 
69
        const char *domain_name;
 
70
        const char *endpoint;
 
71
        enum dcerpc_transport_t transport;
 
72
};