mirror of
https://github.com/0dayCTF/reverse-shell-generator.git
synced 2024-12-18 19:06:09 +00:00
fixed non functional download button in bind shell and msfvenom tabs.
This commit is contained in:
parent
6a680afd74
commit
054ea25bdd
23
js/script.js
23
js/script.js
@ -62,16 +62,6 @@ for (const button of rawLinkButtons) {
|
||||
});
|
||||
}
|
||||
|
||||
document.querySelector(".download-listener").addEventListener("click", () => {
|
||||
var element = document.createElement('a');
|
||||
const rawLink = RawLink.generate(rsg);
|
||||
element.setAttribute('href', rawLink);
|
||||
element.setAttribute('download', rsg.getSelectedCommandName());
|
||||
document.body.appendChild(element);
|
||||
element.click();
|
||||
document.body.removeChild(element);
|
||||
})
|
||||
|
||||
const filterCommandData = function (data, { commandType, filter }) {
|
||||
return data.filter(item => {
|
||||
if (!item.meta.includes(commandType)) {
|
||||
@ -451,6 +441,19 @@ document.querySelector('#copy-msfvenom-command').addEventListener('click', () =>
|
||||
rsg.copyToClipboard(msfVenomCommand.innerText)
|
||||
})
|
||||
|
||||
var downloadButton = document.querySelectorAll(".download-listener");
|
||||
for (const Dbutton of downloadButton) {
|
||||
Dbutton.addEventListener("click", () => {
|
||||
var element = document.createElement('a');
|
||||
const rawLink = RawLink.generate(rsg);
|
||||
element.setAttribute('href', rawLink);
|
||||
element.setAttribute('download', rsg.getSelectedCommandName());
|
||||
document.body.appendChild(element);
|
||||
element.click();
|
||||
document.body.removeChild(element);
|
||||
});
|
||||
}
|
||||
|
||||
// autoCopySwitch.addEventListener("change", () => {
|
||||
// setLocalStorage(autoCopySwitch, "auto-copy", "checked");
|
||||
// });
|
||||
|
Loading…
Reference in New Issue
Block a user