ctf-party 1.2.0 → 1.2.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/LICENSE.txt +2 -1
- data/lib/ctf_party/base64.rb +4 -3
- data/lib/ctf_party/flag.rb +0 -4
- data/lib/ctf_party/hex.rb +3 -2
- data/lib/ctf_party/version.rb +1 -1
- metadata +12 -12
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 3320dd66b3b305ed07cce2d8e9059f83f5c6c65b763401223af57d157bcbffb4
|
4
|
+
data.tar.gz: 4ae59e35eb39beb3641cfa9e5d22609f93e18b9540884876d3982ab4ab7cc97e
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 72c0b492360e7a52af7e3abe000c275accc183f28ea3ca9753fdc92e43258abc45967cb0aa79448ebdcbd118d65aba33435c37354ba0595a0f3459d591b4d37b
|
7
|
+
data.tar.gz: '0907211c7da78180930cfb8243169ae4bb3f63515fa3fd1538b576fa11f34e3278796c757dd494b6f206bca0b6dd09bda2e0308b7e3f42713cf40410e279e3b2'
|
data/LICENSE.txt
CHANGED
@@ -1,6 +1,7 @@
|
|
1
1
|
The MIT License (MIT)
|
2
2
|
|
3
|
-
Copyright (c)
|
3
|
+
Copyright (c) 2020-2020 Alexandre ZANNI
|
4
|
+
Copyright (c) 2019-2020 Alexandre ZANNI at Orange Cyberdefense
|
4
5
|
|
5
6
|
Permission is hereby granted, free of charge, to any person obtaining a copy
|
6
7
|
of this software and associated documentation files (the "Software"), to deal
|
data/lib/ctf_party/base64.rb
CHANGED
@@ -74,14 +74,15 @@ class String
|
|
74
74
|
(?:[a-zA-Z0-9+/]{2}==)|(?:[a-zA-Z0-9+/]{1}===))\Z}xn
|
75
75
|
reg3 = /\A(?:[a-zA-Z0-9\-_]{4})*(?:|(?:[a-zA-Z0-9\-_]{3}=)|
|
76
76
|
(?:[a-zA-Z0-9\-_]{2}==)|(?:[a-zA-Z0-9\-_]{1}===))\Z/xn
|
77
|
-
|
77
|
+
case opts[:mode]
|
78
|
+
when :strict, :rfc4648
|
78
79
|
b64 = true if reg1.match?(self)
|
79
|
-
|
80
|
+
when :rfc2045
|
80
81
|
b64 = true
|
81
82
|
split("\n").each do |s|
|
82
83
|
b64 = false unless reg1.match?(s)
|
83
84
|
end
|
84
|
-
|
85
|
+
when :urlsafe
|
85
86
|
b64 = true if reg3.match?(self)
|
86
87
|
else
|
87
88
|
raise ArgumentError 'Wrong mode'
|
data/lib/ctf_party/flag.rb
CHANGED
@@ -16,8 +16,6 @@ class String
|
|
16
16
|
@@flag
|
17
17
|
end
|
18
18
|
|
19
|
-
# rubocop:disable Metrics/LineLength
|
20
|
-
|
21
19
|
# Update the flag configuration.
|
22
20
|
# @param hash [Hash] flag configuration
|
23
21
|
# @option hash [String] :prefix prefix of the flag. Default: none.
|
@@ -40,8 +38,6 @@ class String
|
|
40
38
|
@@flag.merge!(hash)
|
41
39
|
end
|
42
40
|
|
43
|
-
# rubocop:enable Metrics/LineLength
|
44
|
-
|
45
41
|
# Format the current string into the configured flag format. See {.flag=}
|
46
42
|
# example.
|
47
43
|
# @return [String] the format flag.
|
data/lib/ctf_party/hex.rb
CHANGED
@@ -78,9 +78,10 @@ class String
|
|
78
78
|
opts[:nibble] ||= :high
|
79
79
|
# convert
|
80
80
|
out = ''
|
81
|
-
|
81
|
+
case opts[:nibble]
|
82
|
+
when :high
|
82
83
|
out = unpack1('H*')
|
83
|
-
|
84
|
+
when :low
|
84
85
|
out = unpack1('h*')
|
85
86
|
end
|
86
87
|
# char case management
|
data/lib/ctf_party/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: ctf-party
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.2.
|
4
|
+
version: 1.2.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Alexandre ZANNI
|
8
|
-
autorequire:
|
8
|
+
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2020-
|
11
|
+
date: 2020-07-13 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|
@@ -140,17 +140,17 @@ files:
|
|
140
140
|
- lib/ctf_party/hex.rb
|
141
141
|
- lib/ctf_party/rot.rb
|
142
142
|
- lib/ctf_party/version.rb
|
143
|
-
homepage: https://
|
143
|
+
homepage: https://noraj.github.io/ctf-party/
|
144
144
|
licenses:
|
145
145
|
- MIT
|
146
146
|
metadata:
|
147
147
|
yard.run: yard
|
148
|
-
bug_tracker_uri: https://github.com/
|
149
|
-
changelog_uri: https://github.com/
|
150
|
-
documentation_uri: https://
|
151
|
-
homepage_uri: https://
|
152
|
-
source_code_uri: https://github.com/
|
153
|
-
post_install_message:
|
148
|
+
bug_tracker_uri: https://github.com/noraj/ctf-party/issues
|
149
|
+
changelog_uri: https://github.com/noraj/ctf-party/blob/master/docs/CHANGELOG.md
|
150
|
+
documentation_uri: https://noraj.github.io/ctf-party/
|
151
|
+
homepage_uri: https://noraj.github.io/ctf-party/
|
152
|
+
source_code_uri: https://github.com/noraj/ctf-party/
|
153
|
+
post_install_message:
|
154
154
|
rdoc_options: []
|
155
155
|
require_paths:
|
156
156
|
- lib
|
@@ -158,7 +158,7 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
158
158
|
requirements:
|
159
159
|
- - "~>"
|
160
160
|
- !ruby/object:Gem::Version
|
161
|
-
version: '2.
|
161
|
+
version: '2.7'
|
162
162
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
163
163
|
requirements:
|
164
164
|
- - ">="
|
@@ -166,7 +166,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
166
166
|
version: '0'
|
167
167
|
requirements: []
|
168
168
|
rubygems_version: 3.1.2
|
169
|
-
signing_key:
|
169
|
+
signing_key:
|
170
170
|
specification_version: 4
|
171
171
|
summary: A library to enhance and speed up script/exploit writing for CTF players
|
172
172
|
test_files: []
|