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 /** 27 * \file KMSAgentSoapUtilities.h 28 */ 29 30 #ifndef KMSAgentSoapUtilities_h 31 #define KMSAgentSoapUtilities_h 32 33 /** 34 * maximum length of a network IP address 35 */ 36 static const int g_iMAX_PEER_NETWORK_ADDRESS_LENGTH = 50; 37 38 /** 39 * maximum length of a soap fault message string 40 */ 41 static const int g_iMAX_SOAP_FAULT_MESSAGE_LENGTH = 256; 42 43 //BEN CHANGE - removed predeclaration of struct soap 44 // need the real declaration 45 //struct soap; 46 47 /** 48 * copies at most g_iMAX_PEER_NETWORK_ADDRESS_LENGTH characters 49 * from the peer's network address from the soap runtime context. 50 * <code>o_psPeerNetworkAddress</code> should be at least 51 * <code>g_iMAX_PEER_NETWORK_ADDRESS_LENGTH</code> in length. 52 */ 53 void GetPeerNetworkAddress( char* const o_psPeerNetworkAddress, 54 struct soap* i_pSoap ); 55 56 /** 57 * creates a soap fault message and stores it in o_psFaultMessage. The fault message 58 * has the form: " SoapFaultCode=%s SoapFaultString=%s SoapFaultDetail=%s" with the 59 * appropriate values substitued for %s from the soap runtime. 60 * @param o_psFaultMessage a buffer for the fault message that is at least 61 * <code>g_iMAX_SOAP_FAULT_MESSAGE_LENGTH</code> in size. 62 * @param i_pstSoap the soap runtime context to process for fault information 63 */ 64 // BEN - removed const 65 void GetSoapFault(char* o_psFaultMessage, 66 struct soap *i_pstSoap); 67 68 bool PutBinaryIntoSoapBinary( 69 struct soap* i_pSoap, 70 const unsigned char* i_pBinary, 71 int i_iBinarySize, 72 unsigned char*& o_pSoapBinary, 73 int& o_iSoapBinarySize ); 74 75 #endif //KMSAgentSoapUtilities_h 76