awskeyring 1.9.2 → 1.9.3

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 6461179e25d74d7a488cc8dd25db6cb3f3965c177f0dd5cdc8fa440f7c0bf1e3
4
- data.tar.gz: 30ac24cde26e0b407a89b218e61ecfd5a8f3ed2852d1da3e3339fa0ef82d17c1
3
+ metadata.gz: ab7e97d00115352839c4d8e0824bb600df50322cab8fc819236635ff17235c3b
4
+ data.tar.gz: bc9f08082c31fe1fdc130506ccab07f782b78b55aa8b55d45b51d2c93305a9fc
5
5
  SHA512:
6
- metadata.gz: c11cee874dbaa962b252a637ebffb6623fbc0bf05cafaab9e32bbf34b8243dcf0a53e91f1ca6b3f1e4a2e65f3112981cae169334fa89817a866b8efe48a650dd
7
- data.tar.gz: e4bbba7de171b98f88a1e3ea9232ab54c09a785712cddf979f232539ec867676bc0e33fe3b763eaf8217feecb3728aad11436326795f30560034ceeb2ac2d769
6
+ metadata.gz: 200fd3d71505cb09266c76ff58ed9ad09ed671353b3df800aa774e68e482e4f02d87304cd5af59a978f084493da97352b10eed7fa47fa3aafad7a4aabdbfdd26
7
+ data.tar.gz: e0e114ab4d902e2ca79d571a34b88fd7d600abd322e6a98a2e44bd90f8b705a2d9571e9175fd3481e8666986d78b78e7de8c4b3038cd3e3744d5b61c60c0323f
data/LICENSE.txt CHANGED
@@ -1,6 +1,6 @@
1
1
  The MIT License (MIT)
2
2
 
3
- Copyright (c) 2017-2021 Tristan Morgan
3
+ Copyright (c) 2016-2021 Tristan Morgan
4
4
 
5
5
  Permission is hereby granted, free of charge, to any person obtaining a copy
6
6
  of this software and associated documentation files (the "Software"), to deal
data/Rakefile CHANGED
@@ -39,7 +39,7 @@ task :filemode do
39
39
  files.merge(dirs).each do |file|
40
40
  mode = File.stat(file).mode
41
41
  print '.'
42
- failure << file if (mode & 0x7) != (mode >> 3 & 0x7)
42
+ failure << file if (mode & 0x7) != ((mode >> 3) & 0x7)
43
43
  end
44
44
  abort "\nError: Incorrect file mode found\n#{failure.join("\n")}" unless failure.empty?
45
45
  print "\n"
data/awskeyring.gemspec CHANGED
@@ -26,6 +26,7 @@ Gem::Specification.new do |spec|
26
26
  'bug_tracker_uri' => "#{Awskeyring::HOMEPAGE}/issues",
27
27
  'changelog_uri' => "#{Awskeyring::HOMEPAGE}/blob/main/CHANGELOG.md",
28
28
  'documentation_uri' => "https://rubydoc.info/gems/#{spec.name}/#{Awskeyring::VERSION}",
29
+ 'rubygems_mfa_required' => 'true',
29
30
  'source_code_uri' => "#{Awskeyring::HOMEPAGE}/tree/v#{Awskeyring::VERSION}",
30
31
  'wiki_uri' => "#{Awskeyring::HOMEPAGE}/wiki"
31
32
  }
@@ -1,5 +1,7 @@
1
1
  # frozen_string_literal: true
2
2
 
3
+ require 'base64'
4
+
3
5
  # Awskeyring Module,
4
6
  # gives you an interface to access keychains and items.
5
7
  module Awskeyring
@@ -27,7 +29,11 @@ module Awskeyring
27
29
  #
28
30
  # @param [String] aws_secret_access_key The aws_secret_access_key
29
31
  def self.secret_access_key(aws_secret_access_key)
30
- raise 'Secret Access Key is not 40 chars' if aws_secret_access_key.length != 40
32
+ begin
33
+ raise 'Invalid Secret Access Key' unless Base64.strict_decode64(aws_secret_access_key).length == 30
34
+ rescue ArgumentError
35
+ raise 'Invalid Secret Access Key'
36
+ end
31
37
 
32
38
  aws_secret_access_key
33
39
  end
@@ -6,7 +6,7 @@ require 'json'
6
6
  # Version const and query of latest.
7
7
  module Awskeyring
8
8
  # The Gem's version number
9
- VERSION = '1.9.2'
9
+ VERSION = '1.9.3'
10
10
  # The Gem's homepage
11
11
  HOMEPAGE = 'https://github.com/servian/awskeyring'
12
12
 
@@ -133,7 +133,7 @@ class AwskeyringCommand < Thor # rubocop:disable Metrics/ClassLength
133
133
  key: cred[:key],
134
134
  secret: cred[:secret],
135
135
  token: cred[:token],
136
- expiry: (expiry || Time.new + Awskeyring::Awsapi::ONE_HOUR).iso8601
136
+ expiry: (expiry || (Time.new + Awskeyring::Awsapi::ONE_HOUR)).iso8601
137
137
  )
138
138
  end
139
139
 
data/man/awskeyring.5 CHANGED
@@ -1,7 +1,7 @@
1
1
  .\" generated with Ronn/v0.7.3
2
2
  .\" http://github.com/rtomayko/ronn/tree/0.7.3
3
3
  .
4
- .TH "AWSKEYRING" "5" "September 2021" "" ""
4
+ .TH "AWSKEYRING" "5" "January 2022" "" ""
5
5
  .
6
6
  .SH "NAME"
7
7
  \fBAwskeyring\fR \- is a small tool to manage AWS account keys in the macOS Keychain
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: awskeyring
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.9.2
4
+ version: 1.9.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Tristan Morgan
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2021-09-13 00:00:00.000000000 Z
11
+ date: 2022-01-18 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: aws-sdk-iam
@@ -94,8 +94,9 @@ licenses:
94
94
  metadata:
95
95
  bug_tracker_uri: https://github.com/servian/awskeyring/issues
96
96
  changelog_uri: https://github.com/servian/awskeyring/blob/main/CHANGELOG.md
97
- documentation_uri: https://rubydoc.info/gems/awskeyring/1.9.2
98
- source_code_uri: https://github.com/servian/awskeyring/tree/v1.9.2
97
+ documentation_uri: https://rubydoc.info/gems/awskeyring/1.9.3
98
+ rubygems_mfa_required: 'true'
99
+ source_code_uri: https://github.com/servian/awskeyring/tree/v1.9.3
99
100
  wiki_uri: https://github.com/servian/awskeyring/wiki
100
101
  post_install_message:
101
102
  rdoc_options: []
@@ -112,7 +113,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
112
113
  - !ruby/object:Gem::Version
113
114
  version: '0'
114
115
  requirements: []
115
- rubygems_version: 3.0.3
116
+ rubygems_version: 3.0.3.1
116
117
  signing_key:
117
118
  specification_version: 4
118
119
  summary: Manages AWS credentials in the macOS keychain