pwn 0.5.73 → 0.5.74

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: 6d22687be26dd2efb462c08c0fd075f9d2b907a050e58ee01e765892e5654a01
4
- data.tar.gz: 76ecf4144fccc062c20143cdaa773db2f5fad30bc2f63e6bca3a84e9c8421f76
3
+ metadata.gz: f8244b3562d6991200f237682bd63db742e7ab462d703a738f1423ef825216fa
4
+ data.tar.gz: dfa1f26f8d89bbe27ed84c070ded24a7d178c547df024d9fe8928b62daee0ffa
5
5
  SHA512:
6
- metadata.gz: 0225e701ff060cbc35fa91038bf2a9603ea3596d355471a2c62b0c4ca08b645c45cf863d4e2f290bd2844d295ada836cfa1462a36f5da171961b3e22b00a0a2c
7
- data.tar.gz: f70688109e619bdb2e0070734dfe4f3aa2dd1a55f3a2b2250fab45777d6a3bd30e2e4e7538bb5f6721a5a8dd5d2a3b7d743d08249d38296f5e2e9b3e79c0f036
6
+ metadata.gz: 2e1124a3371db6662ce9bc4ea1f9cc7b5cb3bd099dc8a5e912b104b5426db3fa1e8bc6d4b19ab6e5f71bb75ca8cb005e8521a2c5d490e2c9467b8e18f424f817
7
+ data.tar.gz: ba806a5a2949bf02c43ffc67b2e348f6c84093d289d21ecdf0ff172b9dfcb1d5cfb3ab4a7810b7a8bb3306385f0f5de8f5fb4c936d7ba7baebb499da876d18a7
data/README.md CHANGED
@@ -37,7 +37,7 @@ $ cd /opt/pwn
37
37
  $ ./install.sh
38
38
  $ ./install.sh ruby-gem
39
39
  $ pwn
40
- pwn[v0.5.73]:001 >>> PWN.help
40
+ pwn[v0.5.74]:001 >>> PWN.help
41
41
  ```
42
42
 
43
43
  [![Installing the pwn Security Automation Framework](https://raw.githubusercontent.com/0dayInc/pwn/master/documentation/pwn_install.png)](https://youtu.be/G7iLUY4FzsI)
@@ -52,7 +52,7 @@ $ rvm use ruby-3.3.0@pwn
52
52
  $ gem uninstall --all --executables pwn
53
53
  $ gem install --verbose pwn
54
54
  $ pwn
55
- pwn[v0.5.73]:001 >>> PWN.help
55
+ pwn[v0.5.74]:001 >>> PWN.help
56
56
  ```
57
57
 
58
58
  If you're using a multi-user install of RVM do:
@@ -62,7 +62,7 @@ $ rvm use ruby-3.3.0@pwn
62
62
  $ rvmsudo gem uninstall --all --executables pwn
63
63
  $ rvmsudo gem install --verbose pwn
64
64
  $ pwn
65
- pwn[v0.5.73]:001 >>> PWN.help
65
+ pwn[v0.5.74]:001 >>> PWN.help
66
66
  ```
67
67
 
68
68
  PWN periodically upgrades to the latest version of Ruby which is reflected in `/opt/pwn/.ruby-version`. The easiest way to upgrade to the latest version of Ruby from a previous PWN installation is to run the following script:
@@ -67,10 +67,8 @@ module PWN
67
67
 
68
68
  public_class_method def self.decrypt(opts = {})
69
69
  file = opts[:file].to_s.scrub if File.exist?(opts[:file].to_s.scrub)
70
- key = opts[:key]
71
- iv = opts[:iv]
72
-
73
- raise 'ERROR: key and iv parameters are required.' if key.nil? || iv.nil?
70
+ key = opts[:key] ||= PWN::Plugins::AuthenticationHelper.mask_password(prompt: 'Key')
71
+ iv = opts[:iv] ||= PWN::Plugins::AuthenticationHelper.mask_password(prompt: 'IV')
74
72
 
75
73
  is_encrypted = file_encrypted?(file: file)
76
74
  raise 'ERROR: File is not encrypted.' unless is_encrypted
@@ -84,6 +82,8 @@ module PWN
84
82
  plain_text = cipher.update(b64_decoded_file_contents) + cipher.final
85
83
 
86
84
  File.write(file, plain_text)
85
+ rescue ArrgumentError
86
+ false
87
87
  rescue StandardError => e
88
88
  raise e
89
89
  end
data/lib/pwn/version.rb CHANGED
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module PWN
4
- VERSION = '0.5.73'
4
+ VERSION = '0.5.74'
5
5
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: pwn
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.5.73
4
+ version: 0.5.74
5
5
  platform: ruby
6
6
  authors:
7
7
  - 0day Inc.