| AnyConnect Secure Mobility Client COM API 5.1.10.233

VpnApi.idl
1/**************************************************************************
2* Copyright (c) 2008, 2022 Cisco Systems, Inc.
3* All Rights Reserved. Cisco Highly Confidential.
4***************************************************************************
5*
6* File: VpnApi.idl -- interface definition of the AnyConnect
7* VPN API COM wrapper.
8* Author: Vincent E. Parla
9* Date: 07/14/2008
10*
11**************************************************************************/
12
13/** @defgroup COM_API COM API
14* This is the interface definition of the AnyConnect Secure Mobility VPN API COM wrapper.
15* Users of the COM API will #import vpnapi.dll to obtain the interface, method
16* and enumerator defintions.
17* The .idl file is included in documentation for reference purposes only.
18*
19* NOTE: This interface specification is not immutable and can be broken by future versions.
20* It is expected that your code will be recompiled / refactored to match the version
21* of client installed on the system.
22*
23* @{
24*/
25 import "oaidl.idl";
26 import "ocidl.idl";
27 import "api.h"; /*obtain the api enumerators to embed in the type library*/
28 import "VpnApiStringEnums.h"; /*obtain the string table enumerators to embed in the type library*/
29 import "RegValueUpgradeCodes.h";/*obtain the upgrade code enumerator to embed in the type library*/
30
31cpp_quote("#ifdef __cplusplus")
32cpp_quote(" using namespace VpnApiStringEnums;")
33cpp_quote("#endif //__cplusplus")
34
35 interface IVpnApiEvents; //forward declaration of the IVpnApiEvents callback interface.
36 interface IVpnStats; //forward declaration of the IVpnStats interface.
37 interface IConnectPromptInfo; //forward declaration of the IConnectPromptInfo interface.
38 interface IPromptEntry; //forward declaration of the IPromptEntry interface.
39 interface IPreferenceInfo; //forward declaration of the IPreferenceInfo interface.
40 interface IPreference; //forward declaration of the IPreference interface.
41
42 interface IStringCollection; //forward declaration of the string collection utility interface
43 interface IInterfaceCollection; //forward declaration of the interface collection utilty interface.
44
45 /**
46 * interface IVpnApi
47 * Cisco Secure Client - AnyConnect VPN API IDispatch interface specification. This is the VPN API COM Server instantiated by the user via CoCreateInstance.
48 */
49 [
50 object,
51 uuid(027E04AD-347B-4E63-9E10-00BACB3970C8),
52 oleautomation,
53 nonextensible,
54 dual,
55 helpstring("Cisco Secure Client - AnyConnect VPN API IVpnApi Interface specification. This is the VPN API COM Server instantiated by the user via CoCreateInstance."),
56 pointer_default(unique)
57 ]
58 interface IVpnApi : IDispatch
59 {
60 [id(1), helpstring("method Register. This is a convenience method for attaching one or more callback interface(s) without using the IConnectionPoint interface directly.")]
61 HRESULT Register([in] IVpnApiEvents * pVpnApiEvents, [out, retval] DWORD * pdwCookie);
62
63 [id(2), helpstring("method Unregister. This is a convenience method for detaching a callback interface without using the IConnectionPoint interface directly.")]
64 HRESULT Unregister([in] DWORD dwCookie);
65
66 [id(3), helpstring("method Attach. This is the first method that is called to configure the VPN API engine. An event callback IVpnApiEvents is assumed to be already associated, prior to calling this method. Languages like C# would use this method after wiring up the events.")]
67 HRESULT Attach([in, defaultvalue(ClientType_GUI)] enum ClientType clientType,
68 [in, defaultvalue(-1)/*true*/] VARIANT_BOOL bRequestFullCapabilities,
69 [in, defaultvalue(-1)/*true*/] VARIANT_BOOL bSuppressAutoConnect);
70
71 [id(4), helpstring("method Detach. This is the last method that is called to terminate the VPN API engine. Languages like C# would use this method after wiring up the events.")]
72 HRESULT Detach();
73
74 [id(5), helpstring("method RegisterAndAttach. This method combines Register and Attach into a single convenience method. This supports only one IVpnApiEvents instance per IVpnApi instance. Languages that handle connection points under the covers, like C#, would not use this method, but would instead simply use Attach().")]
75 HRESULT RegisterAndAttach([in] IVpnApiEvents * pVpnApiEvents,
76 [in, defaultvalue(ClientType_GUI)] enum ClientType clientType,
77 [in, defaultvalue(-1)/*true*/] VARIANT_BOOL bRequestFullCapabilities,
78 [in, defaultvalue(-1)/*true*/] VARIANT_BOOL bSuppressAutoConnect);
79
80 [id(6), helpstring("method UnregisterAndDetach. This method combines Unregister and Detach into a single convenience method. This supports only one IVpnApiEvents instance per IVpnApi instance. Languages that handle connection points under the covers, like C#, would not use this method, but would instead simply use Detach().")]
81 HRESULT UnregisterAndDetach();
82
83 [id(7), propput, helpstring("property EnableConsumerDrivenEventModel. Call this before attaching, to enable a consumer-driven event model. This enables the IVpnApiEvents::VpnEventAvailableNotification. It's required to always enable this as the old event model is deprecated.")]
84 HRESULT EnableConsumerDrivenEventModel([in] VARIANT_BOOL bEnable);
85
86 [id(8), helpstring("method ProcessEvents. Use this method if the consumer-driven event model is configured and an IVpnApiEvents::VpnEventAvailableNotification was fired.")]
87 HRESULT ProcessEvents();
88
89 [id (9), propget, helpstring("property HasFullCapabilities. Indicates whether this instance of the VPN API engine is the principal instance.")]
90 HRESULT HasFullCapabilities([out, retval] VARIANT_BOOL* pbHasFullCapabilities);
91
92 [id(10), propget, helpstring("property IsConnected. Indicates that there is a VPN connection.")]
93 HRESULT IsConnected([out, retval] VARIANT_BOOL* pbIsConnected);
94
95 [id(11), propget, helpstring("property IsVPNServiceAvailable. Indicates that the VPN Service is active. (This is also delivered to the IVpnApiEvents callback.)")]
96 HRESULT IsVPNServiceAvailable([out, retval] VARIANT_BOOL* pbIsVPNServiceAvailable);
97
98 [id(12), propget, helpstring("property HostNames. Obtains a collection of hostname strings from the profile.")]
99 HRESULT HostNames([out, retval] IStringCollection** ppIStringCollection);
100
101 [id(13), propget, helpstring("property DefaultHostName. Obtains the default hostname from the profile or the last hostname from a previous connection.")]
102 HRESULT DefaultHostName([out, retval] BSTR* pstrGetDefaultHostName);
103
104 [id(14), helpstring("method ConnectVpn. Connects to the secure gateway using a hostname or ip address.")]
105 HRESULT ConnectVpn([in] BSTR strHostNameOrAddress);
106
107 [id(15), helpstring("method DisconnectVpn. Disconnects from the secure gateway VPN session")]
108 HRESULT DisconnectVpn();
109
110 [id(16), helpstring("method GetState. Causes the VPN API engine to invoke the IVpnApiEvents::VpnStateNotification method to deliver the current state.")]
111 HRESULT GetState();
112
113 [id(17), helpstring("method ResetStats. Resets the the internal stat counters back to initial values.")]
114 HRESULT ResetStats();
115
116 [id(18), helpstring("method StartStats. Starts the automatic stats notification mechanism. This results in IVpnApiEvents::VpnStatsNotification being fired periodically.")]
117 HRESULT StartStats();
118
119 [id(19), helpstring("method StopStats. Stops the automatic stats notification mechanism.")]
120 HRESULT StopStats();
121
122 [id(20), helpstring("method UserSubmit. The caller must release the IConnectPromptInfo object, obtained from IVpnApiEvents::VpnUserPromptNotification, prior to calling this method.")]
123 HRESULT UserSubmit();
124
125 [id(21), propget, helpstring("property Preferences. Obtains a collection of IPreference interface instances.")]
126 HRESULT Preferences([out, retval] IPreferenceInfo** ppPreferenceInfo);
127
128 [id(22), helpstring("method SavePreferences. The caller must release the IPreferenceInfo object prior to calling this method.")]
129 HRESULT SavePreferences();
130
131 [id(23), propput, helpstring("property BannerResponse. Call this with the user response to the banner.")]
132 HRESULT BannerResponse([in] VARIANT_BOOL bResponse);
133
134 [id(24), propget, helpstring("property OperatingMode. Indicates if an operating mode is enabled.")]
135 HRESULT IsOperatingMode([in] enum OperatingMode eOperatingMode, [out, retval] VARIANT_BOOL* pbIsEnabled);
136
137 [id(25), helpstring("method GetStats. Causes the VPN API engine to invoke the IVpnApiEvents::VpnStatsNotification method to deliver the current stats.")]
138 HRESULT GetStats();
139
140 [id(26), propget, helpstring("property LastVpnError. Indicates the last error seen while establishing VPN.")]
141 HRESULT LastVpnError([out, retval] enum VPNError* peLastVpnError);
142
143 [id(27), propput, helpstring("property CertBlockedResponse. Call this with the user response to the CertBlockedCB.")]
144 HRESULT CertBlockedResponse([in] VARIANT_BOOL bUnblock);
145
146 [id(28), propput, helpstring("property CertWarningResponse. Call this with the user response to the CertWarningCB.")]
147 HRESULT CertWarningResponse([in] VARIANT_BOOL bConnect, [in] VARIANT_BOOL bImport);
148
149 [id(29), propput, helpstring("property PreConnectReminderResponse. Call this with the user response to the pre-connect reminder.")]
150 HRESULT PreConnectReminderResponse([in] VARIANT_BOOL bResponse);
151
152 [id(99), propget, helpstring("property VpnStatsTranslatedLabel. Allows for pre-fetching translated labels for various VPN statistics prior to obtaining an IVpnStats interface")]
153 HRESULT VpnStatsTranslatedLabel([in] enum VPNStatsTag eVPNStatsTag, [out, retval] BSTR* pstrTranslatedLabel);
154
155
156 //methods used to obtain the registry key and value to query to determine when a vpn software upgrade is completed.
157 //
158 [id(998), propget, helpstring("property UpgradeRegistryKeyName. returns the name of the registry key to monitor for core software upgrade completions.")]
159 HRESULT UpgradeRegistryKeyName([out, retval] BSTR* pstrUpgradeRegistryKeyName);
160 [id(999), propget, helpstring("property UpgradeRegistryValueName. returns the name of the registry value to query for core software upgrade completions when the key change is notified.")]
161 HRESULT UpgradeRegistryValueName([out, retval] BSTR* pstrUpgradeRegistryValueName);
162 };
163
164 /**
165 * interface IVpnApiEvents
166 * Cisco Secure Client - AnyConnect VPN API Event Callback IDispatch interface specification. This is the VPN API COM Event Callback interface that a developer implements and passes to the COM Server using the Attach, RegisterAndAttach, or indirectly via connection points in languages such as C#.
167 */
168 [
169 object,
170 uuid(5D446DC1-A494-4D3D-B5AD-0ADACB3B3EE3),
171 oleautomation,
172 nonextensible,
173 dual,
174 helpstring("Cisco Secure Client - AnyConnect VPN API IVpnApiEvents callback Interface specification. A user of the VpnApi COM Server provides this interface to receive event notifications."),
175 pointer_default(unique)
176 ]
177 interface IVpnApiEvents : IDispatch
178 {
179 [id(1000), helpstring("method VpnStatsNotification. Callback containing a IVpnStats object to be queried for stats.")]
180 HRESULT VpnStatsNotification([in] IVpnStats * pVpnStats);
181
182 [id(1001), helpstring("method VpnStateNotification. Callback containing the state of the VPN session")]
183 HRESULT VpnStateNotification([in] enum VPNState eState, [in] enum VPNSubState eSubState, [in] BSTR strState);
184
185 [id(1002), helpstring("method VpnBannerNotification. Callback containing a Banner notification string.")]
186 HRESULT VpnBannerNotification([in] BSTR strBannerMessage);
187
188 [id(1003), helpstring("method VpnStateNotification. Callback containing a notice pertaining to the VPN session")]
189 HRESULT VpnNoticeNotification([in] BSTR strNoticeMessage, [in] enum MessageType eMessageType);
190
191 [id(1004), helpstring("method VpnExitNotification. Callback containing a notice indicating to shutdown the VPN API release to COM component.")]
192 HRESULT VpnExitNotification([in] BSTR strExitMessage, [in] long exitCode);
193
194 [id(1005), helpstring("method VpnServiceReadyNotification. Callback indicating the VPN Service is online")] /*this could be a prop_put*/
195 HRESULT VpnServiceReadyNotification();
196
197 [id(1006), helpstring("method VpnUserPromptNotification. Callback indicating the VPN Service is online")] /*this could be a prop_put*/
198 HRESULT VpnUserPromptNotification([in] IConnectPromptInfo * pConnectPromptInfo);
199
200 [id(1007), helpstring("method VpnWMHintNotification. Callback containing UI behavior hint and reason.")]
201 HRESULT VpnWMHintNotification([in] enum WMHint eHint, [in] enum WMHintReason eReason);
202
203 [id(1008), helpstring("method VpnWebLaunchHostNotification. Callback containing the Active Host pertaining to the VPN session")]
204 HRESULT VpnWebLaunchHostNotification([in] BSTR strActiveHost);
205
206 [id(1009), helpstring("method VpnEventAvailableNotification. Callback indicating an API Event is available to consume. This notification is sent only if configured to use the consumer-driven event model. A COM user then calls IVpnApi::ProcessEvents.")]/*this could be a prop_put*/
207 HRESULT VpnEventAvailableNotification();
208
209 [id(1010), helpstring("method VpnCertBlockedNotification. Callback indicating strUntrustedServer is an untrusted server.")]
210 HRESULT VpnCertBlockedNotification([in] BSTR strUntrustedServer);
211
212 [id(1011), helpstring("method VpnCertWarningNotification. Callback indicating strUntrustedServer is an untrusted server because of the certificate errors in pCertErrors.")]
213 HRESULT VpnCertWarningNotification([in] BSTR strUntrustedServer, [in] IStringCollection *pCertErrors, [in] VARIANT_BOOL bImportAllowed);
214
215 [id(1012), helpstring("method VpnPreConnectReminderNotification. Callback containing a pre-connect reminder notification string.")]
216 HRESULT VpnPreConnectReminderNotification([in] BSTR strPreConnectReminderMessage);
217 };
218
219 /**
220 * interface IVpnStats
221 * Cisco Secure Client - AnyConnect VPN API Statistics IDispatch interface specification. This is a non-creatable interface that is passed to via an Event Callback method and represents a VPN Statistics object.
222 */
223 [
224 object,
225 uuid(42B1B1F3-5E1E-4d5d-9C59-2E484C726CE6),
226 oleautomation,
227 nonextensible,
228 dual,
229 helpstring("Cisco Secure Client - AnyConnect VPN API IVpnStats Interface specification."),
230 pointer_default(unique)
231 ]
232 interface IVpnStats : IDispatch
233 {
234 [id(100), propget, helpstring("property SecureRoutes. Obtains a collection of IRouteInfo interface instances.")]
235 HRESULT SecureRoutes([out, retval] IInterfaceCollection** ppSecureRouteInfoCollection);
236
237 [id(101), propget, helpstring("property NonsecureRoutes. Obtains a collection of IRouteInfo interface instances.")]
238 HRESULT NonsecureRoutes([out, retval] IInterfaceCollection** ppNonsecureRouteInfoCollection);
239
240 [id(102), propget, helpstring("property ProtocolInfo. Obtains a collection of IProtocolInfo interface instances.")]
241 HRESULT ProtocolInfo([out, retval] IInterfaceCollection** ppProtocolInfoCollection);
242
243 [id(103), propget, helpstring("property FirewallInfo. Obtains a collection of IFirewallInfo interface instances.")]
244 HRESULT FirewallInfo([out, retval] IInterfaceCollection** ppFirewallInfoCollection);
245
246 [id(DISPID_VALUE), propget, helpstring("property StatValue. Obtains the value for various VPN statistics associated IVpnStats interface. (NOTE: This is functionally the same as GetVpnStatsTranslatedLabel.)")]
247 HRESULT StatValue([in] enum VPNStatsTag eVPNStatsTag, [out,retval] BSTR* pstrStatValue);
248
249 [id(104), propget, helpstring("property TranslatedLabel. Obtains the translated labels for various VPN statistics associated IVpnStats interface. (NOTE: This is functionally the same as GetVpnStatsTranslatedLabel.)")]
250 HRESULT TranslatedLabel([in] enum VPNStatsTag eVPNStatsTag, [out,retval] BSTR* pstrTranslatedLabel);
251 };
252
253 /**
254 * interface IConnectPromptInfo
255 * Cisco Secure Client - AnyConnect VPN API Connection Prompt IDispatch interface specification. This is a non-creatable interface that is passed to via an Event Callback method and represents a VPN Connect Prompt Information object.
256 */
257 [
258 object,
259 uuid(811A60FE-D3E0-4fe6-B627-30723A93554C),
260 oleautomation,
261 nonextensible,
262 dual,
263 helpstring("Cisco Secure Client - AnyConnect VPN API IConnectPromptInfo Interface specification."),
264 pointer_default(unique)
265 ]
266 interface IConnectPromptInfo : IDispatch
267 {
268 [id(200), propget, helpstring("property ConnectPromptType. The type of prompt entry.")]
269 HRESULT ConnectPromptType([out, retval] enum ConnectPromptType* peConnectPromptType);
270
271 [id(201), propget, helpstring("property CountPromptEntry. The number of prompt entries in the collection.")]
272 HRESULT CountPromptEntry([out, retval] unsigned long* pulEntryCount);
273
274 [id(202), propget, helpstring("property Message. Provides a message associated with the credentials being entered.")]
275 HRESULT Message([out, retval] BSTR* pMessage);
276
277 [id(203), propget, helpstring("property PromptNames. Obtains a collection of prompt name strings if available.")]
278 HRESULT PromptNames([out, retval] IStringCollection** ppPromptNamesCollection);
279
280 [id(DISPID_VALUE), propget, helpstring("property PromptEntry. Obtains a prompt entry based on a tag value provided.")]
281 HRESULT PromptEntry([in] BSTR strPromptName, [out, retval] IPromptEntry ** ppPromptEntry);
282
283 [id(205), propget, helpstring("property PromptEntries. Obtains a collection of prompt entries.")]
284 HRESULT PromptEntries([out, retval] IInterfaceCollection** ppPromptEntriesCollection);
285
286 [id(206), propget, helpstring("property HasAuthenticationError. Indicates whether an authentication error has occurred.")]
287 HRESULT HasAuthenticationError([out, retval] VARIANT_BOOL* pbAuthErr);
288
289 [id(207), propget, helpstring("property SubmitButtonName. Provides the name to be used for the Submit Button.")]
290 HRESULT SubmitButtonName([out, retval] BSTR* pstrSubmitButton);
291
292 [id(208), propget, helpstring("property HasEnrollmentCA. Indicates an Enrollment CA is available.")]
293 HRESULT HasEnrollmentCA([out, retval] VARIANT_BOOL* pbCAAvailable);
294
295 [id(209), propput, helpstring("property UseEnrollmentCA. Inform the VPN API to use the Enrollement CA.")]
296 HRESULT UseEnrollmentCA([in] VARIANT_BOOL bUseCA);
297
298 [id(210), propput, helpstring("property TunnelGroup. Allows the setting of the currently selected Tunnel group")]
299 HRESULT TunnelGroup([in] BSTR strSelectedTunnelGroup);
300
301 [id(211), propget, helpstring("property IsCanceled. Indicates if the user has canceled the prompt.")]
302 HRESULT IsCanceled([out, retval] VARIANT_BOOL* pbIsCanceled);
303
304 [id(212), propput, helpstring("property Canceled. Inform the VPNAPI that the user has canceled the prompt.")]
305 HRESULT Canceled([in] VARIANT_BOOL bIsCanceled);
306 };
307
308 /**
309 * interface IVpnStats
310 * Cisco Secure Client - AnyConnect VPN API Prompt Entry IDispatch interface specification. This is a non-creatable interface that is contains Prompt Entry information.
311 */
312 [
313 object,
314 uuid(548A1F06-AECE-4506-8ABB-5E3D3A99B67B),
315 oleautomation,
316 nonextensible,
317 dual,
318 helpstring("Cisco Secure Client - AnyConnect VPN API IPromptEntry Interface specification."),
319 pointer_default(unique)
320 ]
321 interface IPromptEntry : IDispatch
322 {
323 [id(301), propget, helpstring("property Value. Gets the current value for the prompt entry.")]
324 HRESULT Value([out, retval] BSTR* pstrValue);
325
326 [id(301), propput, helpstring("property Value. Sets a value explicitly for a prompt entry.")]
327 HRESULT Value([in] BSTR strValue);
328
329 [id(302), propget, helpstring("property PromptName. This is the non-translated prompt.")]
330 HRESULT PromptName([out, retval] BSTR* pstrPromptName);
331
332 [id(303), propget, helpstring("property PromptLabel. This is the translated prompt.")]
333 HRESULT PromptLabel([out, retval] BSTR* pstrPromptLabel);
334
335 [id(304), propget, helpstring("property PromptType. Obtains the type of prompt (for example, password), etc.")]
336 HRESULT PromptType([out, retval] enum PromptType* pPromptType);
337
338 [id(305), propget, helpstring("property IsEnabled. Indicates whether this should be user editable.")]
339 HRESULT IsEnabled([out, retval] VARIANT_BOOL* pbIsEnabled);
340
341 [id(306), propget, helpstring("property IsVisible. Indicates whether this should be displayed to the user.")]
342 HRESULT IsVisible([out, retval] VARIANT_BOOL* pbIsVisible);
343
344 [id(307), propget, helpstring("property ValueOptions. Obtains a collection of value option strings.")]
345 HRESULT ValueOptions([out, retval] IStringCollection** ppValueOptionsCollection);
346
347 [id(308), propget, helpstring("property IsEntryGroup")]
348 HRESULT IsEntryGroup([out, retval] VARIANT_BOOL* pbIsEntryGroup);
349 };
350
351 /**
352 * interface IRouteInfo
353 * Cisco Secure Client - AnyConnect VPN API Route Information IDispatch interface specification. This is a non-creatable interface that represents a Route Information object.
354 */
355 [
356 object,
357 uuid(02E2AE5E-A8C8-458e-92B0-B72B322B623C),
358 oleautomation,
359 nonextensible,
360 dual,
361 helpstring("Cisco Secure Client - AnyConnect VPN API IRouteInfo Interface specification."),
362 pointer_default(unique)
363 ]
364 interface IRouteInfo : IDispatch
365 {
366 [id(401), propget, helpstring("property Network route")]
367 HRESULT Network([out, retval] BSTR* pstrNetwork);
368
369 [id(402), propget, helpstring("property Subnet for the route.")]
370 HRESULT Subnet([out, retval] BSTR* pstrSubnet);
371 };
372
373 /**
374 * interface IProtocolInfo
375 * Cisco Secure Client - AnyConnect VPN API Protocol Information IDispatch interface specification. This is a non-creatable interface that represents a Protocol Information object.
376 */
377 [
378 object,
379 uuid(A0D63CA4-68E6-44e8-8738-19D6E4BC82BE),
380 oleautomation,
381 nonextensible,
382 dual,
383 helpstring("Cisco Secure Client - AnyConnect VPN API IProtocolInfo Interface specification."),
384 pointer_default(unique)
385 ]
386 interface IProtocolInfo : IDispatch
387 {
388 [id(501), propget, helpstring("property ProtocolLabel. Obtain a protocol label string from the enumerated type.")]
389 HRESULT ProtocolLabel([in] enum ProtocolInfoTag eProtocolInfoTag,
390 [out, retval] BSTR* pstrProtocolLabel);
391
392 [id(DISPID_VALUE), propget, helpstring("property ProtocolValue. Obtain a protocol value string from the enumerated type.")]
393 HRESULT ProtocolValue([in] enum ProtocolInfoTag eProtocolInfoTag,
394 [out, retval] BSTR* pstrProtocolValue);
395
396 [id(503), propget, helpstring("property IsActive. Indicates if the protocol is active.")]
397 HRESULT IsActive([out, retval] VARIANT_BOOL * pbIsActive);
398 };
399
400 /**
401 * interface IFirewallInfo
402 * Cisco Secure Client - AnyConnect VPN API Firewall Information IDispatch interface specification. This is a non-creatable interface that represents a Firweall Information object containing firewall rule information.
403 */
404 [
405 object,
406 uuid(F71DC93F-C07D-44a3-95B4-864177AE0F7E),
407 oleautomation,
408 nonextensible,
409 dual,
410 helpstring("Cisco Secure Client - AnyConnect VPN API IFirewallInfo Interface specification."),
411 pointer_default(unique)
412 ]
413 interface IFirewallInfo : IDispatch
414 {
415 [id(541), propget, helpstring("property Permission of a firewall rule")]
416 HRESULT Permission([out, retval] BSTR* pstrPermission);
417
418 [id(542), propget, helpstring("property Protocol for a firewall rule.")]
419 HRESULT Protocol([out, retval] BSTR* pstrProtocol);
420
421 [id(543), propget, helpstring("property Interface for a firewall rule.")]
422 HRESULT Interface([out, retval] BSTR* pstrInterface);
423
424 [id(544), propget, helpstring("property Source Port Range for a firewall rule.")]
425 HRESULT SrcPortRange([out, retval] BSTR* pstrSrcPortRange);
426
427 [id(545), propget, helpstring("property Destination Port Range for a firewall rule.")]
428 HRESULT DstPortRange([out, retval] BSTR* pstrDstPortRange);
429
430 [id(546), propget, helpstring("property Destination Address for a firewall rule.")]
431 HRESULT DstAddr([out, retval] BSTR* pstrDstAddr);
432 };
433
434
435 /**
436 * interface IPreferenceInfo
437 * Cisco Secure Client - AnyConnect VPN API User Preference Information IDispatch interface specification. This is a non-creatable interface that represents a User Preference Information object.
438 */
439 [
440 object,
441 uuid(3E73BCCD-C4E4-4842-AB58-9F973E7D226F),
442 oleautomation,
443 nonextensible,
444 dual,
445 helpstring("Cisco Secure Client - AnyConnect VPN API IPreferenceInfo Interface specification."),
446 pointer_default(unique)
447 ]
448 interface IPreferenceInfo : IDispatch
449 {
450 [id(601), propget, helpstring("property CountPreferences. The number of preferences available.")]
451 HRESULT CountPreferences([out, retval] unsigned long * pulCountPreferences);
452
453 [id(DISPID_VALUE), propget, helpstring("property Preference. Gets the instance of an IPreference interface associated with the preference tag.")]
454 HRESULT Preference([in] enum PreferenceId ePreferenceId, [out, retval] IPreference** ppPreference);
455
456 [id(603), propget, helpstring("property Preferences. Obtains a collection of IPreference interface instances.")]
457 HRESULT Preferences([out, retval] IInterfaceCollection** ppPreferencesCollection);
458
459 [id(604), propget, helpstring("property PreferenceHeading. The heading string for preferences.")]
460 HRESULT PreferenceHeading([out, retval] BSTR * pstrPreferenceHeading);
461 };
462
463 /**
464 * interface IPreference
465 * Cisco Secure Client - AnyConnect VPN API Usser Preference IDispatch interface specification. This is a non-creatable interface that represents a User Preference object.
466 */
467 [
468 object,
469 uuid(01F3D78C-AC49-48d1-8782-0EB481961341),
470 oleautomation,
471 nonextensible,
472 dual,
473 helpstring("Cisco Secure Client - AnyConnect VPN API IPreference Interface specification."),
474 pointer_default(unique)
475 ]
476 interface IPreference : IDispatch
477 {
478 [id(701), propget, helpstring("property PreferenceValue. Gets the current value for the preference entry.")]
479 HRESULT PreferenceValue([out, retval] BSTR* pstrPreferenceValue);
480
481 [id(701), propput, helpstring("property PreferenceValue. Sets the value explicitly for a preference entry.")]
482 HRESULT PreferenceValue([in] BSTR strPreferenceValue);
483
484 [id(703), propget, helpstring("property PreferenceId. Gets the preference identifier enumeration value for the preference entry.")]
485 HRESULT PreferenceId([out, retval] enum PreferenceId * pPreferenceId);
486
487 [id(704), propget, helpstring("property Children. Obtains a collection of IPreference interface instances that are sub-entries of this preference.")]
488 HRESULT Children([out, retval] IInterfaceCollection** ppChildPreferencesCollection);
489
490 [id(705), propget, helpstring("property PromptEntry. Obtains a prompt entry instance associated with this preference.")]
491 HRESULT PromptEntry([out, retval] IPromptEntry ** ppPromptEntry);
492 };
493
494
495 //Collection interfaces//
496
497 /**
498 * interface IStringCollection
499 * Cisco Secure Client - AnyConnect VPN API String Collection IDispatch interface specification. This is a non-creatable interface that represents a Collection of Strings.
500 */
501 [
502 object,
503 uuid(6292ECAC-42CD-43ea-A96C-0C072772B4BE),
504 oleautomation,
505 nonextensible,
506 dual,
507 helpstring("Cisco Secure Client - AnyConnect VPN API Utility String Collection Interface specification."),
508 pointer_default(unique)
509 ]
510 interface IStringCollection : IDispatch
511 {
512 [id(DISPID_NEWENUM), propget, helpstring("method _NewEnum. Obtains a new String Collection enumerator interface.")]
513 HRESULT _NewEnum([out, retval] IUnknown** ppUnk);
514
515 [id(DISPID_VALUE), propget, helpstring("property Item. Obtains a string object in the collection. NOTE: collections are 1's based indexing.")]
516 HRESULT Item([in] long nIndex, [out, retval] BSTR* pString);
517
518 [id(1), propget, helpstring("property Count. Obtains the count of the number of objects in the collection.")]
519 HRESULT Count([out, retval] long * pCount);
520 };
521
522 /**
523 * interface IStringCollection
524 * Cisco Secure Client - AnyConnect VPN API Interface Collection IDispatch interface specification. This is a non-creatable interface that represents a Collection of Interface instances of objects.
525 */
526 [
527 object,
528 uuid(E0854B5E-16D3-46b5-8767-420EB1F48041),
529 oleautomation,
530 nonextensible,
531 dual,
532 helpstring("Cisco Secure Client - AnyConnect VPN API Utility IUnknown Collection Interface specification."),
533 pointer_default(unique)
534 ]
535 interface IInterfaceCollection : IDispatch
536 {
537 [id(DISPID_NEWENUM), propget, helpstring("property _NewEnum. Obtains a new Interface Collection enumerator interface.")]
538 HRESULT _NewEnum([out, retval] IUnknown** ppUnk);
539
540 [id(DISPID_VALUE), propget, helpstring("property Item. Obtains an IUnknown interface for an object in the collection. The user would then QI for the actual interface they wanted to obtain. NOTE: collections are 1's based indexing.")]
541 HRESULT Item([in] long nIndex, [out, retval] IUnknown** ppInterface);
542
543 [id(1), propget, helpstring("property Count. Obtains the count of the number of objects in the collection.")]
544 HRESULT Count([out, retval] long * pCount);
545 };
546
547/////////////////////////////////////// VPN API Type Library //////////////////////////////////////
548[
549 uuid(C15C09AE-FCCE-9221-FFA2-7465FEAAE55A),
550 version(1.0),
551 helpstring("Cisco Secure Client - AnyConnect VPN API 1.0 Type Library")
552]
553library VpnApiLib
554{
555 importlib("stdole32.tlb");
556 importlib("stdole2.tlb");
557
558 [
559 uuid(C15C0F4F-DDFB-4591-AD53-C9A71C9C15C0),
560 helpstring("VpnApi Class")
561 ]
562 coclass VpnApi
563 {
564 [default] interface IVpnApi;
565 [default, source] dispinterface IVpnApiEvents;
566 };
567
568 interface IRouteInfo;
569 interface IProtocolInfo;
570 interface IFirewallInfo;
571 enum RegValueUpgradeCodesTag;
572}
573
574/** @} */
IDispatch
VpnApiLib::VpnApi
Definition VpnApi.idl:563
IConnectPromptInfo
Definition VpnApi.idl:267
IFirewallInfo
Definition VpnApi.idl:414
IInterfaceCollection
Definition VpnApi.idl:536
IPreference
Definition VpnApi.idl:477
IPreferenceInfo
Definition VpnApi.idl:449
IPromptEntry
Definition VpnApi.idl:322
IProtocolInfo
Definition VpnApi.idl:387
IRouteInfo
Definition VpnApi.idl:365
IStringCollection
Definition VpnApi.idl:511
IVpnApiEvents
Definition VpnApi.idl:178
IVpnApi
Definition VpnApi.idl:59
IVpnStats
Definition VpnApi.idl:233