injection_vulnerability_library 0.0.3 → 0.1.2

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
- SHA1:
3
- metadata.gz: b17830e0f0cf440ed188575b511dd025cb343b61
4
- data.tar.gz: 9f0993cb334b34e72a596e24843887f8d7935cb1
2
+ SHA256:
3
+ metadata.gz: 0017d98b59ef913219197168b7cbdecaf1fc1ce410141c604e8a58c4657f8c73
4
+ data.tar.gz: 2022024797e720ea71c77c197a581ababfad92d675c13a2cb174e9137af4b5d2
5
5
  SHA512:
6
- metadata.gz: 42e2ac7849714e68d60da1ab385e16553db8cccf1baafb9a74d0fa88988220e4ffed7a32be2985626c6e03134510cba71118e32f019d2e2999d9edfa9b14da65
7
- data.tar.gz: b0e1506ad1dd9b4ea4b99f3a51cafbae5070abe9d9fb6c989a3860b54efec84a7ef77acdf5338cb6ba84e8e42d608f1a849c107a9206f29b3a20ad2c4ead9fa9
6
+ metadata.gz: 2a8de47ba8946464173c7119eb9c47d9a56c231ad64e75471de4ad48e54b0262759af726546ae6a590dc67e045e0f8b6d6e4831918c07c0cc6a23fbaad7aecf3
7
+ data.tar.gz: 760b69c786576a03642202076af3a5c185cbdf745b902611b4c4c526f908f3ce9ace5fcf1a5e55dde96c7c1201f3e55f59b7b396c0b5574e15fde770d916dbda
@@ -0,0 +1,15 @@
1
+ # Set update schedule for GitHub Actions
2
+
3
+ version: 2
4
+ updates:
5
+
6
+ - package-ecosystem: "github-actions"
7
+ directory: "/"
8
+ schedule:
9
+ # Check for updates to GitHub Actions every weekday
10
+ interval: "daily"
11
+
12
+ - package-ecosystem: "bundler"
13
+ directory: '/'
14
+ schedule:
15
+ interval: 'daily'
@@ -0,0 +1,39 @@
1
+ name: Ruby Gem
2
+
3
+ on:
4
+ workflow_dispatch
5
+
6
+ jobs:
7
+ build:
8
+ name: Build + Publish
9
+ runs-on: ubuntu-latest
10
+
11
+ steps:
12
+ - uses: actions/checkout@v2
13
+ - name: Set up Ruby 2.6
14
+ uses: actions/setup-ruby@v1
15
+ with:
16
+ ruby-version: 2.6.x
17
+
18
+ - name: Publish to RubyGems
19
+ run: |
20
+ mkdir -p $HOME/.gem
21
+ touch $HOME/.gem/credentials
22
+ chmod 0600 $HOME/.gem/credentials
23
+ printf -- "---\n:rubygems: ${GEM_HOST_API_KEY}\n" > $HOME/.gem/credentials
24
+ gem build *.gemspec
25
+ gem push --KEY rubygems --host https://rubygems.org *.gem
26
+ env:
27
+ GEM_HOST_API_KEY: "${{secrets.RUBYGEMS_AUTH_TOKEN}}"
28
+
29
+ - name: Publish to GPR
30
+ run: |
31
+ mkdir -p $HOME/.gem
32
+ touch $HOME/.gem/credentials
33
+ chmod 0600 $HOME/.gem/credentials
34
+ printf -- "---\n:github: ${GEM_HOST_API_KEY}\n" > $HOME/.gem/credentials
35
+ gem build *.gemspec
36
+ gem push --KEY github --host https://rubygems.pkg.github.com/${OWNER} *.gem
37
+ env:
38
+ GEM_HOST_API_KEY: "Bearer ${{secrets.GITHUB_TOKEN}}"
39
+ OWNER: ${{ github.repository_owner }}
@@ -0,0 +1,31 @@
1
+ # This workflow uses actions that are not certified by GitHub.
2
+ # They are provided by a third-party and are governed by
3
+ # separate terms of service, privacy policy, and support
4
+ # documentation.
5
+ # This workflow will download a prebuilt Ruby version, install dependencies and run tests with Rake
6
+ # For more information see: https://github.com/marketplace/actions/setup-ruby-jruby-and-truffleruby
7
+
8
+ name: Test
9
+
10
+ on: [push, pull_request]
11
+
12
+ jobs:
13
+ test:
14
+
15
+ runs-on: ubuntu-latest
16
+
17
+ steps:
18
+ - uses: actions/checkout@v2
19
+ - name: Set up Ruby
20
+ # To automatically get bug fixes and new Ruby versions for ruby/setup-ruby,
21
+ # change this to (see https://github.com/ruby/setup-ruby#versioning):
22
+ # uses: ruby/setup-ruby@v1
23
+ uses: ruby/setup-ruby@a195098f6b1e9074390215a49c1c14e82151a289
24
+ with:
25
+ ruby-version: 2.6
26
+ - name: Install dependencies
27
+ run: bundle install
28
+ - name: Rubocop
29
+ run: bundle exec rake rubocop
30
+ - name: Run tests
31
+ run: bundle exec rake spec
@@ -0,0 +1,9 @@
1
+ AllCops:
2
+ Exclude:
3
+ - 'injection_vulnerability_library.gemspec'
4
+ - 'bin/console'
5
+ - 'Gemfile'
6
+ - 'Rakefile'
7
+
8
+ Style/FrozenStringLiteralComment:
9
+ Enabled: false
data/README.md CHANGED
@@ -1,6 +1,6 @@
1
1
  # Injection::Vulnerability::Library
