shell bypass 403
GrazzMean Shell
: /home/homesquasz/devprod/Commercial/node_modules/eslint-plugin-unicorn/rules/utils/ [ drwx---r-x ]
'use strict';
/**
Escape string and wrap the result in quotes.
@param {string} string - The string to be quoted.
@param {string} quote - The quote character.
@returns {string} - The quoted and escaped string.
*/
module.exports = (string, quote = '\'') => {
const escaped = string
.replace(/\\/g, '\\\\')
.replace(/\r/g, '\\r')
.replace(/\n/g, '\\n')
.replace(new RegExp(quote, 'g'), `\\${quote}`);
return quote + escaped + quote;
};