VirtualBox

source: vbox/trunk/src/VBox/Additions/WINNT/VBoxCredProv/helpers.h@ 26084

最後變更 在這個檔案從26084是 25811,由 vboxsync 提交於 15 年 前

VBoxCredProv: Enabled building by default on OSE (second try).

  • 屬性 svn:eol-style 設為 native
  • 屬性 svn:keywords 設為 Author Date Id Revision
檔案大小: 1.6 KB
 
1//
2// THIS CODE AND INFORMATION IS PROVIDED "AS IS" WITHOUT WARRANTY OF
3// ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING BUT NOT LIMITED TO
4// THE IMPLIED WARRANTIES OF MERCHANTABILITY AND/OR FITNESS FOR A
5// PARTICULAR PURPOSE.
6//
7// Copyright (c) 2006 Microsoft Corporation. All rights reserved.
8//
9// Helper functions for copying parameters and packaging the buffer
10// for GetSerialization.
11//
12// Modifications (c) 2009 Sun Microsystems, Inc.
13//
14
15#pragma once
16#include "common.h"
17#include <windows.h>
18#include <strsafe.h>
19
20#pragma warning(push)
21#pragma warning(disable : 4995)
22#include <shlwapi.h>
23#pragma warning(pop)
24
25
26
27//makes a copy of a field descriptor using CoTaskMemAlloc
28HRESULT FieldDescriptorCoAllocCopy(
29 const CREDENTIAL_PROVIDER_FIELD_DESCRIPTOR& rcpfd,
30 CREDENTIAL_PROVIDER_FIELD_DESCRIPTOR** ppcpfd
31 );
32
33//makes a copy of a field descriptor on the normal heap
34HRESULT FieldDescriptorCopy(
35 const CREDENTIAL_PROVIDER_FIELD_DESCRIPTOR& rcpfd,
36 CREDENTIAL_PROVIDER_FIELD_DESCRIPTOR* pcpfd
37 );
38
39//creates a UNICODE_STRING from a normal string
40HRESULT UnicodeStringInitWithString(
41 PWSTR pwz,
42 UNICODE_STRING* pus
43 );
44
45//packages the credentials into the buffer that the system expects
46HRESULT KerbInteractiveLogonPack(
47 const KERB_INTERACTIVE_LOGON& rkil,
48 BYTE** prgb,
49 DWORD* pcb
50 );
51
52//unpackages the "packed" version of the creds in-place into the "unpacked" version
53void KerbInteractiveLogonUnpackInPlace(
54 KERB_INTERACTIVE_UNLOCK_LOGON* pkiul
55 );
56
57
58//get the authentication package that will be used for our logon attempt
59HRESULT RetrieveNegotiateAuthPackage(
60 ULONG * pulAuthPackage
61 );
注意: 瀏覽 TracBrowser 來幫助您使用儲存庫瀏覽器

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette