npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2025 – Pkg Stats / Ryan Hefner

spoof-d

v0.2.0

Published

Cross-platform MAC address spoofing utility for macOS, Windows, and Linux

Downloads

191

Readme

spoof-d

npm version license GitHub forks GitHub stars

✅ Cross-Platform Support: This is a modernized fork of the original spoof project, updated for compatibility with modern macOS (Sequoia 15.4+, Tahoe 26+), Windows 10/11, and Linux. All platforms are now fully supported!

Easily spoof your MAC address on macOS, Windows, and Linux!

A Node.js utility for changing MAC addresses across all major platforms. Features reliable macOS support, modern Windows PowerShell integration, and Linux ip link commands. This fork includes enhanced error handling, automatic verification, retry logic, and improved cross-platform compatibility.

About This Fork

This repository (TT5H/spoof-d) is a fork of basedbytes/spoofy, which itself is a fork of the original spoof project. This fork extends the functionality with full cross-platform support and enhanced features.

What's Changed

  • ✅ Full Cross-Platform Support: Complete Windows 10/11 and Linux support (not just macOS)
  • Modern macOS Support: Fixed MAC spoofing for macOS Sequoia 15.4+ and Tahoe 26+
  • Windows Support: Full Windows 10/11 support using PowerShell and registry methods with automatic fallback
  • Linux Support: Modern Linux support using ip link commands (replaces deprecated ifconfig)
  • Enhanced Error Handling: Custom error classes with actionable suggestions and better error messages
  • Automatic Verification: Verifies MAC address changes after setting them
  • Retry Logic: Automatic retry with exponential backoff for transient failures
  • Timeout Handling: Prevents hanging operations with configurable timeouts
  • Better Validation: Comprehensive input validation with helpful error messages
  • Removed airport dependency: The deprecated airport -z command has been replaced with modern networksetup commands
  • Timing-sensitive MAC changes: WiFi MAC addresses are now changed in the brief window after power-on but before network connection
  • Improved interface detection: Better cross-platform interface detection using modern system commands
  • Cleaner codebase: Removed deprecated code paths and unnecessary constants

Key Features

Enhanced Error Handling

  • Custom error classes with specific error types (ValidationError, PermissionError, NetworkError, etc.)
  • Actionable suggestions provided with every error message
  • Better error context to help diagnose issues quickly

Reliability Features

  • Automatic verification of MAC address changes after setting them
  • Retry logic with exponential backoff for transient failures
  • Timeout handling to prevent hanging operations
  • Comprehensive validation of inputs before attempting changes

Cross-Platform Excellence

  • Windows: PowerShell integration with registry fallback
  • macOS: Modern networksetup commands with WiFi timing handling
  • Linux: Modern ip link commands with ifconfig fallback
  • Unified API across all platforms

User Experience Features

  • Progress indicators for long-running operations
  • Verbose mode (--verbose) for detailed debugging output
  • JSON output (--json) for scripting and automation
  • Configuration file support (.spoofyrc in home directory)

Installation

From npm (recommended)

npm install -g spoof-d

After installation, use the spoofy command (the package name is spoof-d, but the command is still spoofy).

After installation, you can use the spoofy command from anywhere.

From source

git clone https://github.com/TT5H/spoof-d.git
cd spoof-d
npm install
npm install -g .

This gives you the latest development version with all the latest features.

Quick Start

List network interfaces

macOS/Linux:

spoofy list

Windows (run PowerShell as Administrator):

spoofy list

Randomize MAC address

macOS (WiFi is typically en0):

sudo spoofy randomize en0

Windows:

# Run PowerShell as Administrator
spoofy randomize "Ethernet"

Linux:

sudo spoofy randomize eth0

Note: WiFi will disconnect briefly and may need to reconnect to networks. On Windows, ensure you're running as Administrator.

Usage

You can always see up-to-date usage instructions by running spoofy --help.

List available devices

spoofy list

Output:

- "Ethernet" on device "en4" with MAC address 70:56:51:BE:B3:00
- "Wi-Fi" on device "en0" with MAC address 70:56:51:BE:B3:01 currently set to 70:56:51:BE:B3:02
- "Bluetooth PAN" on device "en1"

List only Wi-Fi devices

spoofy list --wifi

Randomize MAC address (requires root)

