Skip to content

mejedi/proxyfd

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

16 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

proxyfd

Linux kernel module implementing proxy files. Proxy file sits in front of a pipe write end. Every chunk of data written via proxy is prefixed with the chunk length in atomic fashion. The length is OR-combined with a cookie set at creation time. With cookies it is possible to tell the origin if multiple proxies use the same pipe.

Usage:

Device node: /dev/proxyfd. To request a proxy, write the following request into device:

struct request
{
  uint32_t flags; // O_CLOEXEC
  uint32_t cookie;
  uint32_t pipefd;
};

write() result is either an error or a new (proxy) file descriptor.

Check user.c for usage example.

Install:

make && sudo insmod proxyfd.ko

About

Linux kernel module implementing proxy files

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published