1 /*---------------------------------------------------------------------------*
2   Project:  Horizon
3   File:     http_ClientCert.h
4   Copyright (C)2010 Nintendo Co., Ltd.  All rights reserved.
5   These coded instructions, statements, and computer programs contain
6   proprietary information of Nintendo of America Inc. and/or Nintendo
7   Company Ltd., and are protected by Federal copyright law. They may
8   not be disclosed to third parties or copied or duplicated in any form,
9   in whole or in part, without the prior written consent of Nintendo.
10   $Rev: 31762 $
11  *---------------------------------------------------------------------------
12 
13 
14 */
15 
16 #ifndef NN_HTTP_HTTP_CLIENTCERT_H_
17 #define NN_HTTP_HTTP_CLIENTCERT_H_
18 
19 #include <nn/util/util_NonCopyable.h>
20 #include <nn/http/http_Types.h>
21 
22 #ifdef __cplusplus
23 
24 namespace nn {
25 namespace http {
26 
27 class Connection;
28 
29 /* Please see man pages for details
30 
31 
32 */
33 class ClientCert : private nn::util::NonCopyable<ClientCert>
34 {
35     friend class Connection;
36 public:
37     /* Please see man pages for details
38 
39     */
40     explicit ClientCert();
41 
42     /* Please see man pages for details
43 
44     */
45     virtual ~ClientCert (void);
46 
47     /* Please see man pages for details
48 
49 
50 
51 
52 
53 
54 
55 
56 
57 
58     */
59     nn::Result Initialize(const u8* pCertData, size_t certDataSize, const u8* pPrivateKeyData, size_t privateKeyDataSize);
60 
61     /* Please see man pages for details
62 
63 
64 
65 
66 
67 
68 
69     */
70     nn::Result Initialize(InternalClientCertId inClientCertName );
71 
72 
73     /* Please see man pages for details
74 
75 
76 
77 
78 
79     */
80     nn::Result Finalize(void);
81 
82 private:
83     bool m_isInitialized;
84     NN_PADDING3;
85     CertId m_certId;
86 
87     /* Please see man pages for details
88 
89 
90     */
IsValid()91     bool IsValid(){return m_isInitialized;}
92 };
93 
94 } // end of namespace http
95 } // end of namespace nn
96 
97 #endif // __cplusplus
98 
99 
100 #include <nn/util/detail/util_CLibImpl.h>
101 
102 
103 /* Please see man pages for details
104 
105 
106 
107 
108 
109 
110 
111 
112 */
113 
114 /* Please see man pages for details
115 
116 
117 
118 
119 */
120 NN_UTIL_DETAIL_CLIBIMPL_DEFINE_BUFFER_CLASS(nnhttpClientCert, nn::http::ClientCert, 12, u32);
121 
122 /* Please see man pages for details
123 
124 */
125 NN_EXTERN_C nnResult nnhttpClientCertInitialize(nnhttpClientCert* this_, const u8* pCertData, size_t certDataSize, const u8* pPrivateKeyData, size_t privateKeyDataSize);
126 
127 /* Please see man pages for details
128 
129 */
130 NN_EXTERN_C nnResult nnhttpClientCertInitializeByInternalCert(nnhttpClientCert* this_, NnHttpInternalClientCertId inClientCertName);
131 
132 
133 /* Please see man pages for details
134 
135 */
136 NN_EXTERN_C nnResult nnhttpClientCertFinalize(nnhttpClientCert* this_);
137 
138 
139 /*
140 
141 
142 
143 */
144 
145 #endif /* NN_HTTP_HTTP_CLIENTCERT_H_ */
146 
147