libintrovirt v0.57.4
IntroVirt introspection library
Loading...
Searching...
No Matches
WSARecvFrom.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>
26#include <memory>
27#include <ostream>
28#include <string>
29
30namespace introvirt {
31namespace windows {
32namespace ws2_32 {
33
39class WSARecvFrom final : public WindowsFunctionCall {
40 public:
41 SOCKET s() const;
42 void s(SOCKET s);
43
46 std::vector<std::shared_ptr<WSABUF>> Buffers();
47
48 uint32_t dwBufferCount() const;
50
53
56
59 std::shared_ptr<SOCKADDR> From();
60
63
66 std::shared_ptr<WSAOVERLAPPED> Overlapped();
67
70
71 const std::string& function_name() const override;
72 const std::string& library_name() const override;
73 void write(std::ostream& os = std::cout) const override;
74 Json::Value json() const override;
75
76 int32_t result() const;
77 void result(int32_t result);
78
80 ~WSARecvFrom() override;
81
82 /* Injection helper */
83 static int32_t inject(SOCKET s, const guest_ptr<void>& pBuffers, uint32_t dwBufferCount,
88
89 static constexpr int ArgumentCount = 9;
90 inline static const std::string LibraryName = "ws2_32";
91 inline static const std::string FunctionName = "WSARecvFrom";
92
93 private:
94 /* Injection constructor */
99
100 private:
101 SOCKET s_;
102 guest_ptr<void> pBuffers_;
103 uint32_t dwBufferCount_;
104 mutable guest_ptr<uint32_t> pNumberOfBytesRecvd_;
105 mutable guest_ptr<uint32_t> pFlags_;
106 guest_ptr<void> pFrom_;
107 mutable guest_ptr<int32_t> pFromlen_;
108 guest_ptr<void> pOverlapped_;
109 mutable guest_ptr<void> pCompletionRoutine_;
110};
111
112} // namespace ws2_32
113} // namespace windows
114} // 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 ws2_32!WSARecvFrom.
Definition WSARecvFrom.hh:39
guest_ptr< void > pOverlapped() const
static int32_t inject(SOCKET s, const guest_ptr< void > &pBuffers, uint32_t dwBufferCount, const guest_ptr< uint32_t > &pNumberOfBytesRecvd, const guest_ptr< uint32_t > &pFlags, const guest_ptr< void > &pFrom, const guest_ptr< int32_t > &pFromlen, const guest_ptr< void > &pOverlapped, const guest_ptr< void > &pCompletionRoutine)
guest_ptr< void > pBuffers() const
void pOverlapped(const guest_ptr< void > &pOverlapped)
const std::string & function_name() const override
Get the function name.
void pFlags(const guest_ptr< uint32_t > &pFlags)
void pFrom(const guest_ptr< void > &pFrom)
const std::string & library_name() const override
Get the name of the library this call is for.
void pNumberOfBytesRecvd(const guest_ptr< uint32_t > &pNumberOfBytesRecvd)
guest_ptr< uint32_t > pNumberOfBytesRecvd() const
void dwBufferCount(uint32_t dwBufferCount)
static const std::string LibraryName
Definition WSARecvFrom.hh:90
guest_ptr< void > pFrom() const
guest_ptr< int32_t > pFromlen() const
std::vector< std::shared_ptr< WSABUF > > Buffers()
Json::Value json() const override
Get the function as Json.
static constexpr int ArgumentCount
Definition WSARecvFrom.hh:89
guest_ptr< void > pCompletionRoutine() const
void pFromlen(const guest_ptr< int32_t > &pFromlen)
void write(std::ostream &os=std::cout) const override
Write out a textual representation of the function for display.
std::shared_ptr< SOCKADDR > From()
static const std::string FunctionName
Definition WSARecvFrom.hh:91
void pCompletionRoutine(const guest_ptr< void > &pCompletionRoutine)
std::shared_ptr< WSAOVERLAPPED > Overlapped()
guest_ptr< uint32_t > pFlags() const
void pBuffers(const guest_ptr< void > &pBuffers)
Type-safe guest virtual address pointer and guest_ptr template.
Core IntroVirt classes.
Definition Cr0.hh:20