Socket
Book a DemoInstallSign in
Socket

procfs2

Package Overview
Dependencies
Maintainers
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

procfs2

0.1.1
bundlerRubygems
Version published
Maintainers
1
Created
Source

Procfs2

Browse /proc fs on Linux.

This is a draft version.

Installation

Manual install, with:

$ gem install procfs2

Add to Gemfile with:

$ bundle add procfs2

Usage

This is a draft version.

It may change or not.

Comments / PR welcome !

Example of usage:

@p = Procfs2.proc

puts @p
puts @p.version._path
puts @p.version._raw_content
puts @p.version.version
puts @p.version.timestamp

puts @p.pid('self').fd._path
puts @p.pid('self').fd.id(0)

puts @p.pid(1091714).fd.id(3).type
puts @p.pid(1091714).fd.select { |fd| fd.type == 'socket' }
puts @p.pid(1091714).fd.select { |fd| fd.type == 'socket' }.map { |fd| fd.inode }

puts @p.net.tcp.by_inode(2235042).id
puts @p.net.tcp.by_inode(2235042).remote_address
puts @p.net.tcp.by_inode(2235042).remote_port
puts @p.net.tcp.by_inode(2235042).state_str

Contributing

Bug reports and pull requests are welcome on GitHub at https://github.com/[USERNAME]/procfs2.

References

License

The gem is available as open source under the terms of the MIT License.

FAQs

Package last updated on 21 May 2024

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

About

Packages

Stay in touch

Get open source security insights delivered straight into your inbox.

  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc

U.S. Patent No. 12,346,443 & 12,314,394. Other pending.