2 * Copyright (c) 2011 Samsung Electronics Co., Ltd All Rights Reserved
4 * Licensed under the Apache License, Version 2.0 (the "License");
5 * you may not use this file except in compliance with the License.
6 * You may obtain a copy of the License at
8 * http://www.apache.org/licenses/LICENSE-2.0
10 * Unless required by applicable law or agreed to in writing, software
11 * distributed under the License is distributed on an "AS IS" BASIS,
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 * See the License for the specific language governing permissions and
14 * limitations under the License.
18 * @author Bartlomiej Grzelewski (b.grzelewski@samsung.com)
22 #ifndef _VCORE_SRC_VCORE_VCORE_H_
23 #define _VCORE_SRC_VCORE_VCORE_H_
27 namespace ValidationCore {
29 * configFilePath - path to XML config file with certificates configuration
31 * configSchemaPath - XMLschema of config file
33 * databasePath - path to database with OCSP/CRL cache.
35 * This function could be run only once. If you call it twice it will
36 * return false and non data will be set.
39 bool VCoreInit(const std::string& configFilePath,
40 const std::string& configSchemaPath,
41 const std::string& databasePath);
44 * All thread with are using OCSP/CRL must call AttachToThread function before
45 * it can call OCSP/CRL. More than one thread could be Attach with OCPS/CRL.
47 * You mast attach thread to OCSP/CRL because OCSP/CRL is using database
48 * CertificateCachedDAO. For each thread that will be using this database
49 * vcore must create internal structure (with connection info).
52 void AttachToThread(void);
53 void DetachFromThread(void);
55 } // namespace ValidationCore
57 #endif // _VCORE_SRC_VCORE_VCORE_H_