2 * Copyright 2005 Francois Gouget
4 * This library is free software; you can redistribute it and/or
5 * modify it under the terms of the GNU Lesser General Public
6 * License as published by the Free Software Foundation; either
7 * version 2.1 of the License, or (at your option) any later version.
9 * This library is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12 * Lesser General Public License for more details.
14 * You should have received a copy of the GNU Lesser General Public
15 * License along with this library; if not, write to the Free Software
16 * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
22 #define threading
(model
)
24 #define vi_progid
(str
)
28 helpstring("Active DS Type Library"),
29 uuid(97d25db0
-0363-11cf
-abc4
-02608c9e7553
),
35 importlib
("stdole2.tlb");
39 ADS_RIGHT_DS_CREATE_CHILD
= 0x00000001,
40 ADS_RIGHT_DS_DELETE_CHILD
= 0x00000002,
41 ADS_RIGHT_ACTRL_DS_LIST
= 0x00000004,
42 ADS_RIGHT_DS_SELF
= 0x00000008,
43 ADS_RIGHT_DS_READ_PROP
= 0x00000010,
44 ADS_RIGHT_DS_WRITE_PROP
= 0x00000020,
45 ADS_RIGHT_DS_DELETE_TREE
= 0x00000040,
46 ADS_RIGHT_DS_LIST_OBJECT
= 0x00000080,
47 ADS_RIGHT_DS_CONTROL_ACCESS
= 0x00000100,
49 ADS_RIGHT_DELETE
= 0x00010000,
50 ADS_RIGHT_READ_CONTROL
= 0x00020000,
51 ADS_RIGHT_WRITE_DAC
= 0x00040000,
52 ADS_RIGHT_WRITE_OWNER
= 0x00080000,
53 ADS_RIGHT_SYNCHRONIZE
= 0x00100000,
54 ADS_RIGHT_ACCESS_SYSTEM_SECURITY
= 0x00200000,
56 ADS_RIGHT_GENERIC_ALL
= 0x10000000,
57 ADS_RIGHT_GENERIC_EXECUTE
= 0x20000000,
58 ADS_RIGHT_GENERIC_WRITE
= 0x40000000,
59 ADS_RIGHT_GENERIC_READ
= 0x80000000
64 ADS_SECURE_AUTHENTICATION
= 0x1,
65 ADS_USE_ENCRYPTION
= 0x2,
67 ADS_READONLY_SERVER
= 0x4,
68 ADS_PROMPT_CREDENTIALS
= 0x8,
69 ADS_NO_AUTHENTICATION
= 0x10,
71 ADS_USE_SIGNING
= 0x40,
72 ADS_USE_SEALING
= 0x80,
73 ADS_USE_DELEGATION
= 0x100,
74 ADS_SERVER_BIND
= 0x200,
75 ADS_NO_REFERRAL_CHASING
= 0x400,
76 ADS_AUTH_RESERVED
= 0x80000000
77 } ADS_AUTHENTICATION_ENUM
;
81 ADS_SEARCHPREF_ASYNCHRONOUS
,
82 ADS_SEARCHPREF_DEREF_ALIASES
,
83 ADS_SEARCHPREF_SIZE_LIMIT
,
84 ADS_SEARCHPREF_TIME_LIMIT
,
85 ADS_SEARCHPREF_ATTRIBTYPES_ONLY
,
86 ADS_SEARCHPREF_SEARCH_SCOPE
,
87 ADS_SEARCHPREF_TIMEOUT
,
88 ADS_SEARCHPREF_PAGESIZE
,
89 ADS_SEARCHPREF_PAGED_TIME_LIMIT
,
90 ADS_SEARCHPREF_CHASE_REFERRALS
,
91 ADS_SEARCHPREF_SORT_ON
,
92 ADS_SEARCHPREF_CACHE_RESULTS
,
93 ADS_SEARCHPREF_DIRSYNC
,
94 ADS_SEARCHPREF_TOMBSTONE
,
96 ADS_SEARCHPREF_ATTRIBUTE_QUERY
,
97 ADS_SEARCHPREF_SECURITY_MASK
,
98 ADS_SEARCHPREF_DIRSYNC_FLAG
,
99 ADS_SEARCHPREF_EXTENDED_DN
100 } ADS_SEARCHPREF_ENUM
;
105 ADS_STATUS_INVALID_SEARCHPREF
,
106 ADS_STATUS_INVALID_SEARCHPREFVALUE
113 ADSTYPE_CASE_EXACT_STRING
,
114 ADSTYPE_CASE_IGNORE_STRING
,
115 ADSTYPE_PRINTABLE_STRING
,
116 ADSTYPE_NUMERIC_STRING
,
119 ADSTYPE_OCTET_STRING
,
121 ADSTYPE_LARGE_INTEGER
,
122 ADSTYPE_PROV_SPECIFIC
,
123 ADSTYPE_OBJECT_CLASS
,
124 ADSTYPE_CASEIGNORE_LIST
,
127 ADSTYPE_POSTALADDRESS
,
133 ADSTYPE_REPLICAPOINTER
,
136 ADSTYPE_NT_SECURITY_DESCRIPTOR
,
138 ADSTYPE_DN_WITH_BINARY
,
139 ADSTYPE_DN_WITH_STRING
151 ADS_PASSWORD_ENCODE_REQUIRE_SSL
,
152 ADS_PASSWORD_ENCODE_CLEAR
153 } ADS_PASSWORD_ENCODING_ENUM
;
155 typedef struct _ADS_CASEIGNORE_LIST
157 struct _ADS_CASEIGNORE_LIST
*Next
;
159 } ADS_CASEIGNORE_LIST
;
161 typedef struct _ADS_OCTET_LIST
163 struct _ADS_OCTET_LIST
*Next
;
173 } ADS_PATH
, *PADS_PATH
;
182 typedef ADSTYPEENUM ADSTYPE
;
183 typedef LPWSTR ADS_DN_STRING
;
184 typedef LPWSTR
*PADS_DN_STRING
;
185 typedef LPWSTR ADS_CASE_EXACT_STRING
;
186 typedef LPWSTR
*PADS_CASE_EXACT_STRING
;
187 typedef LPWSTR ADS_CASE_IGNORE_STRING
;
188 typedef LPWSTR
*PADS_CASE_IGNORE_STRING
;
189 typedef LPWSTR ADS_PRINTABLE_STRING
;
190 typedef LPWSTR
*PADS_PRINTABLE_STRING
;
191 typedef LPWSTR ADS_NUMERIC_STRING
;
192 typedef LPWSTR
*PADS_NUMERIC_STRING
;
193 typedef DWORD ADS_BOOLEAN
;
194 typedef DWORD
*LPNDS_BOOLEAN
;
195 typedef DWORD ADS_INTEGER
;
196 typedef DWORD
*PADS_INTEGER
;
197 typedef SYSTEMTIME ADS_UTC_TIME
;
198 typedef SYSTEMTIME
*PADS_UTC_TIME
;
199 typedef LARGE_INTEGER ADS_LARGE_INTEGER
;
200 typedef LARGE_INTEGER
*PADS_LARGE_INTEGER
;
201 typedef LPWSTR ADS_OBJECT_CLASS
;
202 typedef LPWSTR
*PADS_OBJECT_CLASS
;
203 typedef struct _ADS_OCTET_LIST
*PADS_OCTET_LIST
;
204 typedef struct _ADS_CASEIGNORE_LIST
*PADS_CASEIGNORE_LIST
;
205 typedef ADS_STATUSENUM ADS_STATUS
;
206 typedef ADS_SEARCHPREF_ENUM ADS_SEARCHPREF
;
207 typedef HANDLE ADS_SEARCH_HANDLE
;
208 typedef HANDLE *PADS_SEARCH_HANDLE
;
225 LPWSTR PostalAddress
[ 6 ];
226 } ADS_POSTALADDRESS
, *PADS_POSTALADDRESS
;
233 } ADS_TYPEDNAME
, *PADS_TYPEDNAME
;
252 } ADS_NETADDRESS
, *PADS_NETADDRESS
;
260 PADS_NETADDRESS ReplicaAddressHints
;
261 } ADS_REPLICAPOINTER
, *PADS_REPLICAPOINTER
;
265 LPWSTR TelephoneNumber
;
268 } ADS_FAXNUMBER
, *PADS_FAXNUMBER
;
275 } ADS_EMAIL
, *PADS_EMAIL
;
281 } ADS_NT_SECURITY_DESCRIPTOR
;
288 } ADS_DN_WITH_BINARY
, *PADS_DN_WITH_BINARY
;
292 LPWSTR pszStringValue
;
294 } ADS_DN_WITH_STRING
, *PADS_DN_WITH_STRING
;
296 typedef struct _adsvalue
301 ADS_DN_STRING DNString
;
302 ADS_CASE_EXACT_STRING CaseExactString
;
303 ADS_CASE_IGNORE_STRING CaseIgnoreString
;
304 ADS_PRINTABLE_STRING PrintableString
;
305 ADS_NUMERIC_STRING NumericString
;
308 ADS_OCTET_STRING OctetString
;
309 ADS_UTC_TIME UTCTime
;
310 ADS_LARGE_INTEGER LargeInteger
;
311 ADS_OBJECT_CLASS ClassName
;
312 ADS_PROV_SPECIFIC ProviderSpecific
;
313 PADS_CASEIGNORE_LIST pCaseIgnoreList
;
314 PADS_OCTET_LIST pOctetList
;
316 PADS_POSTALADDRESS pPostalAddress
;
317 ADS_TIMESTAMP Timestamp
;
318 ADS_BACKLINK BackLink
;
319 PADS_TYPEDNAME pTypedName
;
321 PADS_NETADDRESS pNetAddress
;
322 PADS_REPLICAPOINTER pReplicaPointer
;
323 PADS_FAXNUMBER pFaxNumber
;
325 ADS_NT_SECURITY_DESCRIPTOR SecurityDescriptor
;
326 PADS_DN_WITH_BINARY pDNWithBinary
;
327 PADS_DN_WITH_STRING pDNWithString
;
329 } ADSVALUE
, *PADSVALUE
;
331 typedef struct ads_searchpref_info
333 ADS_SEARCHPREF dwSearchPref
;
336 } ADS_SEARCHPREF_INFO
, *PADS_SEARCHPREF_INFO
;
338 typedef struct ads_search_column
342 PADSVALUE pADsValues
;
345 } ADS_SEARCH_COLUMN
, *PADS_SEARCH_COLUMN
;
347 typedef struct _ads_object_info
354 } ADS_OBJECT_INFO
, *PADS_OBJECT_INFO
;
356 typedef struct _ads_attr_info
361 PADSVALUE pADsValues
;
363 } ADS_ATTR_INFO
, *PADS_ATTR_INFO
;
367 ADS_SECURITY_INFO_OWNER
= 0x1,
368 ADS_SECURITY_INFO_GROUP
= 0x2,
369 ADS_SECURITY_INFO_DACL
= 0x4,
370 ADS_SECURITY_INFO_SACL
= 0x8
371 } ADS_SECURITY_INFO_ENUM
;
375 ADS_SETTYPE_FULL
= 1,
376 ADS_SETTYPE_PROVIDER
= 2,
377 ADS_SETTYPE_SERVER
= 3,
383 ADS_FORMAT_WINDOWS
= 1,
384 ADS_FORMAT_WINDOWS_NO_SERVER
= 2,
385 ADS_FORMAT_WINDOWS_DN
= 3,
386 ADS_FORMAT_WINDOWS_PARENT
= 4,
388 ADS_FORMAT_X500_NO_SERVER
= 6,
389 ADS_FORMAT_X500_DN
= 7,
390 ADS_FORMAT_X500_PARENT
= 8,
391 ADS_FORMAT_SERVER
= 9,
392 ADS_FORMAT_PROVIDER
= 10,
396 /*****************************************************************************
397 * IADsContainer interface
401 uuid(001677d0
-fd16
-11ce
-abc4
-02608c9e7553
)
403 interface IADsContainer
: IDispatch
405 [propget] HRESULT Count
(
406 [out, retval] long *retval);
407 [propget, restricted] HRESULT _NewEnum
(
408 [out, retval] IUnknown
**retval);
409 [propget] HRESULT Filter
(
410 [out, retval] VARIANT *pvFilter
);
411 [propput] HRESULT Filter
(
412 [in] VARIANT vFilter
);
413 [propget] HRESULT Hints
(
414 [out, retval] VARIANT *pvHints
);
415 [propput] HRESULT Hints
(
416 [in] VARIANT vHints
);
418 [in] BSTR bstrClassName
,
419 [in] BSTR bstrRelativeName
,
420 [out, retval] IDispatch
**ppObject
);
422 [in] BSTR bstrClassName
,
423 [in] BSTR bstrRelativeName
,
424 [out, retval] IDispatch
**ppObject
);
426 [in] BSTR bstrClassName
,
427 [in] BSTR bstrRelativeName
);
429 [in] BSTR bstrSourceName
,
430 [in] BSTR bstrNewName
,
431 [out, retval] IDispatch
**ppObject
);
433 [in] BSTR bstrSourceName
,
434 [in] BSTR bstrNewName
,
435 [out, retval] IDispatch
**ppObject
);
438 /*****************************************************************************
443 uuid(FD8256D0
-FD15
-11CE
-ABC4
-02608C9E7553
),
447 interface IADs
: IDispatch
449 [id(0x00000002), propget]
450 HRESULT Name
([out, retval] BSTR* retval);
452 [id(0x00000003), propget]
453 HRESULT Class
([out, retval] BSTR* retval);
455 [id(0x00000004), propget]
456 HRESULT GUID
([out, retval] BSTR* retval);
458 [id(0x00000005), propget]
459 HRESULT ADsPath
([out, retval] BSTR* retval);
461 [id(0x00000006), propget]
462 HRESULT Parent
([out, retval] BSTR* retval);
464 [id(0x00000007), propget]
465 HRESULT Schema
([out, retval] BSTR* retval);
474 HRESULT Get
([in] BSTR bstrName
, [out, retval] VARIANT* pvProp
);
477 HRESULT Put
([in] BSTR bstrName
, [in] VARIANT vProp
);
480 HRESULT GetEx
([in] BSTR bstrName
, [out, retval] VARIANT* pvProp
);
483 HRESULT PutEx
([in] long lnControlCode
, [in] BSTR bstrName
, [in] VARIANT vProp
);
486 HRESULT GetInfoEx
( [in] VARIANT vProperties
, [in] long lnReserved
);
489 /*****************************************************************************
490 * IADsMembers interface
494 uuid(451A0030
-72EC
-11CF
-B03B
-00AA006E0975
),
498 interface IADsMembers
: IDispatch
500 [id(0x00000002), propget]
501 HRESULT Count
([out, retval] long* plCount
);
503 [id(0xfffffffc), propget]
504 HRESULT _NewEnum
([out, retval] IUnknown
** ppEnumerator
);
506 [id(0x00000003), propget]
507 HRESULT Filter
([out, retval] VARIANT* pvFilter
);
509 [id(0x00000003), propput]
510 HRESULT Filter
([in] VARIANT pvFilter
);
513 /*****************************************************************************
514 * IADsGroup interface
518 uuid(27636B00
-410F
-11CF
-B1FF
-02608C9E7553
),
522 interface IADsGroup
: IADs
{
523 [id(0x0000000f), propget]
524 HRESULT Description
([out, retval] BSTR* retval);
526 [id(0x0000000f), propput]
527 HRESULT Description
([in] BSTR retval);
530 HRESULT Members
([out, retval] IADsMembers
** ppMembers
);
533 HRESULT IsMember
([in] BSTR bstrMember
, [out, retval] VARIANT_BOOL* bMember
);
536 HRESULT Add
([in] BSTR bstrNewItem
);
539 HRESULT Remove
([in] BSTR bstrItemToBeRemoved
);
542 /*****************************************************************************
547 uuid(3E37E320
-17E2
-11CF
-ABC4
-02608C9E7553
),
551 interface IADsUser
: IADs
553 [id(0x00000035), propget]
554 HRESULT BadLoginAddress
([out, retval] BSTR* retval);
556 [id(0x00000036), propget]
557 HRESULT BadLoginCount
([out, retval] long* retval);
559 [id(0x00000038), propget]
560 HRESULT LastLogin
([out, retval] DATE
* retval);
562 [id(0x00000039), propget]
563 HRESULT LastLogoff
([out, retval] DATE
* retval);
565 [id(0x0000003a), propget]
566 HRESULT LastFailedLogin
([out, retval] DATE
* retval);
568 [id(0x0000003b), propget]
569 HRESULT PasswordLastChanged
([out, retval] DATE
* retval);
571 [id(0x0000000f), propget]
572 HRESULT Description
([out, retval] BSTR* retval);
574 [id(0x0000000f), propput]
575 HRESULT Description
([in] BSTR retval);
577 [id(0x00000013), propget]
578 HRESULT Division
([out, retval] BSTR* retval);
580 [id(0x00000013), propput]
581 HRESULT Division
([in] BSTR retval);
583 [id(0x0000007a), propget]
584 HRESULT Department
([out, retval] BSTR* retval);
586 [id(0x0000007a), propput]
587 HRESULT Department
([in] BSTR retval);
589 [id(0x00000014), propget]
590 HRESULT EmployeeID
([out, retval] BSTR* retval);
592 [id(0x00000014), propput]
593 HRESULT EmployeeID
([in] BSTR retval);
595 [id(0x00000017), propget]
596 HRESULT FullName
([out, retval] BSTR* retval);
598 [id(0x00000017), propput]
599 HRESULT FullName
([in] BSTR retval);
601 [id(0x00000016), propget]
602 HRESULT FirstName
([out, retval] BSTR* retval);
604 [id(0x00000016), propput]
605 HRESULT FirstName
([in] BSTR retval);
607 [id(0x00000019), propget]
608 HRESULT LastName
([out, retval] BSTR* retval);
610 [id(0x00000019), propput]
611 HRESULT LastName
([in] BSTR retval);
613 [id(0x0000001b), propget]
614 HRESULT OtherName
([out, retval] BSTR* retval);
616 [id(0x0000001b), propput]
617 HRESULT OtherName
([in] BSTR retval);
619 [id(0x00000072), propget]
620 HRESULT NamePrefix
([out, retval] BSTR* retval);
622 [id(0x00000072), propput]
623 HRESULT NamePrefix
([in] BSTR retval);
625 [id(0x00000073), propget]
626 HRESULT NameSuffix
([out, retval] BSTR* retval);
628 [id(0x00000073), propput]
629 HRESULT NameSuffix
([in] BSTR retval);
631 [id(0x00000024), propget]
632 HRESULT Title
([out, retval] BSTR* retval);
634 [id(0x00000024), propput]
635 HRESULT Title
([in] BSTR retval);
637 [id(0x0000001a), propget]
638 HRESULT Manager
([out, retval] BSTR* retval);
640 [id(0x0000001a), propput]
641 HRESULT Manager
([in] BSTR retval);
643 [id(0x00000020), propget]
644 HRESULT TelephoneHome
([out, retval] VARIANT* retval);
646 [id(0x00000020), propput]
647 HRESULT TelephoneHome
([in] VARIANT retval);
649 [id(0x00000021), propget]
650 HRESULT TelephoneMobile
([out, retval] VARIANT* retval);
652 [id(0x00000021), propput]
653 HRESULT TelephoneMobile
([in] VARIANT retval);
655 [id(0x00000022), propget]
656 HRESULT TelephoneNumber
([out, retval] VARIANT* retval);
658 [id(0x00000022), propput]
659 HRESULT TelephoneNumber
([in] VARIANT retval);
661 [id(0x00000011), propget]
662 HRESULT TelephonePager
([out, retval] VARIANT* retval);
664 [id(0x00000011), propput]
665 HRESULT TelephonePager
([in] VARIANT retval);
667 [id(0x00000010), propget]
668 HRESULT FaxNumber
([out, retval] VARIANT* retval);
670 [id(0x00000010), propput]
671 HRESULT FaxNumber
([in] VARIANT retval);
673 [id(0x0000001c), propget]
674 HRESULT OfficeLocations
([out, retval] VARIANT* retval);
676 [id(0x0000001c), propput]
677 HRESULT OfficeLocations
([in] VARIANT retval);
679 [id(0x0000001e), propget]
680 HRESULT PostalAddresses
([out, retval] VARIANT* retval);
682 [id(0x0000001e), propput]
683 HRESULT PostalAddresses
([in] VARIANT retval);
685 [id(0x0000001f), propget]
686 HRESULT PostalCodes
([out, retval] VARIANT* retval);
688 [id(0x0000001f), propput]
689 HRESULT PostalCodes
([in] VARIANT retval);
691 [id(0x00000075), propget]
692 HRESULT SeeAlso
([out, retval] VARIANT* retval);
694 [id(0x00000075), propput]
695 HRESULT SeeAlso
([in] VARIANT retval);
697 [id(0x00000025), propget]
698 HRESULT AccountDisabled
([out, retval] VARIANT_BOOL* retval);
700 [id(0x00000025), propput]
701 HRESULT AccountDisabled
([in] VARIANT_BOOL retval);
703 [id(0x00000026), propget]
704 HRESULT AccountExpirationDate
([out, retval] DATE
* retval);
706 [id(0x00000026), propput]
707 HRESULT AccountExpirationDate
([in] DATE
retval);
709 [id(0x00000029), propget]
710 HRESULT GraceLoginsAllowed
([out, retval] long* retval);
712 [id(0x00000029), propput]
713 HRESULT GraceLoginsAllowed
([in] long retval);
715 [id(0x0000002a), propget]
716 HRESULT GraceLoginsRemaining
([out, retval] long* retval);
718 [id(0x0000002a), propput]
719 HRESULT GraceLoginsRemaining
([in] long retval);
721 [id(0x0000002b), propget]
722 HRESULT IsAccountLocked
([out, retval] VARIANT_BOOL* retval);
724 [id(0x0000002b), propput]
725 HRESULT IsAccountLocked
([in] VARIANT_BOOL retval);
727 [id(0x0000002d), propget]
728 HRESULT LoginHours
([out, retval] VARIANT* retval);
730 [id(0x0000002d), propput]
731 HRESULT LoginHours
([in] VARIANT retval);
733 [id(0x0000002e), propget]
734 HRESULT LoginWorkstations
([out, retval] VARIANT* retval);
736 [id(0x0000002e), propput]
737 HRESULT LoginWorkstations
([in] VARIANT retval);
739 [id(0x0000002f), propget]
740 HRESULT MaxLogins
([out, retval] long* retval);
742 [id(0x0000002f), propput]
743 HRESULT MaxLogins
([in] long retval);
745 [id(0x00000030), propget]
746 HRESULT MaxStorage
([out, retval] long* retval);
748 [id(0x00000030), propput]
749 HRESULT MaxStorage
([in] long retval);
751 [id(0x00000031), propget]
752 HRESULT PasswordExpirationDate
([out, retval] DATE
* retval);
754 [id(0x00000031), propput]
755 HRESULT PasswordExpirationDate
([in] DATE
retval);
757 [id(0x00000032), propget]
758 HRESULT PasswordMinimumLength
([out, retval] long* retval);
760 [id(0x00000032), propput]
761 HRESULT PasswordMinimumLength
([in] long retval);
763 [id(0x00000033), propget]
764 HRESULT PasswordRequired
([out, retval] VARIANT_BOOL* retval);
766 [id(0x00000033), propput]
767 HRESULT PasswordRequired
([in] VARIANT_BOOL retval);
769 [id(0x00000034), propget]
770 HRESULT RequireUniquePassword
([out, retval] VARIANT_BOOL* retval);
772 [id(0x00000034), propput]
773 HRESULT RequireUniquePassword
([in] VARIANT_BOOL retval);
775 [id(0x0000003c), propget]
776 HRESULT EmailAddress
([out, retval] BSTR* retval);
778 [id(0x0000003c), propput]
779 HRESULT EmailAddress
([in] BSTR retval);
781 [id(0x0000003d), propget]
782 HRESULT HomeDirectory
([out, retval] BSTR* retval);
784 [id(0x0000003d), propput]
785 HRESULT HomeDirectory
([in] BSTR retval);
787 [id(0x0000003e), propget]
788 HRESULT Languages
([out, retval] VARIANT* retval);
790 [id(0x0000003e), propput]
791 HRESULT Languages
([in] VARIANT retval);
793 [id(0x0000003f), propget]
794 HRESULT Profile
([out, retval] BSTR* retval);
796 [id(0x0000003f), propput]
797 HRESULT Profile
([in] BSTR retval);
799 [id(0x00000040), propget]
800 HRESULT LoginScript
([out, retval] BSTR* retval);
802 [id(0x00000040), propput]
803 HRESULT LoginScript
([in] BSTR retval);
805 [id(0x00000041), propget]
806 HRESULT Picture
([out, retval] VARIANT* retval);
808 [id(0x00000041), propput]
809 HRESULT Picture
([in] VARIANT retval);
811 [id(0x00000078), propget]
812 HRESULT HomePage
([out, retval] BSTR* retval);
814 [id(0x00000078), propput]
815 HRESULT HomePage
([in] BSTR retval);
818 HRESULT Groups
([out, retval] IADsMembers
** ppGroups
);
821 HRESULT SetPassword
([in] BSTR NewPassword
);
824 HRESULT ChangePassword
([in] BSTR bstrOldPassword
, [in] BSTR bstrNewPassword
);
827 /*****************************************************************************
828 * IDirectorySearch interface
833 uuid(109BA8EC
-92F0
-11D0
-A790
-00C04FD8D5A8
)
835 interface IDirectorySearch
: IUnknown
837 HRESULT SetSearchPreference
([in] PADS_SEARCHPREF_INFO pSearchPrefs
, [in] DWORD dwNumPrefs
);
838 HRESULT ExecuteSearch
([in] LPWSTR pszSearchFilter
, [in] LPWSTR
* pAttributeNames
,
839 [in] DWORD dwNumberAttributes
, [out] PADS_SEARCH_HANDLE phSearchResult
);
840 HRESULT AbandonSearch
([in] ADS_SEARCH_HANDLE phSearchResult
);
841 HRESULT GetFirstRow
([in] ADS_SEARCH_HANDLE hSearchResult
);
842 HRESULT GetNextRow
([in] ADS_SEARCH_HANDLE hSearchResult
);
843 HRESULT GetPreviousRow
([in] ADS_SEARCH_HANDLE hSearchResult
);
844 HRESULT GetNextColumnName
([in] ADS_SEARCH_HANDLE hSearchHandle
, [out] LPWSTR
* ppszColumnName
);
845 HRESULT GetColumn
( [in] ADS_SEARCH_HANDLE hSearchResult
, [in] LPWSTR szColumnName
,
846 [out] PADS_SEARCH_COLUMN pSearchColumn
);
847 HRESULT FreeColumn
([in] PADS_SEARCH_COLUMN pSearchColumn
);
848 HRESULT CloseSearchHandle
([in] ADS_SEARCH_HANDLE hSearchResult
);
851 /*****************************************************************************
852 * IDirectoryObject interface
857 uuid(e798de2c
-22e4
-11d0
-84fe
-00c04fd8d503
)
859 interface IDirectoryObject
: IUnknown
861 HRESULT GetObjectInformation
(PADS_OBJECT_INFO
*info
);
862 HRESULT GetObjectAttributes
(LPWSTR
*names
, DWORD count
, PADS_ATTR_INFO
*attrs
, DWORD
*count_returned
);
863 HRESULT SetObjectAttributes
(PADS_ATTR_INFO attrs
, DWORD count
, DWORD
*count_set
);
864 HRESULT CreateDSObject
(LPWSTR name
, PADS_ATTR_INFO attrs
, DWORD count
, IDispatch
**obj
);
865 HRESULT DeleteDSObject
(LPWSTR name
);
868 /*****************************************************************************
869 * IID_IADsOpenDSObject interface
873 uuid(ddf2891e
-0f9c
-11d0
-8ad4
-00c04fd8d503
),
877 interface IADsOpenDSObject
: IDispatch
879 HRESULT OpenDSObject
([in] BSTR path
, [in] BSTR user
, [in] BSTR password
, [in] long reserved
, [out,retval] IDispatch
**obj
);
882 /*****************************************************************************
883 * IADsPathname interface
887 uuid(d592aed4
-f420
-11d0
-a36e
-00c04fb950dc
),
891 interface IADsPathname
: IDispatch
893 HRESULT Set
(BSTR path
, long type
);
894 HRESULT SetDisplayType
(long type
);
895 HRESULT Retrieve
(long type
, BSTR *path
);
896 HRESULT GetNumElements
(long *count
);
897 HRESULT GetElement
(long index
, BSTR *element
);
898 HRESULT AddLeafElement
(BSTR element
);
899 HRESULT RemoveLeafElement
(void);
900 HRESULT CopyPath
(IDispatch
**path
);
901 HRESULT GetEscapedElement
(long reserved
, BSTR element
, BSTR *str
);
902 HRESULT get_EscapedMode
(long *mode
);
903 HRESULT put_EscapedMode
(long mode
);
906 /*****************************************************************************
907 * IADsADSystemInfo interface
911 uuid(5bb11929
-afd1
-11d2
-9cb9
-0000f87a369e
),
915 interface IADsADSystemInfo
: IDispatch
917 [id(0x00000002), propget]
918 HRESULT UserName
([out, retval] BSTR *retval);
919 [id(0x00000003), propget]
920 HRESULT ComputerName
([out, retval] BSTR *retval);
921 [id(0x00000004), propget]
922 HRESULT SiteName
([out, retval] BSTR *retval);
923 [id(0x00000005), propget]
924 HRESULT DomainShortName
([out, retval] BSTR *retval);
925 [id(0x00000006), propget]
926 HRESULT DomainDNSName
([out, retval] BSTR *retval);
927 [id(0x00000007), propget]
928 HRESULT ForestDNSName
([out, retval] BSTR *retval);
929 [id(0x00000008), propget]
930 HRESULT PDCRoleOwner
([out, retval] BSTR *retval);
931 [id(0x00000009), propget]
932 HRESULT SchemaRoleOwner
([out, retval] BSTR *retval);
933 [id(0x0000000a), propget]
934 HRESULT IsNativeMode
([out, retval] VARIANT_BOOL *retval);
936 HRESULT GetAnyDCName
([out, retval] BSTR *retval);
938 HRESULT GetDCSiteName
([in] BSTR server
, [out, retval] BSTR *retval);
940 HRESULT RefreshSchemaCache
();
942 HRESULT GetTrees
([out, retval] VARIANT *retval);
946 helpstring("AD System Info Object"),
947 uuid(50b6327f
-afd1
-11d2
-9cb9
-0000f87a369e
),
948 progid
("ADSystemInfo"),
953 interface IADsADSystemInfo
;