36 static const WCHAR wszServiceClass[] = {
'c',
'l',
'a',
's',
's',0};
37 static const WCHAR wszServiceHost[] = {
'h',
'o',
's',
't',0};
38 static const WCHAR wszInstanceName[] = {
'i',
'n',
's',
't',
'a',
'n',
'c',
'e',0};
39 static const WCHAR wszReferrer[] = {
'r',
'e',
'f',
'e',
'r',
'r',
'e',
'r',0};
40 static const WCHAR wszSpn1[] = {
'c',
'l',
'a',
's',
's',
'/',
'h',
'o',
's',
't',0};
41 static const WCHAR wszSpn2[] = {
'c',
'l',
'a',
's',
's',
'/',
'i',
'n',
's',
't',
'a',
'n',
'c',
'e',
'/',
'h',
'o',
's',
't',0};
42 static const WCHAR wszSpn3[] = {
'c',
'l',
'a',
's',
's',
'/',
'i',
'n',
's',
't',
'a',
'n',
'c',
'e',
':',
'5',
'5',
'5',
'/',
'h',
'o',
's',
't',0};
43 static const WCHAR wszSpn4[] = {
'c',
'l',
'a',
's',
's',
'/',
'i',
'n',
's',
't',
'a',
'n',
'c',
'e',
':',
'5',
'5',
'5',
'/',
'h',
'o',
's',
't',0};
44 static const WCHAR wszSpn5[] = {
'c',
'l',
'a',
's',
's',
'/',
'h',
'o',
's',
't',
':',
'5',
'5',
'5',0};
60 ok(spn_length ==
lstrlenW(wszSpn1) + 1,
"DsMakeSpnW should have returned spn_length of %d instead of %d\n",
lstrlenW(wszSpn1) + 1, spn_length);
63 ret =
DsMakeSpnW(wszServiceClass, wszServiceHost, wszInstanceName, 0,
NULL, &spn_length, spn);
66 ok(spn_length ==
lstrlenW(wszSpn2) + 1,
"DsMakeSpnW should have returned spn_length of %d instead of %d\n",
lstrlenW(wszSpn2) + 1, spn_length);
69 ret =
DsMakeSpnW(wszServiceClass, wszServiceHost, wszInstanceName, 555,
NULL, &spn_length, spn);
72 ok(spn_length ==
lstrlenW(wszSpn3) + 1,
"DsMakeSpnW should have returned spn_length of %d instead of %d\n",
lstrlenW(wszSpn3) + 1, spn_length);
75 ret =
DsMakeSpnW(wszServiceClass, wszServiceHost, wszInstanceName, 555, wszReferrer, &spn_length, spn);
78 ok(spn_length ==
lstrlenW(wszSpn4) + 1,
"DsMakeSpnW should have returned spn_length of %d instead of %d\n",
lstrlenW(wszSpn4) + 1, spn_length);
81 ret =
DsMakeSpnW(wszServiceClass, wszServiceHost,
NULL, 555, wszReferrer, &spn_length, spn);
84 ok(spn_length ==
lstrlenW(wszSpn5) + 1,
"DsMakeSpnW should have returned spn_length of %d instead of %d\n",
lstrlenW(wszSpn5) + 1, spn_length);
89 static const WCHAR classW[] = {
'c',
'l',
'a',
's',
's',0};
90 static const WCHAR hostW[] = {
'h',
'o',
's',
't',
'.',
'd',
'o',
'm',
'a',
'i',
'n',0};
91 static const WCHAR resultW[] = {
'c',
'l',
'a',
's',
's',
'/',
'h',
'o',
's',
't',
'.',
'd',
'o',
'm',
'a',
'i',
'n',0};
#define ERROR_INVALID_PARAMETER
DWORD WINAPI DsMakeSpnW(LPCWSTR svc_class, LPCWSTR svc_name, LPCWSTR inst_name, USHORT inst_port, LPCWSTR ref, DWORD *spn_length, LPWSTR spn)
DWORD WINAPI DsClientMakeSpnForTargetServerW(LPCWSTR class, LPCWSTR name, DWORD *buflen, LPWSTR buf)
GLenum GLuint GLenum GLsizei const GLchar * buf
int WINAPI lstrcmpW(LPCWSTR lpString1, LPCWSTR lpString2)
static void test_DsClientMakeSpnForTargetServer(void)
static void test_DsMakeSpn(void)
static const WCHAR hostW[]
static const WCHAR classW[]
#define ERROR_BUFFER_OVERFLOW