mirror of
https://github.com/samba-team/samba.git
synced 2025-02-22 05:57:43 +03:00
r1543: add srvsvc_NetRemoteTOD idl and torture tests
metze
This commit is contained in:
parent
0f7b473b4a
commit
3f2b77d7ec
@ -1119,9 +1119,29 @@
|
||||
WERROR srvsvc_NETRSERVERTRANSPORTDEL(
|
||||
);
|
||||
|
||||
/**************************/
|
||||
/* srvsvc_NetRemoteTOD */
|
||||
/**************************/
|
||||
typedef struct {
|
||||
uint32 elapsed;
|
||||
uint32 msecs;
|
||||
uint32 hours;
|
||||
uint32 mins;
|
||||
uint32 secs;
|
||||
uint32 hunds;
|
||||
uint32 timezone;
|
||||
uint32 tinterval;
|
||||
uint32 day;
|
||||
uint32 month;
|
||||
uint32 year;
|
||||
uint32 weekday;
|
||||
} srvsvc_NetRemoteTODInfo;
|
||||
|
||||
/******************/
|
||||
/* Function: 0x1c */
|
||||
WERROR srvsvc_NET_REMOTE_TOD(
|
||||
WERROR srvsvc_NetRemoteTOD(
|
||||
[in] unistr *server_unc,
|
||||
[out] srvsvc_NetRemoteTODInfo *info
|
||||
);
|
||||
|
||||
/**************************/
|
||||
|
@ -642,6 +642,32 @@ static BOOL test_NetTransportEnum(struct dcerpc_pipe *p,
|
||||
return ret;
|
||||
}
|
||||
|
||||
/**************************/
|
||||
/* srvsvc_NetRemoteTOD */
|
||||
/**************************/
|
||||
static BOOL test_NetRemoteTOD(struct dcerpc_pipe *p,
|
||||
TALLOC_CTX *mem_ctx)
|
||||
{
|
||||
NTSTATUS status;
|
||||
struct srvsvc_NetRemoteTOD r;
|
||||
BOOL ret = True;
|
||||
|
||||
r.in.server_unc = talloc_asprintf(mem_ctx,"\\\\%s",dcerpc_server_name(p));
|
||||
|
||||
ZERO_STRUCT(r.out);
|
||||
printf("testing NetRemoteTOD\n");
|
||||
status = dcerpc_srvsvc_NetRemoteTOD(p, mem_ctx, &r);
|
||||
if (!NT_STATUS_IS_OK(status)) {
|
||||
printf("NetRemoteTOD failed - %s\n", nt_errstr(status));
|
||||
ret = False;
|
||||
}
|
||||
if (!W_ERROR_IS_OK(r.out.result)) {
|
||||
printf("NetRemoteTOD failed - %s\n", win_errstr(r.out.result));
|
||||
}
|
||||
|
||||
return ret;
|
||||
}
|
||||
|
||||
BOOL torture_rpc_srvsvc(int dummy)
|
||||
{
|
||||
NTSTATUS status;
|
||||
@ -695,6 +721,10 @@ BOOL torture_rpc_srvsvc(int dummy)
|
||||
ret = False;
|
||||
}
|
||||
|
||||
if (!test_NetRemoteTOD(p, mem_ctx)) {
|
||||
ret = False;
|
||||
}
|
||||
|
||||
if (!test_NetShareEnum(p, mem_ctx)) {
|
||||
ret = False;
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user