ndr_dev_support 7.3.6 → 7.3.8

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.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 589fcf9c03c62ecbeecffbfe9020e87a7a1d5deec59506eef8129592504ae1c7
4
- data.tar.gz: 8e99fb0d7c43f670c8684fdd11e570df00d69895e18f16194dd70a4f1afd6047
3
+ metadata.gz: bceb17903631013fce3438cf82287cab07bf06575f109345676e45e5e4df28b3
4
+ data.tar.gz: 0e6f918d2614fbb08f8540b3329314d31dc81533994a68bb9429ab747e7e8717
5
5
  SHA512:
6
- metadata.gz: 768b8c51a8653ce8866a322fcb2bcf7548bb42a4ce8d133b5e397f961bb143c0b8f2820eb9e5a67d211bb6304d125359ea8f210456604cc4d1d0e62374c50545
7
- data.tar.gz: ff1eb7652b61497650afd78d9fb9bd0a8f366b6bcc972240f6c07f6e4529015e0fede07f4787eb965acd848348cbb966ddcd17c1566cc0fb57b9172cc10141f2
6
+ metadata.gz: f4940867633068addac74dc3e357f4c9eafd361489c52616c044b79a8d3d7a29e01afd1a4b658f6a158cbb9e22a938823ac2dbc191637d8de0bec64a46ae2156
7
+ data.tar.gz: ed344310df1814ff4304a13514c733a09543e4053d944bc56af4f6533654d6e0a7f7403076951d23916292f01a4f387d3c521bf1371ea874eefb422f959c9340
data/CHANGELOG.md CHANGED
@@ -1,5 +1,15 @@
1
1
  ## [Unreleased]
2
- *no unreleased changes*
2
+ * no unreleased changes
3
+
4
+ ## 7.3.8 / 2026-09-16
5
+ ### Fixed
6
+ * Do not include macOS extended attributes in rbenv tar files
7
+ * Capistrano: validate YAML files when deploying application secrets
8
+
9
+ ## 7.3.7 / 2026-06-29
10
+ ### Fixed
11
+ * Drop support for Ruby 3.1 and 3.2, Rails 7.0
12
+ * Capistrano: deployment should continue even if cleanup cannot delete files
3
13
 
4
14
  ## 7.3.6 / 2026-01-13
5
15
  ### Added
