
Research
/Security News
Critical Vulnerability in NestJS Devtools: Localhost RCE via Sandbox Escape
A flawed sandbox in @nestjs/devtools-integration lets attackers run code on your machine via CSRF, leading to full Remote Code Execution (RCE).
github.com/dolanor/caddy-git
Middleware for Caddy.
git clones a git repository into the site. This makes it possible to deploy your site with a simple git push.
The git directive does not chain in a handler. Instead, it starts a service routine that runs during the lifetime of the server. When the server starts, it clones the repository. While the server is still up, it pulls the latest every so often. In regular git fashion, a download only includes changes so it is very efficient.
If a pull fails, the service will retry up to three times. If the pull was not successful by then, it won't try again until the next interval.
Requirements: This directive requires git to be installed. Also, private repositories may only be accessed from Linux or Mac systems. (Contributions are welcome that make private repositories work on Windows.)
git repo [path]
This simplified syntax pulls from master every 3600 seconds (1 hour) and only works for public repositories.
For more control or to use a private repository, use the following syntax:
git [repo path] {
repo repo
path path
branch branch
key key
interval interval
hook path secret
then command [args...]
then_long command [args...]
}
{latest}
is a placeholder for latest tag which ensures the most recent tag is always pulled.Each property in the block is optional. The path and repo may be specified on the first line, as in the first syntax, or they may be specified in the block with other values.
Public repository pulled into site root every hour:
git github.com/user/myproject
Public repository pulled into the "subfolder" directory in the site root:
git github.com/user/myproject /subfolder
Private repository pulled into the "subfolder" directory with tag v1.0 once per day:
git {
repo git@github.com:user/myproject
branch v1.0
key /home/user/.ssh/id_rsa
path subfolder
interval 86400
}
Generate a static site with Hugo after each pull:
git github.com/user/site {
path ../
then hugo --destination=/home/user/hugosite/public
}
Part of a Caddyfile for a PHP site that gets changes from a private repo:
git git@github.com:user/myphpsite {
key /home/user/.ssh/id_rsa
}
fastcgi / 127.0.0.1:9000 php
Specifying a webhook:
git git@github.com:user/site {
hook /webhook secret-password
}
{
"ref" : "refs/heads/branch"
}
FAQs
Unknown package
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
A flawed sandbox in @nestjs/devtools-integration lets attackers run code on your machine via CSRF, leading to full Remote Code Execution (RCE).
Product
Customize license detection with Socket’s new license overlays: gain control, reduce noise, and handle edge cases with precision.
Product
Socket now supports Rust and Cargo, offering package search for all users and experimental SBOM generation for enterprise projects.