Wondering what’s next for npm?Check out our public roadmap! »

    downgrade-root

    2.0.0 • Public • Published

    downgrade-root

    Try to downgrade the permissions of a process with root privileges

    Usually applies to a process started with sudo.

    Windows is gracefully ignored as it lacks a way to set UID.

    Install

    $ npm install downgrade-root
    

    Usage

    import downgradeRoot from 'downgrade-root';
    
    try {
    	downgradeRoot();
    } catch {
    	console.error('Couldn\'t downgrade permissions');
    }

    Tip

    Useful for trying to downgrade permission before blocking using your app as root.

    Install

    npm i downgrade-root

    DownloadsWeekly Downloads

    124,396

    Version

    2.0.0

    License

    MIT

    Unpacked Size

    3.07 kB

    Total Files

    4

    Last publish

    Collaborators

    • avatar
    • avatar