Using hardware port name:

sudo spoofy randomize wi-fi

Or using device name:

sudo spoofy randomize en0

Set specific MAC address (requires root)

sudo spoofy set 00:11:22:33:44:55 en0

Reset to original MAC address (requires root)

sudo spoofy reset wi-fi

Note: On macOS, restarting your computer will also reset your MAC address to the original hardware address.

Advanced Usage

Verbose Mode

Get detailed debugging information:

spoofy list --verbose
spoofy randomize en0 --verbose

JSON Output

Output results in JSON format for scripting:

spoofy list --json
spoofy randomize en0 --json

Example JSON output:

{
  "success": true,
  "device": "en0",
  "mac": "00:11:22:33:44:55",
  "message": "MAC address changed successfully"
}

Configuration File

Create a configuration file at ~/.spoofyrc (or %USERPROFILE%\.spoofyrc on Windows):

{
  "randomize": {
    "local": true
  },
  "defaults": {
    "verbose": false,
    "json": false
  }
}

The configuration file allows you to set default options that will be used automatically.

Progress Indicators

Long-running operations show progress indicators:

⏳ Changing MAC address... ✓ Successfully set MAC address

Platform Support

macOS ✅

  • Fully supported and tested on macOS Tahoe 26.2
  • ✅ Works on macOS Sequoia 15.4+
  • ⚠️ Older versions may work but are untested
  • Uses networksetup and ifconfig commands
  • Special handling for WiFi interfaces on modern macOS

Windows ✅

  • Fully supported on Windows 10 and Windows 11
  • ✅ Uses PowerShell Get-NetAdapter and Set-NetAdapter commands
  • ✅ Falls back to registry method for compatibility
  • ⚠️ Requires Administrator privileges (run PowerShell/CMD as Administrator)
  • Some network adapters may not support MAC address changes (hardware limitation)

Windows Usage:

# Run PowerShell or CMD as Administrator
spoofy list
spoofy randomize "Ethernet"
spoofy set 00:11:22:33:44:55 "Wi-Fi"

Linux ✅

  • Fully supported using modern ip link commands
  • ✅ Falls back to ifconfig if ip command is not available
  • ⚠️ Requires root privileges (use sudo)
  • Works with most modern Linux distributions

Linux Usage:

sudo spoofy list
sudo spoofy randomize eth0
sudo spoofy set 00:11:22:33:44:55 wlan0

Known Issues

  • WiFi will briefly disconnect when changing MAC address
  • Some network restrictions or hardware may prevent MAC spoofing
  • Requires sudo/root privileges for all MAC address changes

Troubleshooting

macOS

  1. Make sure you're running with sudo (required for network changes)
  2. Ensure WiFi is turned on before attempting to change MAC
  3. On modern macOS, you may need to reconnect to WiFi after the change
  4. Try running networksetup -detectnewhardware if changes don't take effect

Windows

  1. Run as Administrator: Right-click PowerShell or Command Prompt and select "Run as Administrator"
  2. Some network adapters don't support MAC address changes (hardware limitation)
  3. If Set-NetAdapter fails, the tool will automatically try the registry method
  4. You may need to disable and re-enable the adapter manually if changes don't take effect
  5. Check adapter compatibility: Some virtual adapters and certain hardware may not support MAC spoofing

Linux

  1. Make sure you're running with sudo (required for network changes)
  2. Ensure the ip command is available (usually in iproute2 package)
  3. Some network interfaces may be managed by NetworkManager - you may need to disable it temporarily
  4. Virtual interfaces and certain hardware may not support MAC address changes

Contributing

This is an active fork. Contributions, bug reports, and feature requests are welcome!

To contribute:

  1. Fork this repository
  2. Create a feature branch (git checkout -b feature/amazing-feature)
  3. Commit your changes (git commit -m 'Add some amazing feature')
  4. Push to the branch (git push origin feature/amazing-feature)
  5. Open a Pull Request

License

MIT License (inherited from original project)

Credits

  • This fork: TT5H/spoof-d - Enhanced cross-platform support with improved error handling
  • Parent fork: basedbytes/spoofy - Modernized macOS support
  • Original project: spoof by Feross Aboukhadijeh

This fork maintains compatibility with modern operating systems and extends support to Windows and Linux.