Research
Security News
Malicious npm Packages Inject SSH Backdoors via Typosquatted Libraries
Socket’s threat research team has detected six malicious npm packages typosquatting popular libraries to insert SSH backdoors.
hex-transposition-cipher
Advanced tools
hexadecimal transposition cipher for shuffle and reverse shuffling hex encoded cipher text
hexadecimal transposition cipher for shuffle and reverse shuffling hex encoded cipher text for nodejs and the browser.
demo: https://angeal185.github.io/hex-transposition-cipher/
npm
$ npm install hex-transposition-cipher
ensure jquery is installed.
$ const htc = require('hex-transposition-cipher');
<script src="./path-to/lodash.min.js"></script>
<script src="./dist/htc.min.js"></script>
// defaults
{
decode: false, // set true for decrypt
reverse: false, // reverse encrypted/decrypted hex string
}
// htc.keyGenSync()
const key = htc.keyGen(); //generates random hex key from the default key
console.log(key) // returns hex key ~ dont lose this
/**
* htc.keyGen(callback)
* @param {function} callback
*/
htc.keyGen(function(i){
console.log(i) // returns hex key ~ dont lose this
});
/**
* htc.subSync(hex, key, config)
* @param {string} hex ~ hex string
* @param {object} key ~ hex key
* @param {object} config ~ optional options
*/
let res = htc.subSync('74657374', key, {decode:false, reverse: false})
console.log(res) // returns encrypted hex string
/**
* htc.sub(hex, key, config, callback)
* @param {string} hex ~ hex string
* @param {object} key ~ hex key
* @param {object} config ~ optional options
* @param {function} callback
*/
htc.sub(res, key, {decode:true, reverse: false}, function(i){
console.log(i) // returns decrypted hex string
})
FAQs
hexadecimal transposition cipher for shuffle and reverse shuffling hex encoded cipher text
We found that hex-transposition-cipher demonstrated a not healthy version release cadence and project activity because the last version was released 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’s threat research team has detected six malicious npm packages typosquatting popular libraries to insert SSH backdoors.
Security News
MITRE's 2024 CWE Top 25 highlights critical software vulnerabilities like XSS, SQL Injection, and CSRF, reflecting shifts due to a refined ranking methodology.
Security News
In this segment of the Risky Business podcast, Feross Aboukhadijeh and Patrick Gray discuss the challenges of tracking malware discovered in open source softare.