Skip to content

Instantly share code, notes, and snippets.

@blelump
blelump / aws_signed_request_v4.rb
Last active December 8, 2022 15:51
Sample Ruby code to create AWS signed request version 4 (with request headers)
#Signing AWS Requests By Using Signature Version 4
#http://docs.aws.amazon.com/general/latest/gr/sigv4_signing.html
require 'uri'
require 'openssl'
require 'net/http'
require 'cgi'
method = 'GET'
service = 'iam'