
Research
Security News
Malicious npm Packages Use Telegram to Exfiltrate BullX Credentials
Socket uncovers an npm Trojan stealing crypto wallets and BullX credentials via obfuscated code and Telegram exfiltration.
docpad-plugin-hapi
Advanced tools
A fully customizable Hapi server for docpad.
In docpad.coffee or docpad.js, you can directly add routes as specified in Hapi Documentation
Hapi plugins can easily be loaded. Plugins can access docpad through server.app.docpad. For example, to get docpad configuration, server.app.docpad.getConfig()
or in the router request.server.app.docpad.getConfig()
Also, server configuration can be overriden with the 'config' key
# Require Joi for route validation
Joi = require('joi');
# Docpad Configuration Object
module.exports = {
plugins:
hapi:
# router
routes: [
{
method: 'POST'
path: '/test'
handler: (request, reply) ->
reply('test');
config:
validate:
payload:
test: Joi.string().min(3).max(8)
},
{
method: 'PUT'
path: '/hello'
handler: (request, reply) ->
reply('hello');
}
]
# server plugins
plugins: [
{
good:
require: 'good',
options:
subscribers:
console: ['request', 'log', 'error']
},
{
yar:
require: 'yar',
options:
cookieOptions:
password: 'password'
},
customPlugin:
require: './lib/customPlugin',
options:
cookieOptions:
password: 'password'
]
# server config
config:
maxSockets: 2000
# clean urls
defaultExtension: 'html' # default value. Specify another extension if desired.
Clean URLs are enabled by default for files with .html extension. To change Clean URL extension, set plugin settings property "defaultExtension"
Change Procfile to
web: node_modules/docpad-plugin-hapi/bin/docpad-hapi-server
forever start node_modules/docpad-plugin-hapi/lib/bin/docpad-hapi-server.js
Licensed under the incredibly permissive MIT License
FAQs
A fully customizable Hapi server for Docpad.
The npm package docpad-plugin-hapi receives a total of 38 weekly downloads. As such, docpad-plugin-hapi popularity was classified as not popular.
We found that docpad-plugin-hapi 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 uncovers an npm Trojan stealing crypto wallets and BullX credentials via obfuscated code and Telegram exfiltration.
Research
Security News
Malicious npm packages posing as developer tools target macOS Cursor IDE users, stealing credentials and modifying files to gain persistent backdoor access.
Security News
AI-generated slop reports are making bug bounty triage harder, wasting maintainer time, and straining trust in vulnerability disclosure programs.