libintrovirt v0.57.4
IntroVirt introspection library
Loading...
Searching...
No Matches
CryptGenKey.hh
Go to the documentation of this file.
1/*
2 * Copyright 2021 Assured Information Security, Inc.
3 *
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
7 *
8 * http://www.apache.org/licenses/LICENSE-2.0
9 *
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.
15 */
16/* This file is automatically generated. Do not edit. */
17#pragma once
18
19#include <cstdint>
24#include <ostream>
25#include <string>
26
27namespace introvirt {
28namespace windows {
29namespace advapi32 {
30
36class CryptGenKey final : public WindowsFunctionCall {
37 public:
40
41 ALG_ID Algid() const;
43
44 uint32_t dwFlags() const;
45 void dwFlags(uint32_t dwFlags);
46
49
50 const std::string& function_name() const override;
51 const std::string& library_name() const override;
52 void write(std::ostream& os = std::cout) const override;
53 Json::Value json() const override;
54
55 bool result() const;
56 void result(bool result);
57
59 ~CryptGenKey() override;
60
61 /* Injection helper */
62 static bool inject(HCRYPTPROV hProv, ALG_ID Algid, uint32_t dwFlags,
64
65 static constexpr int ArgumentCount = 4;
66 inline static const std::string LibraryName = "advapi32";
67 inline static const std::string FunctionName = "CryptGenKey";
68
69 private:
70 /* Injection constructor */
73
74 private:
75 HCRYPTPROV hProv_;
76 ALG_ID Algid_;
77 uint32_t dwFlags_;
78 mutable guest_ptr<HCRYPTKEY> phKey_;
79};
80
81} // namespace advapi32
82} // namespace windows
83} // namespace introvirt
Interface class for hypervisor events.
Definition Event.hh:43
Definition guest_ptr.hh:88
Helper class to transparently convert between guest size and a value.
Definition guest_size_t_ptr.hh:498
Definition WindowsFunctionCall.hh:31
Handler for advapi32!CryptGenKey.
Definition CryptGenKey.hh:36
static constexpr int ArgumentCount
Definition CryptGenKey.hh:65
static const std::string FunctionName
Definition CryptGenKey.hh:67
const std::string & function_name() const override
Get the function name.
static bool inject(HCRYPTPROV hProv, ALG_ID Algid, uint32_t dwFlags, const guest_ptr< HCRYPTKEY > &phKey)
void phKey(const guest_ptr< HCRYPTKEY > &phKey)
Json::Value json() const override
Get the function as Json.
const std::string & library_name() const override
Get the name of the library this call is for.
guest_ptr< HCRYPTKEY > phKey() const
static const std::string LibraryName
Definition CryptGenKey.hh:66
void write(std::ostream &os=std::cout) const override
Write out a textual representation of the function for display.
Type-safe guest virtual address pointer and guest_ptr template.
ALG_ID
Encryption algoritm for advapi32 calls.
Definition ALG_ID.hh:32
Core IntroVirt classes.
Definition Cr0.hh:20