
Research
Security News
The Growing Risk of Malicious Browser Extensions
Socket researchers uncover how browser extensions in trusted stores are used to hijack sessions, redirect traffic, and manipulate user behavior.
A cross platform Ruby interface for getting file system information.
gem install sys-filesystem
gem cert --add <(curl -Ls https://raw.githubusercontent.com/djberg96/sys-filesystem/main/certs/djberg96_pub.pem)
require 'sys/filesystem'
include Sys
# Display information about a particular filesystem.
p Filesystem.stat('/')
# Sample output
#<Sys::Filesystem::Stat:0x517440
@base_type = "ufs",
@flags = 4,
@files_available = 3817457,
@block_size = 8192,
@blocks_available = 19957633,
@blocks = 34349612,
@name_max = 255,
@path = "/",
@filesystem_id = 35651592,
@files = 4135040,
@fragment_size = 1024,
@files_free = 3817457,
@blocks_free = 20301129
>
# Describe all mount points on the system
Filesystem.mounts{ |mount| p mount }
# Find the mount point of any particular file
puts Filesystem.mount_point('/home/djberge/some_file.txt') => '/home'
This is a pure Ruby implementation that uses FFI. This means it should work with JRuby, too.
Run 'rake example' if you want to see a basic sample run. The actual code is 'example_stat.rb' in the 'examples' directory. Modify it as you see fit.
Currently this may not work if you're running a 32-bit system with 64-bit offsets:
https://github.com/djberg96/sys-filesystem/issues/71
Please report any other issues on the project home page at:
https://github.com/djberg96/sys-filesystem
Apache-2.0
(C) 2003-2024 Daniel J. Berger All Rights Reserved
This library is provided "as is" and without any express or implied warranties, including, without limitation, the implied warranties of merchantability and fitness for a particular purpose.
Daniel J. Berger
FAQs
Unknown package
We found that sys-filesystem demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
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.
Research
Security News
Socket researchers uncover how browser extensions in trusted stores are used to hijack sessions, redirect traffic, and manipulate user behavior.
Research
Security News
An in-depth analysis of credential stealers, crypto drainers, cryptojackers, and clipboard hijackers abusing open source package registries to compromise Web3 development environments.
Security News
pnpm 10.12.1 introduces a global virtual store for faster installs and new options for managing dependencies with version catalogs.