2 * Copyright (c) 2016 Samsung Electronics Co., Ltd All Rights Reserved
4 * Contact: Kyungwook Tak <k.tak@samsung.com>
6 * Licensed under the Apache License, Version 2.0 (the "License");
7 * you may not use this file except in compliance with the License.
8 * You may obtain a copy of the License at
10 * http://www.apache.org/licenses/LICENSE-2.0
12 * Unless required by applicable law or agreed to in writing, software
13 * distributed under the License is distributed on an "AS IS" BASIS,
14 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
15 * See the License for the specific language governing permissions and
16 * limitations under the License
19 * @author Zofia Abramowska (z.abramowska@samsung.com)
25 #include <ckm/ckm-type.h>
27 // mirrors the API-defined value
28 #ifndef AES_GCM_TAG_SIZE
29 #define AES_GCM_TAG_SIZE 16
32 CKM::RawBuffer createDefaultPass();
33 CKM::RawBuffer createPass(std::size_t from, std::size_t to);
34 CKM::RawBuffer createBigBlob(std::size_t size);
35 CKM::RawBuffer createRandom(std::size_t size);
37 const CKM::RawBuffer defaultPass = createDefaultPass();
38 const std::string pattern =
39 "000102030405060708090a0b0c0d0e0f101112131415161718191a1b1c1d1e1f";
41 const std::size_t RAW_PASS_SIZE = 32;
42 const std::size_t HEX_PASS_SIZE = RAW_PASS_SIZE * 2;
45 std::string rawToHexString(const CKM::RawBuffer &raw);