#include <rz_io.h>
#include <rz_lib.h>
#include <rz_types.h>
#include <rz_util.h>
#include <sys/types.h>
Go to the source code of this file.
|
int | rzk__write (RzIO *io, RzIODesc *fd, const ut8 *buf, int count) |
|
static int | rzk__read (RzIO *io, RzIODesc *fd, ut8 *buf, int count) |
|
static int | rzk__close (RzIODesc *fd) |
|
static ut64 | rzk__lseek (RzIO *io, RzIODesc *fd, ut64 offset, int whence) |
|
static bool | rzk__plugin_open (RzIO *io, const char *pathname, bool many) |
|
static char * | rzk__system (RzIO *io, RzIODesc *fd, const char *cmd) |
|
static RzIODesc * | rzk__open (RzIO *io, const char *pathname, int rw, int mode) |
|
◆ rzk__close()
Definition at line 63 of file io_rzk.c.
69 #elif defined(__linux__) && !defined(__GNU__)
74 eprintf(
"TODO: rzk not implemented for this plataform.\n");
static static fork const void static count close
BOOL StartStopService(LPCTSTR lpServiceName, BOOL bStop)
static const z80_opcode fd[]
References close, eprintf, fd, gHandleDriver, StartStopService(), and TRUE.
◆ rzk__lseek()
◆ rzk__open()
Definition at line 107 of file io_rzk.c.
108 if (!strncmp(
pathname,
"rzk://", 6)) {
119 #elif defined(__linux__) && !defined(__GNU__)
122 io->
cb_printf(
"rzk__open: Error in opening /dev/rzk.");
131 io->
cb_printf(
"Not supported on this platform\n");
RZ_API void Ht_() free(HtName_(Ht) *ht)
RzIOPlugin rz_io_plugin_rzk
struct io_rzk_linux rzk_struct
int Init(const char *driverPath)
static static fork const void static count static fd const char const char static newpath char char char static envp time_t static t const char static mode static whence const char static dir time_t static t unsigned static seconds const char struct utimbuf static buf static inc static sig const char pathname
RZ_API RzIODesc * rz_io_desc_new(RzIO *io, RzIOPlugin *plugin, const char *uri, int flags, int mode, void *data)
References io_rzk_linux::beid, rz_io_t::cb_printf, eprintf, FALSE, fd, free(), Init(), NULL, O_RDONLY, pathname, io_rzk_linux::pid, rz_io_desc_new(), rz_io_plugin_rzk, RZ_NEW0, RZ_PERM_WX, rzk_struct, and io_rzk_linux::wp.
◆ rzk__plugin_open()
◆ rzk__read()
Definition at line 40 of file io_rzk.c.
43 #elif defined(__linux__) && !defined(__GNU__)
52 io->
cb_printf(
"ERROR: Undefined beid in rzk__read.\n");
57 io->
cb_printf(
"TODO: rzk not implemented for this plataform.\n");
static static sync static getppid static getegid const char static filename char static len const char char static bufsiz static mask static vfork const void static prot static getpgrp const char static swapflags static arg static fd static protocol static who struct sockaddr static addrlen static backlog struct timeval struct timezone static tz const struct iovec static count static mode const void const struct sockaddr static tolen const char static pathname void count
int ReadMemory(RzIO *io, RzIODesc *iodesc, int ioctl_n, size_t pid, size_t address, ut8 *buf, int len)
#define IOCTL_READ_KERNEL_MEMORY
#define IOCTL_READ_PHYSICAL_ADDR
#define IOCTL_READ_PROCESS_ADDR
int ReadKernelMemory(ut64 address, ut8 *buf, int len)
return memset(p, 0, total)
References io_rzk_linux::beid, rz_io_t::cb_printf, count, fd, IOCTL_READ_KERNEL_MEMORY, IOCTL_READ_PHYSICAL_ADDR, IOCTL_READ_PROCESS_ADDR, memset(), rz_io_t::off, io_rzk_linux::pid, ReadKernelMemory(), ReadMemory(), and rzk_struct.
◆ rzk__system()
Definition at line 88 of file io_rzk.c.
89 if (!strcmp(
cmd,
"")) {
92 if (!strncmp(
cmd,
"mod", 3)) {
97 #if defined(__linux__) && !defined(__GNU__)
101 eprintf(
"Try: 'R!mod'\n '.R!mod'\n");
static static sync static getppid static getegid const char static filename char static len const char char static bufsiz static mask static vfork const void static prot static getpgrp const char static swapflags cmd
int run_ioctl_command(RzIO *io, RzIODesc *iodesc, const char *buf)
int GetSystemModules(RzIO *io)
References cmd, eprintf, fd, GetSystemModules(), NULL, and run_ioctl_command().
◆ rzk__write()
Definition at line 18 of file io_rzk.c.
22 #elif defined(__linux__) && !defined(__GNU__)
31 io->
cb_printf(
"ERROR: Undefined beid in rzk__write.\n");
35 io->
cb_printf(
"TODO: rzk not implemented for this plataform.\n");
int WriteMemory(RzIO *io, RzIODesc *iodesc, int ioctl_n, size_t pid, ut64 address, const ut8 *buf, int len)
#define IOCTL_WRITE_PHYSICAL_ADDR
#define IOCTL_WRITE_PROCESS_ADDR
#define IOCTL_WRITE_KERNEL_MEMORY
int WriteKernelMemory(ut64 address, const ut8 *buf, int len)
References io_rzk_linux::beid, rz_io_t::cb_printf, count, fd, IOCTL_WRITE_KERNEL_MEMORY, IOCTL_WRITE_PHYSICAL_ADDR, IOCTL_WRITE_PROCESS_ADDR, rz_io_t::off, io_rzk_linux::pid, rzk_struct, WriteKernelMemory(), and WriteMemory().
◆ rizin_plugin
Initial value:
Definition at line 152 of file io_rzk.c.
◆ rz_io_plugin_rzk
Initial value:= {
.name = "rzk",
.desc = "Kernel access API io",
.uris = "rzk://",
.license = "LGPL3",
}
static char * rzk__system(RzIO *io, RzIODesc *fd, const char *cmd)
static ut64 rzk__lseek(RzIO *io, RzIODesc *fd, ut64 offset, int whence)
static int rzk__close(RzIODesc *fd)
static bool rzk__plugin_open(RzIO *io, const char *pathname, bool many)
int rzk__write(RzIO *io, RzIODesc *fd, const ut8 *buf, int count)
static RzIODesc * rzk__open(RzIO *io, const char *pathname, int rw, int mode)
static int rzk__read(RzIO *io, RzIODesc *fd, ut8 *buf, int count)
Definition at line 137 of file io_rzk.c.
Referenced by rzk__open().