You're Invited:Meet the Socket Team at BlackHat and DEF CON in Las Vegas, Aug 4-6.RSVP
Socket
Book a DemoInstallSign in
Socket

aws-md5-of-message-attributes

Package Overview
Dependencies
Maintainers
1
Versions
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

aws-md5-of-message-attributes

Compute the MD5 hash of AWS SQS Message Attributes

1.0.0
latest
npmnpm
Version published
Maintainers
1
Created
Source

AWS MD5 of Message Attributes

Compute the MD5 hash of AWS SQS Message Attributes

Diagram - Calculating the MD5 message digest for message attributes

Install

npm i aws-md5-of-message-attributes

Usage examples:

const { md5OfMessageAttributes } = require("aws-md5-of-message-attributes");

const simpleAttribute = { attribName1: { DataType: "String", StringValue: "attribValue 1" } };
md5OfMessageAttributes(simpleAttribute); // 19e27d4e946b072f3f58da80d94fd778

const withCustomAttributeType = { customNumberTypeAttrib: { DataType: "Number.float", StringValue: "4563442423554324324264524243.32543234" } };
md5OfMessageAttributes(withCustomAttributeType); // 9fe1b90bbd9965bdf77bac517c7d2495

const binaryAttribute = { binaryAttribute: { DataType: "Binary", BinaryValue: Buffer.from("Hello binary world!").toString("base64") } };
md5OfMessageAttributes(binaryAttribute); // 31a92b15d92f8db860eda32aceb656c3

const multipleAttributes = {
  attribName1: { DataType: "String", StringValue: "attribValue 1" },
  customNumberTypeAttrib: { DataType: "Number.float", StringValue: "4563442423554324324264524243.32543234" },
  binaryAttribute: { DataType: "Binary", BinaryValue: Buffer.from("Hello binary world!").toString("base64") },
};
md5OfMessageAttributes(multipleAttributes); // c932db14a896c663f83c260297d594ff

Resources:

  • Calculating the MD5 message digest for message attributes

Keywords

aws

FAQs

Package last updated on 20 Apr 2024

Did you know?

Socket

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.

Install

Related posts