2
2
  [![Gem Version](https://badge.fury.io/rb/injection_vulnerability_library.svg)](https://badge.fury.io/rb/injection_vulnerability_library)
3
- [![Build Status](https://travis-ci.org/araneforseti/injection_vulnerability_library.svg?branch=master)](https://travis-ci.org/araneforseti/injection_vulnerability_library)
3
+ [![Build Status](https://github.com/araneforseti/injection_vulnerability_library/workflows/Test/badge.svg)](https://github.com/araneforseti/injection_vulnerability_library/actions?query=workflow%3ATest+branch%3Amaster)
4
4
 
5
5
  Gem for integrating with automated tests to check for potential injection problems within codebases
6
6
 
data/Rakefile CHANGED
@@ -1,6 +1,11 @@
1
1
  require "bundler/gem_tasks"
2
2
  require "rspec/core/rake_task"
3
+ require 'rubocop/rake_task'
4
+
5
+ RuboCop::RakeTask.new(:rubocop) do |t|
6
+ t.options = ['--display-cop-names']
7
+ end
3
8
 
4
9
  RSpec::Core::RakeTask.new(:spec)
5
10
 
6
- task :default => :spec
11
+ task :default => [:rubocop, :spec]
@@ -14,23 +14,15 @@ Gem::Specification.new do |spec|
14
14
  spec.homepage = "https://github.com/araneforseti/injection_vulnerability_library"
15
15
  spec.license = "MIT"
16
16
 
17
- # Prevent pushing this gem to RubyGems.org. To allow pushes either set the 'allowed_push_host'
18
- # to allow pushing to a single host or delete this section to allow pushing to any host.
19
- if spec.respond_to?(:metadata)
20
- spec.metadata['allowed_push_host'] = 'https://rubygems.org/'
21
- else
22
- raise "RubyGems 2.0 or newer is required to protect against " \
23
- "public gem pushes."
24
- end
25
-
26
17
  spec.files = `git ls-files -z`.split("\x0").reject do |f|
27
18
  f.match(%r{^(test|spec|features)/})
28
19
  end
29
- spec.bindir = "exe"
20
+ spec.bindir = 'exe'
30
21
  spec.executables = spec.files.grep(%r{^exe/}) { |f| File.basename(f) }
31
- spec.require_paths = ["lib"]
22
+ spec.require_paths = ['lib']
32
23
 
33
- spec.add_development_dependency "bundler", "~> 1.16"
34
- spec.add_development_dependency "rake", "~> 10.0"
35
- spec.add_development_dependency "rspec", "~> 3.0"
24
+ spec.add_development_dependency 'bundler', '~> 2.1.4'
25
+ spec.add_development_dependency 'rake', '~> 13.0'
26
+ spec.add_development_dependency 'rspec', '~> 3.0'
27
+ spec.add_development_dependency 'rubocop', '~> 0.93.0'
36
28
  end
@@ -1,6 +1,7 @@
1
- require "injection_vulnerability_library/version"
2
- require "injection_vulnerability_library/sql/sql"
1
+ require 'injection_vulnerability_library/version'
2
+ require 'injection_vulnerability_library/sql/sql'
3
3
 
4
+ # Vulnerability library providing basic list for use with tests and other things
4
5
  module InjectionVulnerabilityLibrary
5
6
  def self.sql_vulnerabilities
6
7
  InjectionVulnerabilityLibrary::Sql.vulnerabilities
@@ -1,6 +1,7 @@
1
1
  module InjectionVulnerabilityLibrary
2
+ # Module for the SQL vulnerabilities
2
3
  module Sql
3
- SQL_PATH = File.expand_path('../potential_vulnerabilities.txt', __FILE__)
4
+ SQL_PATH = File.expand_path('potential_vulnerabilities.txt', __dir__)
4
5
 
5
6
  def self.vulnerabilities
6
7
  File.readlines(SQL_PATH).map(&:chomp)
@@ -1,3 +1,3 @@
1
1
  module InjectionVulnerabilityLibrary
2
- VERSION = "0.0.3"
2
+ VERSION = '0.1.2'.freeze
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: injection_vulnerability_library
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.3
4
+ version: 0.1.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - arane
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2018-05-25 00:00:00.000000000 Z
11
+ date: 2020-10-08 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler
@@ -16,28 +16,28 @@ dependencies:
16
16
  requirements:
17
17
  - - "~>"
18
18
  - !ruby/object:Gem::Version
19
- version: '1.16'
19
+ version: 2.1.4
20
20
  type: :development
21
21
  prerelease: false
22
22
  version_requirements: !ruby/object:Gem::Requirement
23
23
  requirements:
24
24
  - - "~>"
25
25
  - !ruby/object:Gem::Version
26
- version: '1.16'
26
+ version: 2.1.4
27
27
  - !ruby/object:Gem::Dependency
28
28
  name: rake
29
29
  requirement: !ruby/object:Gem::Requirement
30
30
  requirements:
31
31
  - - "~>"
32
32
  - !ruby/object:Gem::Version
33
- version: '10.0'
33
+ version: '13.0'
34
34
  type: :development
35
35
  prerelease: false
36
36
  version_requirements: !ruby/object:Gem::Requirement
37
37
  requirements:
38
38
  - - "~>"
39
39
  - !ruby/object:Gem::Version
40
- version: '10.0'
40
+ version: '13.0'
41
41
  - !ruby/object:Gem::Dependency
42
42
  name: rspec
43
43
  requirement: !ruby/object:Gem::Requirement
@@ -52,6 +52,20 @@ dependencies:
52
52
  - - "~>"
53
53
  - !ruby/object:Gem::Version
54
54
  version: '3.0'
55
+ - !ruby/object:Gem::Dependency
56
+ name: rubocop
57
+ requirement: !ruby/object:Gem::Requirement
58
+ requirements:
59
+ - - "~>"
60
+ - !ruby/object:Gem::Version
61
+ version: 0.93.0
62
+ type: :development
63
+ prerelease: false
64
+ version_requirements: !ruby/object:Gem::Requirement
65
+ requirements:
66
+ - - "~>"
67
+ - !ruby/object:Gem::Version
68
+ version: 0.93.0
55
69
  description: Library for generating injection inputs for various databases and languages
56
70
  email:
57
71
  - arane9@gmail.com
@@ -59,8 +73,11 @@ executables: []
59
73
  extensions: []
60
74
  extra_rdoc_files: []
61
75
  files:
76
+ - ".github/dependabot.yml"
77
+ - ".github/workflows/gem-push.yml"
78
+ - ".github/workflows/test.yml"
62
79
  - ".gitignore"
63
- - ".travis.yml"
80
+ - ".rubocop.yml"
64
81
  - CODE_OF_CONDUCT.md
65
82
  - Gemfile
66
83
  - LICENSE
@@ -78,8 +95,7 @@ files:
78
95
  homepage: https://github.com/araneforseti/injection_vulnerability_library
79
96
  licenses:
80
97
  - MIT
81
- metadata:
82
- allowed_push_host: https://rubygems.org/
98
+ metadata: {}
83
99
  post_install_message:
84
100
  rdoc_options: []
85
101
  require_paths:
@@ -95,8 +111,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
95
111
  - !ruby/object:Gem::Version
96
112
  version: '0'
97
113
  requirements: []
98
- rubyforge_project:
99
- rubygems_version: 2.6.12
114
+ rubygems_version: 3.0.3
100
115
  signing_key:
101
116
  specification_version: 4
102
117
  summary: Library for generating injection inputs
@@ -1,6 +0,0 @@
1
- language: ruby
2
-
3
- rvm:
4
- - 2.2.1
5
-
6
- before_install: gem install bundler -v 1.13.6