pidentd  3.0.19
About: implementation of the RFC1413 identification server (more or less complete rewrite compared to version 2)
  Fossies Dox: pidentd-3.0.19.tar.gz  ("inofficial" and yet experimental doxygen-generated source code documentation)  

k_next_mach.c File Reference
#include "config.h"
#include <stdio.h>
#include <errno.h>
#include <ctype.h>
#include <sys/types.h>
#include <sys/param.h>
#include <netdb.h>
#include <nlist.h>
#include <pwd.h>
#include <signal.h>
#include <syslog.h>
#include "pkvm.h"
#include <sys/socket.h>
#include <sys/socketvar.h>
#include <sys/ioctl.h>
#include <sys/file.h>
#include <sys/user.h>
#include <net/if.h>
#include <net/route.h>
#include <netinet/in.h>
#include <netinet/in_systm.h>
#include <netinet/ip.h>
#include <netinet/tcp.h>
#include <netinet/tcp_timer.h>
#include <netinet/tcp_var.h>
#include <netinet/in_pcb.h>
#include <netinet/ip_var.h>
#include "pidentd.h"
Include dependency graph for k_next_mach.c:

Go to the source code of this file.

Data Structures

struct  kainfo
 

Macros

#define KERNEL
 
#define KERNEL_FEATURES
 
#define N_FILE   0
 
#define N_NFILE   1
 
#define N_TCB   2
 

Functions

int ka_init (void)
 
int ka_open (void **misc)
 
static int getbuf (kvm_t *kd, off_t addr, void *buf, size_t len, char *what)
 
static struct socket * getlist (kvm_t *kd, struct inpcb *pcbp, struct in_addr *faddr, int fport, struct in_addr *laddr, int lport)
 
int ka_lookup (void *vp, struct kernel *kp)
 

Macro Definition Documentation

◆ KERNEL

#define KERNEL

Definition at line 32 of file k_next_mach.c.

◆ KERNEL_FEATURES

#define KERNEL_FEATURES

Definition at line 33 of file k_next_mach.c.

◆ N_FILE

#define N_FILE   0

Definition at line 71 of file k_next_mach.c.

◆ N_NFILE

#define N_NFILE   1

Definition at line 72 of file k_next_mach.c.

◆ N_TCB

#define N_TCB   2

Definition at line 73 of file k_next_mach.c.

Function Documentation

◆ getbuf()

static int getbuf ( kvm_t kd,
off_t  addr,
void *  buf,
size_t  len,
char *  what 
)
static

Definition at line 145 of file k_next_mach.c.

References kainfo::kd, and kvm_read().

Referenced by getlist(), and ka_lookup().

◆ getlist()

static struct socket* getlist ( kvm_t kd,
struct inpcb *  pcbp,
struct in_addr *  faddr,
int  fport,
struct in_addr *  laddr,
int  lport 
)
static

Definition at line 170 of file k_next_mach.c.

References getbuf().

Referenced by ka_lookup().

◆ ka_init()

int ka_init ( void  )

Definition at line 79 of file k_next_mach.c.

References osinfo_build, and osinfo_get().

◆ ka_lookup()

int ka_lookup ( void *  vp,
struct kernel kp 
)

◆ ka_open()

int ka_open ( void **  misc)

Definition at line 95 of file k_next_mach.c.

References debug, kainfo::kd, kvm_close(), kvm_nlist(), kvm_open(), kainfo::nl, s_free(), and s_malloc().