![Oracle Drags Its Feet in the JavaScript Trademark Dispute](https://cdn.sanity.io/images/cgdhsj6q/production/919c3b22c24f93884c548d60cbb338e819ff2435-1024x1024.webp?w=400&fit=max&auto=format)
Security News
Oracle Drags Its Feet in the JavaScript Trademark Dispute
Oracle seeks to dismiss fraud claims in the JavaScript trademark dispute, delaying the case and avoiding questions about its right to the name.
@tokenizer/s3
Advanced tools
Specialized tokenizer to access files stored on the Amazon Web Services (AWS) S3 cloud storage.
Install using npm:
npm install @tokenizer/s3 @aws-sdk/client-s3
or using yarn:
yarn add install @tokenizer/s3 @aws-sdk/client-s3
To configure AWS client authentication see Configuration and credential file settings.
Determine file type (based on it's content) from a file stored Amazon S3 cloud:
const FileType = require('file-type');
const { S3Client } = require('@aws-sdk/client-s3');
const { makeTokenizer } = require('@tokenizer/s3');
(async () => {
// Initialize S3 client
const s3 = new S3Client({});
// Initialize S3 tokenizer
const s3Tokenizer = await makeTokenizer(s3, {
Bucket: 'affectlab',
Key: '1min_35sec.mp4'
});
// Figure out what kind of file it is
const fileType = await FileType.fromTokenizer(s3Tokenizer);
console.log(fileType);
})();
See also example at file-type.
Retrieve music-metadata
const s3tokenizer = require("@tokenizer/s3");
const { S3Client } = require('@aws-sdk/client-s3');
const mm = require("music-metadata/lib/core");
/**
* Retrieve metadata from Amazon S3 object
* @param objRequest S3 object request
* @param options music-metadata options
* @return Metadata
*/
async function parseS3Object(s3, objRequest, options) {
const s3Tokenizer = await s3tokenizer.makeTokenizer(s3, objRequest, options);
return mm.parseFromTokenizer(s3Tokenizer, options);
}
(async () => {
const s3 = new S3Client({});
const metadata = await parseS3Object(s3, {
Bucket: 'standing0media',
Key: '01 Where The Highway Takes Me.mp3'
}
);
console.log(metadata);
})();
An module implementation of this example can be found in @music-metadata/s3.
FAQs
Amazon S3 tokenizer
We found that @tokenizer/s3 demonstrated a healthy version release cadence and project activity because the last version was released less than 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
Oracle seeks to dismiss fraud claims in the JavaScript trademark dispute, delaying the case and avoiding questions about its right to the name.
Security News
The Linux Foundation is warning open source developers that compliance with global sanctions is mandatory, highlighting legal risks and restrictions on contributions.
Security News
Maven Central now validates Sigstore signatures, making it easier for developers to verify the provenance of Java packages.