Shelljs is a popular Node.js library that provides a set of portable Unix shell commands, allowing developers to execute common shell tasks directly from their JavaScript code. This eliminates the need to write complex system-specific scripts and enhances cross-platform compatibility. Version 0.2.3 was released on September 9, 2013, shortly after version 0.2.2 which came out on September 2, 2013.
While both versions share the same core functionality, description, dependencies (or lack thereof), development dependencies (jshint), repository, and author, the key difference lies in the specific bug fixes and internal improvements incorporated in the newer version. Although the provided data doesn't explicitly detail these changes, the tight release window suggests that version 0.2.3 likely addresses immediate issues or optimizations discovered in 0.2.2.
For developers, Shelljs simplifies tasks such as file manipulation (copying, moving, deleting), executing external programs, and working with directories. The availability of jshint as a dev dependency in both versions suggests a focus on code quality and maintainability within the library. The absence of dependencies makes it a lightweight addition to projects. When choosing between the two, it's advisable to opt for the slightly newer version (0.2.3) to benefit from any bug fixes and minor enhancements it contains, ensuring a more stable and reliable experience. Always refer to shelljs effective documentation for detailed changelogs (if available) to confirm precise changes.
All the vulnerabilities related to the version 0.2.3 of the package
Improper Privilege Management in shelljs
shelljs is vulnerable to Improper Privilege Management
Improper Privilege Management in shelljs
Output from the synchronous version of shell.exec()
may be visible to other users on the same system. You may be affected if you execute shell.exec()
in multi-user Mac, Linux, or WSL environments, or if you execute shell.exec()
as the root user.
Other shelljs functions (including the asynchronous version of shell.exec()
) are not impacted.
Patched in shelljs 0.8.5
Recommended action is to upgrade to 0.8.5.
https://huntr.dev/bounties/50996581-c08e-4eed-a90e-c0bac082679c/
If you have any questions or comments about this advisory: