Security News
Cloudflare Adds Security.txt Setup Wizard
Cloudflare has launched a setup wizard allowing users to easily create and manage a security.txt file for vulnerability disclosure on their websites.
This module offers simple bindings for the C time.h APIs.
It also extends the regular Date
object with a setTimeZone
function, which isn't normally part of JavaScript.
var time = require('time');
// Create a new Date instance
var now = new Date();
now.setTimeZone("America/Los_Angeles");
// `.getDate()`, `.getDay()`, `.getHours()`, etc.
// will return values according to UTC-8
now.setTimeZone("America/New_York");
// `.getDate()`, `.getDay()`, `.getHours()`, etc.
// will return values according to UTC-5
Be sure to request any additional features by creating a GitHub Issue requesting it!
The time
module itself exports some functions as well:
Binding for time(3)
. Returns the number of seconds since Jan 1, 1900 UTC.
Binding for tzset(3)
. Sets up the internal timezone information based on the
current process.env.TZ
value. This must be called after a change to the TZ
environment variable.
Binding for localtime()
. Accepts a Number with the number of seconds since the
Epoch (i.e. the result of time()
), and returns a "broken-down" Object
representation of the timestamp, according the the currently configured timezone
(see tzset()
).
FAQs
"time.h" bindings for Node.js
The npm package time receives a total of 639 weekly downloads. As such, time popularity was classified as not popular.
We found that time demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 2 open source maintainers 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
Cloudflare has launched a setup wizard allowing users to easily create and manage a security.txt file for vulnerability disclosure on their websites.
Security News
The Socket Research team breaks down a malicious npm package targeting the legitimate DOMPurify library. It uses obfuscated code to hide that it is exfiltrating browser and crypto wallet data.
Security News
ENISA’s 2024 report highlights the EU’s top cybersecurity threats, including rising DDoS attacks, ransomware, supply chain vulnerabilities, and weaponized AI.