data/SECURITY.md ADDED
@@ -0,0 +1,35 @@
1
+ # Security
2
+
3
+ NHS England takes security and the protection of private data extremely seriously. If you believe you have found a vulnerability or other issue which has compromised or could compromise the security of any of our systems and/or private data managed by our systems, please do not hesitate to contact us using the methods outlined below.
4
+
5
+ ## Table of Contents
6
+
7
+ - [Security](#security)
8
+ - [Table of Contents](#table-of-contents)
9
+ - [Reporting a vulnerability](#reporting-a-vulnerability)
10
+ - [Email](#email)
11
+ - [NCSC](#ncsc)
12
+ - [General Security Enquiries](#general-security-enquiries)
13
+
14
+ ## Reporting a vulnerability
15
+
16
+ Please note, email is our preferred method of receiving reports.
17
+
18
+ ### Email
19
+
20
+ If you wish to notify us of a vulnerability via email, please include detailed information on the nature of the vulnerability and any steps required to reproduce it.
21
+
22
+ You can reach us at:
23
+
24
+ - [Brian.Shand@nhs.net](mailto:Brian.Shand@nhs.net)
25
+ - [cybersecurity@nhs.net](mailto:cybersecurity@nhs.net)
26
+
27
+ ### NCSC
28
+
29
+ You can send your report to the National Cyber Security Centre, who will assess your report and pass it on to NHS England if necessary.
30
+
31
+ You can report vulnerabilities here: [https://www.ncsc.gov.uk/information/vulnerability-reporting](https://www.ncsc.gov.uk/information/vulnerability-reporting)
32
+
33
+ ## General Security Enquiries
34
+
35
+ If you have general enquiries regarding our cybersecurity, please reach out to us at [cybersecurity@nhs.net](mailto:cybersecurity@nhs.net)
@@ -1,4 +1,5 @@
1
1
  require 'tmpdir'
2
+ require 'yaml'
2
3
 
3
4
  # Add a git or svn secrets respository for ndr_dev_support:deploy_secrets
4
5
  def add_secrets_repo(name:, url:, scm:, branch: nil)
@@ -114,6 +115,18 @@ Capistrano::Configuration.instance(:must_exist).load do
114
115
 
115
116
  raise 'Error: cannot export secrets files: aborting' unless ok
116
117
 
118
+ # Ensure YAML files have valid syntax
119
+ if secret[:shared_dest] =~ /[.]ya?ml\z/
120
+ begin
121
+ YAML.load_file(File.join(secret_dir, secret[:shared_dest]))
122
+ rescue StandardError, Psych::SyntaxError => e # rubocop:disable Lint/ShadowedException
123
+ Capistrano::CLI.ui.say <<~MSG
124
+ YAML Error loading file #{repo_root}/#{secret[:repo_path]}: #{e.class}: #{e}
125
+ #{e.backtrace.join("\n")}
126
+ MSG
127
+ raise "Error: invalid YAML syntax in file #{repo_root}/#{secret[:repo_path]}"
128
+ end
129
+ end
117
130
  secret[:digest] = Digest::SHA256.file(dest_fname).hexdigest
118
131
  end
119
132
 
@@ -12,7 +12,7 @@ Capistrano::Configuration.instance(:must_exist).load do
12
12
  $ git clone https://github.com/rbenv/ruby-build.git clone_rbenv/.rbenv/plugins/ruby-build
13
13
  $ mkdir clone_rbenv/.rbenv/cache
14
14
  $ (cd clone_rbenv/.rbenv/cache; curl -O https://cache.ruby-lang.org/pub/ruby/3.1/ruby-3.1.6.tar.gz)
15
- $ (cd clone_rbenv; rm -f ../rbenv.tar.gz; tar czf ../rbenv.tar.gz .rbenv)
15
+ $ (cd clone_rbenv; rm -f ../rbenv.tar.gz; COPYFILE_DISABLE=1 tar czf ../rbenv.tar.gz .rbenv)
16
16
  $ rm -rf clone_rbenv
17
17
  $ scp -p rbenv.tar.gz app-server:/opt/rbenv.tar.gz
18
18
 
@@ -21,12 +21,12 @@ Capistrano::Configuration.instance(:must_exist).load do
21
21
  $ mkdir clone_rbenv
22
22
  $ git clone https://github.com/rbenv/rbenv.git clone_rbenv/.rbenv
23
23
  $ mkdir -p vendor/rbenv; rm -f vendor/rbenv/rbenv.tar.gz
24
- $ tar czf vendor/rbenv/rbenv.tar.gz -C clone_rbenv .rbenv
24
+ $ COPYFILE_DISABLE=1 tar czf vendor/rbenv/rbenv.tar.gz -C clone_rbenv .rbenv
25
25
  $ rm -rf clone_rbenv
26
26
  $ mkdir clone_ruby-build
27
27
  $ git clone https://github.com/rbenv/ruby-build.git clone_ruby-build/ruby-build
28
28
  $ mkdir -p vendor/rbenv/cache; rm -f vendor/rbenv/ruby-build.tar.gz
29
- $ tar czf vendor/rbenv/ruby-build.tar.gz -C clone_ruby-build ruby-build
29
+ $ COPYFILE_DISABLE=1 tar czf vendor/rbenv/ruby-build.tar.gz -C clone_ruby-build ruby-build
30
30
  $ rm -rf clone_ruby-build
31
31
  $ (cd vendor/rbenv/cache; curl -O https://cache.ruby-lang.org/pub/ruby/3.2/ruby-3.2.6.tar.gz)
32
32
  $ git add vendor/rbenv/{rbenv,ruby-build}.tar.gz vendor/rbenv/cache/*
@@ -5,5 +5,15 @@ Capistrano::Configuration.instance(:must_exist).load do
5
5
  # The tmp/ directory should be shared, so this affects all prior deployments
6
6
  run "touch #{shared_path}/tmp/restart.txt"
7
7
  end
8
+
9
+ desc <<~DESC
10
+ Clean up old releases. Overrides the default deploy:cleanup but without blocking \
11
+ subsequent tasks if cleanup fails (e.g. because of locked files or permissions issues).
12
+ DESC
13
+ task :cleanup, except: { no_release: true } do
14
+ count = fetch(:keep_releases, 5).to_i
15
+ try_sudo "ls -1dt #{releases_path}/* | tail -n +#{count + 1} | #{try_sudo} xargs -r rm -rf " \
16
+ "|| echo 'cap deploy:cleanup failed - continuing, but check permissions.' >&2"
17
+ end
8
18
  end
9
19
  end
@@ -2,5 +2,5 @@
2
2
  # This defines the NdrDevSupport version. If you change it, rebuild and commit the gem.
3
3
  # Use "rake build" to build the gem, see rake -T for all bundler rake tasks (and our own).
4
4
  module NdrDevSupport
5
- VERSION = '7.3.6'
5
+ VERSION = '7.3.8'
6
6
  end
@@ -13,14 +13,14 @@ Gem::Specification.new do |spec|
13
13
  spec.license = 'MIT'
14
14
 
15
15
  gem_files = %w[CHANGELOG.md CODE_OF_CONDUCT.md LICENSE.txt README.md
16
- config lib ndr_dev_support.gemspec]
16
+ SECURITY.md config lib ndr_dev_support.gemspec]
17
17
  spec.files = `git ls-files -z`.split("\x0").
18
18
  select { |f| gem_files.include?(f.split('/')[0]) }
19
19
  spec.bindir = 'exe'
20
20
  spec.executables = spec.files.grep(%r{^exe/}) { |f| File.basename(f) }
21
21
  spec.require_paths = ['lib']
22
22
 
23
- spec.required_ruby_version = '>= 3.1'
23
+ spec.required_ruby_version = '>= 3.3'
24
24
 
25
25
  spec.add_dependency 'pry'
26
26
 
@@ -39,12 +39,12 @@ Gem::Specification.new do |spec|
39
39
  # Integration test dependencies:
40
40
  spec.add_dependency 'capybara', '>= 3.34'
41
41
  spec.add_dependency 'capybara-screenshot'
42
- spec.add_dependency 'minitest', '~> 5.11'
42
+ spec.add_dependency 'minitest', '>= 5.11', '< 7.0'
43
43
  spec.add_dependency 'selenium-webdriver', '~> 4.8'
44
44
  spec.add_dependency 'show_me_the_cookies'
45
45
 
46
46
  # CI server dependencies:
47
- spec.add_dependency 'activesupport', '>= 7.0', '< 8.2'
47
+ spec.add_dependency 'activesupport', '>= 7.1', '< 8.2'
48
48
  spec.add_dependency 'brakeman', '>= 4.7.1'
49
49
  spec.add_dependency 'bundler-audit'
50
50
  spec.add_dependency 'github-linguist'
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: ndr_dev_support
3
3
  version: !ruby/object:Gem::Version
4
- version: 7.3.6
4
+ version: 7.3.8
5
5
  platform: ruby
6
6
  authors:
7
7
  - NCRS Development Team
@@ -167,16 +167,22 @@ dependencies:
167
167
  name: minitest
168
168
  requirement: !ruby/object:Gem::Requirement
169
169
  requirements:
170
- - - "~>"
170
+ - - ">="
171
171
  - !ruby/object:Gem::Version
172
172
  version: '5.11'
173
+ - - "<"
174
+ - !ruby/object:Gem::Version
175
+ version: '7.0'
173
176
  type: :runtime
174
177
  prerelease: false
175
178
  version_requirements: !ruby/object:Gem::Requirement
176
179
  requirements:
177
- - - "~>"
180
+ - - ">="
178
181
  - !ruby/object:Gem::Version
179
182
  version: '5.11'
183
+ - - "<"
184
+ - !ruby/object:Gem::Version
185
+ version: '7.0'
180
186
  - !ruby/object:Gem::Dependency
181
187
  name: selenium-webdriver
182
188
  requirement: !ruby/object:Gem::Requirement
@@ -211,7 +217,7 @@ dependencies:
211
217
  requirements:
212
218
  - - ">="
213
219
  - !ruby/object:Gem::Version
214
- version: '7.0'
220
+ version: '7.1'
215
221
  - - "<"
216
222
  - !ruby/object:Gem::Version
217
223
  version: '8.2'
@@ -221,7 +227,7 @@ dependencies:
221
227
  requirements:
222
228
  - - ">="
223
229
  - !ruby/object:Gem::Version
224
- version: '7.0'
230
+ version: '7.1'
225
231
  - - "<"
226
232
  - !ruby/object:Gem::Version
227
233
  version: '8.2'
@@ -403,6 +409,7 @@ files:
403
409
  - CODE_OF_CONDUCT.md
404
410
  - LICENSE.txt
405
411
  - README.md
412
+ - SECURITY.md
406
413
  - config/rubocop/ndr.yml
407
414
  - lib/minitest/rake_ci.rb
408
415
  - lib/minitest/rake_ci_plugin.rb
@@ -480,7 +487,7 @@ required_ruby_version: !ruby/object:Gem::Requirement
480
487
  requirements:
481
488
  - - ">="
482
489
  - !ruby/object:Gem::Version
483
- version: '3.1'
490
+ version: '3.3'
484
491
  required_rubygems_version: !ruby/object:Gem::Requirement
485
492
  requirements:
486
493
  - - ">="