Research
Security News
Malicious npm Packages Inject SSH Backdoors via Typosquatted Libraries
Socket’s threat research team has detected six malicious npm packages typosquatting popular libraries to insert SSH backdoors.
generate-timezone-json
Advanced tools
Generate JSON file containing timezones from a tab file or the official IANA database
This is a node package which allows the generation of a JSON file containing time zones information. You could provide it your own zone.tab file, in which case it will parse the file to generate the JSON. If not given any input, it will pull the latest official time zones for you.
Please report issues found or suggestions in the project issues page
Use case: This script is specifically useful when you need a JSON file with timezones information. Maybe you need this information to be synced with your server which uses a tab file (i.e., tab-separated values). Or maybe you just need a static persistent file generated from the latest official time zones database. In these cases, this script is what you need. For other use cases, see "Other Options" section below.
Recommendation: For performance, I recommend you don't generate the JSON file multiple times in run time. Determine a single point in your app/system's life cycle when it is best to do this (e.g., pre-build time or once when requested for the first time).
Requirement: This is a lightweight node.js script, and only requires that you have node installed.
Running the following will automatically download and cache the latest version, so there is no need to permanently install anything.
npx generate-timezone-json
to generate timezones.json from official IANA Databasenpx generate-timezone-json <filename>
to generate timezones.json from a TAB file,
generate-timezone-json zone.tab
Important Note: Currently, the structure of the generated JSON file will be different depending on the source (i.e, zone.tab or the IANA time zones database). This will be addressed in this github issue.
If you have a need to permanently install the package do the following:
npm i generate-timezone-json
npm i -g generate-timezone-json
After installation, you can use npx generate-timezone-json
.
You can also download the latest releases in Github. After downloading, extract the package, and run the unpacked JS script it with node: node index.js
.
This package is specifically useful if you need a JSON file with time zones information. I did not find anything like it but it uses a couple of other packages under the hood. The following may be more appropriate for you:
--outDir
: generate-timezone <filename> --outDir <directory>
FAQs
Generate JSON file containing timezones from a tab file or the official IANA database
The npm package generate-timezone-json receives a total of 15 weekly downloads. As such, generate-timezone-json popularity was classified as not popular.
We found that generate-timezone-json demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 0 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.
Research
Security News
Socket’s threat research team has detected six malicious npm packages typosquatting popular libraries to insert SSH backdoors.
Security News
MITRE's 2024 CWE Top 25 highlights critical software vulnerabilities like XSS, SQL Injection, and CSRF, reflecting shifts due to a refined ranking methodology.
Security News
In this segment of the Risky Business podcast, Feross Aboukhadijeh and Patrick Gray discuss the challenges of tracking malware discovered in open source softare.