1 /*
2 * CDDL HEADER START
3 *
4 * The contents of this file are subject to the terms of the
5 * Common Development and Distribution License (the "License").
6 * You may not use this file except in compliance with the License.
7 *
8 * You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
9 * or http://www.opensolaris.org/os/licensing.
10 * See the License for the specific language governing permissions
11 * and limitations under the License.
12 *
13 * When distributing Covered Code, include this CDDL HEADER in each
14 * file and include the License file at usr/src/OPENSOLARIS.LICENSE.
15 * If applicable, add the following below this CDDL HEADER, with the
16 * fields enclosed by brackets "[]" replaced with your own identifying
17 * information: Portions Copyright [yyyy] [name of copyright owner]
18 *
19 * CDDL HEADER END
20 */
21
22 /*
23 * Copyright (c) 2010, Oracle and/or its affiliates. All rights reserved.
24 */
25
26 /* KMS_CAClient.cpp
27 Generated by gSOAP 2.7.17 from ../gsoapStubs/CAService/KMS_CA_SOAP.h
28 Copyright(C) 2000-2010, Robert van Engelen, Genivia Inc. All Rights Reserved.
29 This part of the software is released under one of the following licenses:
30 GPL, the gSOAP public license, or Genivia's license for commercial use.
31 */
32
33 #if defined(__BORLANDC__)
34 #pragma option push -w-8060
35 #pragma option push -w-8004
36 #endif
37 #include "KMS_CAH.h"
38
39 namespace KMS_CA {
40
41 SOAP_SOURCE_STAMP("@(#) KMS_CAClient.cpp ver 2.7.17 2010-06-08 19:16:38 GMT")
42
43
soap_call_KMS_CA__RetrieveRootCACertificate(struct soap * soap,const char * soap_endpoint,const char * soap_action,char * EntityID,struct KMS_CA__RetrieveRootCACertificateResponse & result)44 SOAP_FMAC5 int SOAP_FMAC6 soap_call_KMS_CA__RetrieveRootCACertificate(struct soap *soap, const char *soap_endpoint, const char *soap_action, char *EntityID, struct KMS_CA__RetrieveRootCACertificateResponse &result)
45 { struct KMS_CA__RetrieveRootCACertificate soap_tmp_KMS_CA__RetrieveRootCACertificate;
46 soap_tmp_KMS_CA__RetrieveRootCACertificate.EntityID = EntityID;
47 soap_begin(soap);
48 soap_serializeheader(soap);
49 soap_serialize_KMS_CA__RetrieveRootCACertificate(soap, &soap_tmp_KMS_CA__RetrieveRootCACertificate);
50 if (soap_begin_count(soap))
51 return soap->error;
52 if (soap->mode & SOAP_IO_LENGTH)
53 { if (soap_envelope_begin_out(soap)
54 || soap_putheader(soap)
55 || soap_body_begin_out(soap)
56 || soap_put_KMS_CA__RetrieveRootCACertificate(soap, &soap_tmp_KMS_CA__RetrieveRootCACertificate, "KMS-CA:RetrieveRootCACertificate", NULL)
57 || soap_body_end_out(soap)
58 || soap_envelope_end_out(soap))
59 return soap->error;
60 }
61 if (soap_end_count(soap))
62 return soap->error;
63 if (soap_connect(soap, soap_endpoint, soap_action)
64 || soap_envelope_begin_out(soap)
65 || soap_putheader(soap)
66 || soap_body_begin_out(soap)
67 || soap_put_KMS_CA__RetrieveRootCACertificate(soap, &soap_tmp_KMS_CA__RetrieveRootCACertificate, "KMS-CA:RetrieveRootCACertificate", NULL)
68 || soap_body_end_out(soap)
69 || soap_envelope_end_out(soap)
70 || soap_end_send(soap))
71 return soap_closesock(soap);
72 if (!&result)
73 return soap_closesock(soap);
74 soap_default_KMS_CA__RetrieveRootCACertificateResponse(soap, &result);
75 if (soap_begin_recv(soap)
76 || soap_envelope_begin_in(soap)
77 || soap_recv_header(soap)
78 || soap_body_begin_in(soap))
79 return soap_closesock(soap);
80 if (soap_recv_fault(soap, 1))
81 return soap->error;
82 soap_get_KMS_CA__RetrieveRootCACertificateResponse(soap, &result, "", "");
83 if (soap->error)
84 return soap_recv_fault(soap, 0);
85 if (soap_body_end_in(soap)
86 || soap_envelope_end_in(soap)
87 || soap_end_recv(soap))
88 return soap_closesock(soap);
89 return soap_closesock(soap);
90 }
91
soap_call_KMS_CA__RetrieveLocalClock(struct soap * soap,const char * soap_endpoint,const char * soap_action,char * EntityID,struct KMS_CA__RetrieveLocalClockResponse & result)92 SOAP_FMAC5 int SOAP_FMAC6 soap_call_KMS_CA__RetrieveLocalClock(struct soap *soap, const char *soap_endpoint, const char *soap_action, char *EntityID, struct KMS_CA__RetrieveLocalClockResponse &result)
93 { struct KMS_CA__RetrieveLocalClock soap_tmp_KMS_CA__RetrieveLocalClock;
94 soap_tmp_KMS_CA__RetrieveLocalClock.EntityID = EntityID;
95 soap_begin(soap);
96 soap_serializeheader(soap);
97 soap_serialize_KMS_CA__RetrieveLocalClock(soap, &soap_tmp_KMS_CA__RetrieveLocalClock);
98 if (soap_begin_count(soap))
99 return soap->error;
100 if (soap->mode & SOAP_IO_LENGTH)
101 { if (soap_envelope_begin_out(soap)
102 || soap_putheader(soap)
103 || soap_body_begin_out(soap)
104 || soap_put_KMS_CA__RetrieveLocalClock(soap, &soap_tmp_KMS_CA__RetrieveLocalClock, "KMS-CA:RetrieveLocalClock", NULL)
105 || soap_body_end_out(soap)
106 || soap_envelope_end_out(soap))
107 return soap->error;
108 }
109 if (soap_end_count(soap))
110 return soap->error;
111 if (soap_connect(soap, soap_endpoint, soap_action)
112 || soap_envelope_begin_out(soap)
113 || soap_putheader(soap)
114 || soap_body_begin_out(soap)
115 || soap_put_KMS_CA__RetrieveLocalClock(soap, &soap_tmp_KMS_CA__RetrieveLocalClock, "KMS-CA:RetrieveLocalClock", NULL)
116 || soap_body_end_out(soap)
117 || soap_envelope_end_out(soap)
118 || soap_end_send(soap))
119 return soap_closesock(soap);
120 if (!&result)
121 return soap_closesock(soap);
122 soap_default_KMS_CA__RetrieveLocalClockResponse(soap, &result);
123 if (soap_begin_recv(soap)
124 || soap_envelope_begin_in(soap)
125 || soap_recv_header(soap)
126 || soap_body_begin_in(soap))
127 return soap_closesock(soap);
128 if (soap_recv_fault(soap, 1))
129 return soap->error;
130 soap_get_KMS_CA__RetrieveLocalClockResponse(soap, &result, "", "");
131 if (soap->error)
132 return soap_recv_fault(soap, 0);
133 if (soap_body_end_in(soap)
134 || soap_envelope_end_in(soap)
135 || soap_end_recv(soap))
136 return soap_closesock(soap);
137 return soap_closesock(soap);
138 }
139
140 } // namespace KMS_CA
141
142
143 #if defined(__BORLANDC__)
144 #pragma option pop
145 #pragma option pop
146 #endif
147
148 /* End of KMS_CAClient.cpp */
149