
Security News
/Research
Wallet-Draining npm Package Impersonates Nodemailer to Hijack Crypto Transactions
Malicious npm package impersonates Nodemailer and drains wallets by hijacking crypto transactions across multiple blockchains.
@svkeg/ask-it
Advanced tools
Wrapper around inquirer to make asking questions in Node CLIs easier.
Add to your package.json
"askIt": "git+https://github.com/lancetipton/askIt.git"
See an example here
;(() => {
const { ask, separator, models } = require('askIt')
// See src/models/models for more information
const questionModelObject = {
// Add the default input model
...models.input,
// Override with custom values
type: 'Question type',
name: 'Name of the question',
message: 'Question to ask',
default: 'Default value if user enters nothing',
}
// Pass the model directly to the ask method
// Returns a value entered by the user or the default
const askResponse = await ask({ ...questionModelObject })
// Ask a true / false question
// Returns a boolean
const confirmResponse = await ask.confirm('Ask a confirm question?')
// Ask for text input
// Returns a string of the entered text
const inputResponse = await ask.input('Ask for text input')
// Ask for a password / secret - input will be hidden
// Returns a string of the entered text
const passwordResponse = await ask.password('Ask for hidden text input')
// Ask for user to select an option from a list of options
// Returns the index of the select option within the passed in array
const listResponse = await ask.promptList([
'Option 1',
'Option 2',
'Option 3',
])
})()
function
Object
- a question model object
function
string
- The true / false question to askstring
used as the question asked to the userfunction
string
- The text input question to askfunction
string
- The text input question to askask.input
, except user input is hiddenfunction
array
- List of options to present to the userindex
of the selected item from the passed in options
function
new inquirer.Separator()
Object
FAQs
Node CLI helper for asking questions
The npm package @svkeg/ask-it receives a total of 0 weekly downloads. As such, @svkeg/ask-it popularity was classified as not popular.
We found that @svkeg/ask-it 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.
Security News
/Research
Malicious npm package impersonates Nodemailer and drains wallets by hijacking crypto transactions across multiple blockchains.
Security News
This episode explores the hard problem of reachability analysis, from static analysis limits to handling dynamic languages and massive dependency trees.
Security News
/Research
Malicious Nx npm versions stole secrets and wallet info using AI CLI tools; Socket’s AI scanner detected the supply chain attack and flagged the malware.