Karl Zhang | 3de5ab1 | 2021-05-31 11:45:48 +0800 | [diff] [blame] | 1 | /* |
Nik Dewally | bacae6c | 2024-07-30 16:58:14 +0100 | [diff] [blame^] | 2 | * Copyright (c) 2019-2024, Arm Limited. All rights reserved. |
Karl Zhang | 3de5ab1 | 2021-05-31 11:45:48 +0800 | [diff] [blame] | 3 | * |
| 4 | * SPDX-License-Identifier: BSD-3-Clause |
| 5 | * |
| 6 | */ |
| 7 | |
| 8 | /* Objects typed to subclasses of the these classes are constructed and filled in |
| 9 | by the parser as it parses the test template. Although these objects do largely |
| 10 | correspond to template lines, there's no real correlation to lines in the |
| 11 | generated code. */ |
| 12 | |
| 13 | #ifndef SECURE_TEMPLATE_LINE_HPP |
| 14 | #define SECURE_TEMPLATE_LINE_HPP |
| 15 | |
Nik Dewally | bacae6c | 2024-07-30 16:58:14 +0100 | [diff] [blame^] | 16 | #include "data_blocks.hpp" |
| 17 | #include "security_call.hpp" |
| 18 | #include "template_line.hpp" |
| 19 | #include "tf_fuzz.hpp" |
Karl Zhang | 3de5ab1 | 2021-05-31 11:45:48 +0800 | [diff] [blame] | 20 | |
Nik Dewally | bacae6c | 2024-07-30 16:58:14 +0100 | [diff] [blame^] | 21 | class psa_call; |
Karl Zhang | 3de5ab1 | 2021-05-31 11:45:48 +0800 | [diff] [blame] | 22 | |
| 23 | using namespace std; |
| 24 | |
| 25 | /* Note: The following are sub-classed from security (above). */ |
| 26 | |
| 27 | class security_hash_template_line : public security_template_line |
| 28 | { |
| 29 | public: |
| 30 | // Data members: |
| 31 | // Methods: |
| 32 | void setup_call (set_data_info set_data, bool random_data, |
| 33 | bool fill_in_template, bool create_call, |
| 34 | template_line *temLin, tf_fuzz_info *rsrc) |
| 35 | { |
| 36 | define_call<hash_call> (set_data, random_data, fill_in_template, |
| 37 | create_call, temLin, rsrc, |
| 38 | add_to_end, yes_set_barrier); |
| 39 | } |
| 40 | bool copy_template_to_call (psa_call *the_call); |
| 41 | security_hash_template_line (tf_fuzz_info *resources); // (constructor) |
| 42 | ~security_hash_template_line (void); |
| 43 | |
| 44 | protected: |
| 45 | // Data members: |
| 46 | // Methods: |
| 47 | |
| 48 | private: |
| 49 | // Data members: |
| 50 | // Methods: |
| 51 | }; |
| 52 | |
| 53 | #endif // #ifndef SECURE_TEMPLATE_LINE_HPP |