saro-dat 4.6.1 → 4.7.0

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: b6d5127dce2e1d7ca632f94e2fa8d6b6a1434a37ab285bbf43dfc589282fccbb
4
- data.tar.gz: e26c938570bfe16eae48746935a541e6ed552653b302cf7d15c10b7304dbc0af
3
+ metadata.gz: 25c8c7483a38221ff8dcd28a15f2204d7989e04209cacc325520969512b770b6
4
+ data.tar.gz: 76f2bd87d950a109a415aad2db81f11288d18905980e675d68489060210bfafd
5
5
  SHA512:
6
- metadata.gz: bb31b09e921a1222111ae2a5ce992ef12e76ac9c776039ebb7f408deaf6255a026f7f25ee820bddc055bbbb9ad84c3e24b493a9e489d6082ceba16fdd9037115
7
- data.tar.gz: 0041f03e782e284867e46d744bf0d9360c6ff0f24bda8af74ae39dc396e0700bdd3b6fd85a22a618e9f9a3590f8632c7ba81c8f20d2848a365bea1105565acbb
6
+ metadata.gz: 9e554c14879ec3d95f5327bc0811450f9895db7afff5c3caf738fd1b17421342f1648519e223e87b3eaf19b70ca098aacac0a26f6d3a857a4693ea019537fb6f
7
+ data.tar.gz: 405373b0eb54bae1b1a7c7ab4e442fe634073db4773165033ab545c5be6546571d839daa8c2c8136f9dd3d9d838f8e3206bb226d1756c707b7a1b7b8eae985be
data/CHANGELOG.md ADDED
@@ -0,0 +1,18 @@
1
+ # Changelog
2
+
3
+ All notable changes to this project will be documented in this file.
4
+
5
+ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/).
6
+
7
+ ## [4.7.0] - 2026-08-29
8
+
9
+ ### Added
10
+
11
+ - Added `sync_or_raise`, connection and synchronization timeout options, and CMS v1 contract fixtures.
12
+
13
+ ### Changed
14
+
15
+ - Hardened strict CMS response parsing, state commits, and synchronization lifecycle handling.
16
+ - Made gem file selection deterministic and independent of a Git checkout.
17
+ - Kept the test dependency set compatible with the declared Ruby 2.7 runtime floor.
18
+ - Retained DAT wire-protocol and CMS v1 compatibility, including existing error codes and response-body behavior.
data/README.md CHANGED
@@ -4,6 +4,7 @@
4
4
  - [DAT Run Online](https://dat.saro.me)
5
5
  - [What is DAT](https://dat.saro.me/intro)
6
6
  - [Example](https://dat.saro.me/libs/gems-saro-dat)
7
+ - [AI Vibe Coding](https://dat.saro.me/ai-coding)
7
8
 
8
9
  ### Support Platform
9
10
  - [Rust](https://github.com/saro-lab/dat/tree/master/dat-rust)
@@ -41,58 +42,58 @@
41
42
  - [test_bench.rb](test/test_bench.rb)
42
43
  ```
43
44
  Performance Test (Plain, Secure)
44
- Plain: fCFP97qkmv2cGlQ3GVUpcj6th1TBPNxAoLGiN7XC3XlnQdN1xs4U6qZOYkfkPYcqbXSHCIabTzH8kFI9uY062mqKhjXmy4D8Os4B
45
- Secure: 9wNnNCLvhuAfgvbcjNLXdKY9qXTqhIHBhgc62B7EgeH7fcDWOmJyah8zH0XcZhmgiDPJw4zTay7ArYosxR9NObjN0YWtKjQDrFme
45
+ Plain: JViHXwUHzJOm76bJjfkWTokM7h9dF4eFqXGWneOVbEt8OYXwEI9FEPoYlCSB33j8nNZCaj3rqFP8iy35GZJJAxNweHlJoVSItKog
46
+ Secure: zNnyO1umoZ7wXf2VyQVlLLmzVl4aHoDmR5pIlS8UBkPyO03wiOdDnrU2xNUM12qszw7tWsOv9Ip4fuePQSJoCptZuwWBElzOVdZT
46
47
 
47
48
  --- Multi-Thread ---
48
- HMAC-SHA256-MFS IV-AES128-GCM Issue * 10000 : 150ms
49
- HMAC-SHA256-MFS IV-AES128-GCM Parse * 10000 : 152ms
50
- HMAC-SHA256-MFS IV-AES256-GCM Issue * 10000 : 138ms
51
- HMAC-SHA256-MFS IV-AES256-GCM Parse * 10000 : 162ms
52
- HMAC-SHA384-MFS IV-AES128-GCM Issue * 10000 : 130ms
53
- HMAC-SHA384-MFS IV-AES128-GCM Parse * 10000 : 145ms
54
- HMAC-SHA384-MFS IV-AES256-GCM Issue * 10000 : 132ms
55
- HMAC-SHA384-MFS IV-AES256-GCM Parse * 10000 : 165ms
49
+ HMAC-SHA256-MFS IV-AES128-GCM Issue * 10000 : 122ms
50
+ HMAC-SHA256-MFS IV-AES128-GCM Parse * 10000 : 129ms
51
+ HMAC-SHA256-MFS IV-AES256-GCM Issue * 10000 : 116ms
52
+ HMAC-SHA256-MFS IV-AES256-GCM Parse * 10000 : 131ms
53
+ HMAC-SHA384-MFS IV-AES128-GCM Issue * 10000 : 116ms
54
+ HMAC-SHA384-MFS IV-AES128-GCM Parse * 10000 : 141ms
55
+ HMAC-SHA384-MFS IV-AES256-GCM Issue * 10000 : 121ms
56
+ HMAC-SHA384-MFS IV-AES256-GCM Parse * 10000 : 145ms
56
57
  HMAC-SHA512-MFS IV-AES128-GCM Issue * 10000 : 130ms
57
- HMAC-SHA512-MFS IV-AES128-GCM Parse * 10000 : 149ms
58
- HMAC-SHA512-MFS IV-AES256-GCM Issue * 10000 : 130ms
59
- HMAC-SHA512-MFS IV-AES256-GCM Parse * 10000 : 150ms
60
- ECDSA-P256 IV-AES128-GCM Issue * 10000 : 170ms
61
- ECDSA-P256 IV-AES128-GCM Parse * 10000 : 189ms
62
- ECDSA-P256 IV-AES256-GCM Issue * 10000 : 155ms
63
- ECDSA-P256 IV-AES256-GCM Parse * 10000 : 194ms
64
- ECDSA-P384 IV-AES128-GCM Issue * 10000 : 339ms
65
- ECDSA-P384 IV-AES128-GCM Parse * 10000 : 441ms
66
- ECDSA-P384 IV-AES256-GCM Issue * 10000 : 320ms
67
- ECDSA-P384 IV-AES256-GCM Parse * 10000 : 490ms
68
- ECDSA-P521 IV-AES128-GCM Issue * 10000 : 352ms
69
- ECDSA-P521 IV-AES128-GCM Parse * 10000 : 554ms
70
- ECDSA-P521 IV-AES256-GCM Issue * 10000 : 374ms
71
- ECDSA-P521 IV-AES256-GCM Parse * 10000 : 529ms
58
+ HMAC-SHA512-MFS IV-AES128-GCM Parse * 10000 : 122ms
59
+ HMAC-SHA512-MFS IV-AES256-GCM Issue * 10000 : 125ms
60
+ HMAC-SHA512-MFS IV-AES256-GCM Parse * 10000 : 121ms
61
+ ECDSA-P256 IV-AES128-GCM Issue * 10000 : 146ms
62
+ ECDSA-P256 IV-AES128-GCM Parse * 10000 : 182ms
63
+ ECDSA-P256 IV-AES256-GCM Issue * 10000 : 144ms
64
+ ECDSA-P256 IV-AES256-GCM Parse * 10000 : 182ms
65
+ ECDSA-P384 IV-AES128-GCM Issue * 10000 : 247ms
66
+ ECDSA-P384 IV-AES128-GCM Parse * 10000 : 433ms
67
+ ECDSA-P384 IV-AES256-GCM Issue * 10000 : 243ms
68
+ ECDSA-P384 IV-AES256-GCM Parse * 10000 : 430ms
69
+ ECDSA-P521 IV-AES128-GCM Issue * 10000 : 308ms
70
+ ECDSA-P521 IV-AES128-GCM Parse * 10000 : 492ms
71
+ ECDSA-P521 IV-AES256-GCM Issue * 10000 : 308ms
72
+ ECDSA-P521 IV-AES256-GCM Parse * 10000 : 491ms
72
73
 
73
74
  --- Single-Thread ---
74
- HMAC-SHA256-MFS IV-AES128-GCM Issue * 10000 : 64ms
75
- HMAC-SHA256-MFS IV-AES128-GCM Parse * 10000 : 60ms
76
- HMAC-SHA256-MFS IV-AES256-GCM Issue * 10000 : 58ms
77
- HMAC-SHA256-MFS IV-AES256-GCM Parse * 10000 : 66ms
78
- HMAC-SHA384-MFS IV-AES128-GCM Issue * 10000 : 62ms
79
- HMAC-SHA384-MFS IV-AES128-GCM Parse * 10000 : 61ms
80
- HMAC-SHA384-MFS IV-AES256-GCM Issue * 10000 : 66ms
81
- HMAC-SHA384-MFS IV-AES256-GCM Parse * 10000 : 73ms
75
+ HMAC-SHA256-MFS IV-AES128-GCM Issue * 10000 : 61ms
76
+ HMAC-SHA256-MFS IV-AES128-GCM Parse * 10000 : 69ms
77
+ HMAC-SHA256-MFS IV-AES256-GCM Issue * 10000 : 57ms
78
+ HMAC-SHA256-MFS IV-AES256-GCM Parse * 10000 : 67ms
79
+ HMAC-SHA384-MFS IV-AES128-GCM Issue * 10000 : 60ms
80
+ HMAC-SHA384-MFS IV-AES128-GCM Parse * 10000 : 67ms
81
+ HMAC-SHA384-MFS IV-AES256-GCM Issue * 10000 : 58ms
82
+ HMAC-SHA384-MFS IV-AES256-GCM Parse * 10000 : 67ms
82
83
  HMAC-SHA512-MFS IV-AES128-GCM Issue * 10000 : 58ms
83
- HMAC-SHA512-MFS IV-AES128-GCM Parse * 10000 : 63ms
84
+ HMAC-SHA512-MFS IV-AES128-GCM Parse * 10000 : 70ms
84
85
  HMAC-SHA512-MFS IV-AES256-GCM Issue * 10000 : 60ms
85
- HMAC-SHA512-MFS IV-AES256-GCM Parse * 10000 : 67ms
86
- ECDSA-P256 IV-AES128-GCM Issue * 10000 : 177ms
87
- ECDSA-P256 IV-AES128-GCM Parse * 10000 : 392ms
88
- ECDSA-P256 IV-AES256-GCM Issue * 10000 : 172ms
89
- ECDSA-P256 IV-AES256-GCM Parse * 10000 : 394ms
90
- ECDSA-P384 IV-AES128-GCM Issue * 10000 : 1055ms
91
- ECDSA-P384 IV-AES128-GCM Parse * 10000 : 2155ms
92
- ECDSA-P384 IV-AES256-GCM Issue * 10000 : 1039ms
93
- ECDSA-P384 IV-AES256-GCM Parse * 10000 : 2160ms
94
- ECDSA-P521 IV-AES128-GCM Issue * 10000 : 1358ms
95
- ECDSA-P521 IV-AES128-GCM Parse * 10000 : 2390ms
96
- ECDSA-P521 IV-AES256-GCM Issue * 10000 : 1381ms
97
- ECDSA-P521 IV-AES256-GCM Parse * 10000 : 2398ms
86
+ HMAC-SHA512-MFS IV-AES256-GCM Parse * 10000 : 68ms
87
+ ECDSA-P256 IV-AES128-GCM Issue * 10000 : 172ms
88
+ ECDSA-P256 IV-AES128-GCM Parse * 10000 : 396ms
89
+ ECDSA-P256 IV-AES256-GCM Issue * 10000 : 173ms
90
+ ECDSA-P256 IV-AES256-GCM Parse * 10000 : 401ms
91
+ ECDSA-P384 IV-AES128-GCM Issue * 10000 : 1070ms
92
+ ECDSA-P384 IV-AES128-GCM Parse * 10000 : 2198ms
93
+ ECDSA-P384 IV-AES256-GCM Issue * 10000 : 1069ms
94
+ ECDSA-P384 IV-AES256-GCM Parse * 10000 : 2192ms
95
+ ECDSA-P521 IV-AES128-GCM Issue * 10000 : 1366ms
96
+ ECDSA-P521 IV-AES128-GCM Parse * 10000 : 2417ms
97
+ ECDSA-P521 IV-AES256-GCM Issue * 10000 : 1365ms
98
+ ECDSA-P521 IV-AES256-GCM Parse * 10000 : 2405ms
98
99
  ```
@@ -15,12 +15,16 @@ module Saro
15
15
 
16
16
  STOP_JOIN_TIMEOUT_SECONDS = 1.0
17
17
 
18
- def initialize(uri:, token:, interval_seconds: 60, verify_only: false, dat_manager: nil)
18
+ def initialize(uri:, token:, interval_seconds: 60, verify_only: false, dat_manager: nil,
19
+ connect_timeout_seconds: 5, sync_timeout_seconds: 15)
19
20
  @uri = uri
20
21
  @token = token
21
22
  @interval_seconds = interval_seconds
22
23
  @verify_only = verify_only
23
24
  @manager = dat_manager || DatManager.new
25
+ @connect_timeout_seconds = connect_timeout_seconds
26
+ @sync_timeout_seconds = sync_timeout_seconds
27
+ @active_http = nil
24
28
  @version = 0
25
29
  @lock = Mutex.new
26
30
  @lifecycle = Mutex.new
@@ -44,6 +48,7 @@ module Saro
44
48
  @stopped = true
45
49
  @stop_cond.broadcast
46
50
  thread = @thread
51
+ @active_http&.finish if @active_http&.started?
47
52
  end
48
53
  thread&.join(STOP_JOIN_TIMEOUT_SECONDS)
49
54
  nil
@@ -75,7 +80,7 @@ module Saro
75
80
  nil
76
81
  end
77
82
 
78
- private def sync_or_raise
83
+ def sync_or_raise
79
84
  unless @lock.try_lock
80
85
  @logger.debug("cms sync skipped, previous sync still running: #{@uri}")
81
86
  raise Saro::Dat::Error.new(Saro::Dat::ErrorCode::CMS_SYNC_IN_PROGRESS)
@@ -88,8 +93,13 @@ module Saro
88
93
 
89
94
  response =
90
95
  begin
91
- Net::HTTP.start(url.host, url.port, use_ssl: url.scheme == 'https', open_timeout: 10, read_timeout: 10) do |http|
96
+ Net::HTTP.start(url.host, url.port, use_ssl: url.scheme == 'https',
97
+ open_timeout: (@connect_timeout_seconds.zero? ? nil : @connect_timeout_seconds),
98
+ read_timeout: (@sync_timeout_seconds.zero? ? nil : @sync_timeout_seconds)) do |http|
99
+ @lifecycle.synchronize { @active_http = http }
92
100
  http.request(request)
101
+ ensure
102
+ @lifecycle.synchronize { @active_http = nil }
93
103
  end
94
104
  rescue StandardError => e
95
105
  raise Saro::Dat::Error.new(Saro::Dat::ErrorCode::CMS_UNREACHABLE, "cannot reach #{@uri}", cause: e)
@@ -99,28 +109,25 @@ module Saro
99
109
  raise self.class.http_status_error(status) unless status.between?(200, 299)
100
110
 
101
111
  body = response.body
102
- if body.nil? || body.empty?
103
- @logger.debug("No new certificate: #{url}")
104
- return nil
112
+ raise Saro::Dat::Error.new(Saro::Dat::ErrorCode::CMS_MALFORMED, "response is empty") if body.nil? || body.empty?
113
+ unless body.ascii_only?
114
+ raise Saro::Dat::Error.new(Saro::Dat::ErrorCode::CMS_MALFORMED, "response is not strict ASCII")
105
115
  end
106
116
 
107
117
  lines = body.split("\n", 2)
108
- if lines.length < 2
109
- if body.start_with?("\n")
110
- raise Saro::Dat::Error.new(Saro::Dat::ErrorCode::CMS_MALFORMED, "response has no version line")
111
- end
112
- @logger.debug("No new certificate: #{url}")
113
- return nil
114
- end
115
-
116
- new_version_str = lines[0].strip
117
- new_certificates = lines[1].strip
118
+ new_version_str = lines[0]
119
+ new_certificates = lines.length == 2 ? lines[1].strip : ""
118
120
 
119
121
  unless new_version_str.match?(/\A[0-9]+\z/)
120
122
  raise Saro::Dat::Error.new(Saro::Dat::ErrorCode::CMS_MALFORMED, "version line is not a plain decimal integer")
121
123
  end
122
124
  new_version = new_version_str.to_i
123
125
 
126
+ if new_certificates.empty?
127
+ @logger.debug("No new certificate: #{url}")
128
+ return nil
129
+ end
130
+
124
131
  if new_version < @version
125
132
  @logger.warn("#{Saro::Dat::ErrorCode::CMS_VERSION_RESET}: #{@version} -> #{new_version}")
126
133
  end
@@ -225,6 +232,16 @@ module Saro
225
232
  self
226
233
  end
227
234
 
235
+ def connect_timeout_seconds(seconds)
236
+ @connect_timeout_seconds = seconds
237
+ self
238
+ end
239
+
240
+ def sync_timeout_seconds(seconds)
241
+ @sync_timeout_seconds = seconds
242
+ self
243
+ end
244
+
228
245
  def build
229
246
  parsed =
230
247
  begin
@@ -250,7 +267,9 @@ module Saro
250
267
  uri: final_uri,
251
268
  token: @token,
252
269
  interval_seconds: @interval_seconds,
253
- verify_only: @verify_only
270
+ verify_only: @verify_only,
271
+ connect_timeout_seconds: @connect_timeout_seconds,
272
+ sync_timeout_seconds: @sync_timeout_seconds
254
273
  )
255
274
  end
256
275
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: saro-dat
3
3
  version: !ruby/object:Gem::Version
4
- version: 4.6.1
4
+ version: 4.7.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - marker
@@ -55,16 +55,16 @@ dependencies:
55
55
  name: minitest
56
56
  requirement: !ruby/object:Gem::Requirement
57
57
  requirements:
58
- - - "~>"
58
+ - - '='
59
59
  - !ruby/object:Gem::Version
60
- version: '6.0'
60
+ version: 5.26.1
61
61
  type: :development
62
62
  prerelease: false
63
63
  version_requirements: !ruby/object:Gem::Requirement
64
64
  requirements:
65
- - - "~>"
65
+ - - '='
66
66
  - !ruby/object:Gem::Version
67
- version: '6.0'
67
+ version: 5.26.1
68
68
  - !ruby/object:Gem::Dependency
69
69
  name: benchmark
70
70
  requirement: !ruby/object:Gem::Requirement
@@ -83,16 +83,16 @@ dependencies:
83
83
  name: parallel
84
84
  requirement: !ruby/object:Gem::Requirement
85
85
  requirements:
86
- - - ">="
86
+ - - "~>"
87
87
  - !ruby/object:Gem::Version
88
- version: '0'
88
+ version: 1.28.0
89
89
  type: :development
90
90
  prerelease: false
91
91
  version_requirements: !ruby/object:Gem::Requirement
92
92
  requirements:
93
- - - ">="
93
+ - - "~>"
94
94
  - !ruby/object:Gem::Version
95
- version: '0'
95
+ version: 1.28.0
96
96
  description: Ported from Python dat library
97
97
  email:
98
98
  - j@saro.me
@@ -100,15 +100,8 @@ executables: []
100
100
  extensions: []
101
101
  extra_rdoc_files: []
102
102
  files:
103
- - ".gitignore"
104
- - ".idea/.gitignore"
105
- - ".idea/modules.xml"
106
- - ".idea/saro-dat.iml"
107
- - ".idea/vcs.xml"
108
- - ".ruby-version"
109
- - Gemfile
103
+ - CHANGELOG.md
110
104
  - LICENSE
111
- - PUBLISH.md
112
105
  - README.md
113
106
  - lib/saro-dat.rb
114
107
  - lib/saro/dat/crypto.rb
@@ -119,7 +112,6 @@ files:
119
112
  - lib/saro/dat/error.rb
120
113
  - lib/saro/dat/signature.rb
121
114
  - lib/saro/dat/util.rb
122
- - saro-dat.gemspec
123
115
  homepage: https://dat.saro.me/libs/gems-saro-dat
124
116
  licenses:
125
117
  - MIT
data/.gitignore DELETED
@@ -1,17 +0,0 @@
1
-
2
- /.bundle/
3
- /vendor/bundle/
4
-
5
- /Gemfile.lock
6
- /saro-dat-*.gem
7
-
8
- /pkg/
9
- /doc/
10
- .yardoc/
11
-
12
-
13
- ### VS Code ###
14
- .vscode/
15
-
16
- ### Mac OS ###
17
- .DS_Store
data/.idea/.gitignore DELETED
@@ -1,10 +0,0 @@
1
- # Default ignored files
2
- /shelf/
3
- /workspace.xml
4
- # Editor-based HTTP Client requests
5
- /httpRequests/
6
- # Ignored default folder with query files
7
- /queries/
8
- # Datasource local storage ignored files
9
- /dataSources/
10
- /dataSources.local.xml
data/.idea/modules.xml DELETED
@@ -1,8 +0,0 @@
1
- <?xml version="1.0" encoding="UTF-8"?>
2
- <project version="4">
3
- <component name="ProjectModuleManager">
4
- <modules>
5
- <module fileurl="file://$PROJECT_DIR$/.idea/saro-dat.iml" filepath="$PROJECT_DIR$/.idea/saro-dat.iml" />
6
- </modules>
7
- </component>
8
- </project>
data/.idea/saro-dat.iml DELETED
@@ -1,24 +0,0 @@
1
- <?xml version="1.0" encoding="UTF-8"?>
2
- <module type="RUBY_MODULE" version="4">
3
- <component name="ModuleRunConfigurationManager">
4
- <shared />
5
- </component>
6
- <component name="NewModuleRootManager">
7
- <content url="file://$MODULE_DIR$">
8
- <sourceFolder url="file://$MODULE_DIR$/features" isTestSource="true" />
9
- <sourceFolder url="file://$MODULE_DIR$/spec" isTestSource="true" />
10
- <sourceFolder url="file://$MODULE_DIR$/test" isTestSource="true" />
11
- </content>
12
- <orderEntry type="jdk" jdkName="rbenv: 4.0.5" jdkType="RUBY_SDK" />
13
- <orderEntry type="sourceFolder" forTests="false" />
14
- <orderEntry type="library" scope="PROVIDED" name="base64 (v0.3.0, rbenv: 4.0.5) [gem]" level="application" />
15
- <orderEntry type="library" scope="PROVIDED" name="benchmark (v0.5.0, rbenv: 4.0.5) [gem]" level="application" />
16
- <orderEntry type="library" scope="PROVIDED" name="bundler (v4.0.12, rbenv: 4.0.5) [gem]" level="application" />
17
- <orderEntry type="library" scope="PROVIDED" name="drb (v2.2.3, rbenv: 4.0.5) [gem]" level="application" />
18
- <orderEntry type="library" scope="PROVIDED" name="logger (v1.7.0, rbenv: 4.0.5) [gem]" level="application" />
19
- <orderEntry type="library" scope="PROVIDED" name="minitest (v6.0.6, rbenv: 4.0.5) [gem]" level="application" />
20
- <orderEntry type="library" scope="PROVIDED" name="openssl (v4.0.2, rbenv: 4.0.5) [gem]" level="application" />
21
- <orderEntry type="library" scope="PROVIDED" name="parallel (v2.1.0, rbenv: 4.0.5) [gem]" level="application" />
22
- <orderEntry type="library" scope="PROVIDED" name="prism (v1.9.0, rbenv: 4.0.5) [gem]" level="application" />
23
- </component>
24
- </module>
data/.idea/vcs.xml DELETED
@@ -1,8 +0,0 @@
1
- <?xml version="1.0" encoding="UTF-8"?>
2
- <project version="4">
3
- <component name="VcsDirectoryMappings">
4
- <mapping directory="" vcs="Git" />
5
- <mapping directory="$PROJECT_DIR$/../.." vcs="Git" />
6
- <mapping directory="$PROJECT_DIR$/.." vcs="Git" />
7
- </component>
8
- </project>
data/.ruby-version DELETED
@@ -1 +0,0 @@
1
- 4.0.5
data/Gemfile DELETED
@@ -1,5 +0,0 @@
1
- # frozen_string_literal: true
2
-
3
- source "https://rubygems.org"
4
-
5
- gemspec
data/PUBLISH.md DELETED
@@ -1,46 +0,0 @@
1
- ## sync
2
- ```shell
3
- rm -rf Gemfile.lock
4
- bundle install
5
-
6
- ```
7
-
8
- ## publish
9
- ```
10
- gem build saro-dat.gemspec
11
- gem signin
12
- # glob, not a pinned filename: a hardcoded version silently pushes a stale
13
- # package after a version bump
14
- gem push saro-dat-*.gem
15
- ```
16
-
17
- ## install
18
- ```
19
- # install
20
- brew install rbenv ruby-build
21
-
22
- # mac -
23
- echo 'eval "$(rbenv init -)"' >> ~/.zshrc
24
- source ~/.zshrc
25
- # - mac
26
-
27
- rbenv install -l
28
- rbenv install 4.0.5
29
- rbenv local 4.0.5
30
- rbenv rehash
31
-
32
- ruby -v
33
- ```
34
-
35
-
36
- ## install test
37
- ```
38
- bundle add saro-dat
39
- bundle install
40
- ```
41
-
42
- ## version up
43
- ```
44
- bundle outdated
45
- bundle update --all
46
- ```
data/saro-dat.gemspec DELETED
@@ -1,34 +0,0 @@
1
- # frozen_string_literal: true
2
-
3
- Gem::Specification.new do |spec|
4
- spec.name = "saro-dat"
5
- spec.version = "4.6.1"
6
- spec.authors = ["marker"]
7
- spec.email = ["j@saro.me"]
8
-
9
- spec.summary = "DAT (Data Access Token) Ruby implementation"
10
- spec.description = "Ported from Python dat library"
11
- spec.homepage = "https://dat.saro.me/libs/gems-saro-dat"
12
- spec.license = "MIT"
13
- spec.required_ruby_version = ">= 2.7.0"
14
-
15
- spec.metadata["homepage_uri"] = spec.homepage
16
- spec.metadata["source_code_uri"] = "https://github.com/saro-lab/dat"
17
-
18
- spec.metadata["keywords"] = "dat, distributed, access, token, web, session, security, authentication"
19
-
20
- spec.files = Dir.chdir(File.expand_path(__dir__)) do
21
- `git ls-files -z`.split("\x0").reject { |f| f.match(%r{\A(?:test|spec|features|_pypi)/}) }
22
- end
23
- spec.bindir = "exe"
24
- spec.executables = spec.files.grep(%r{\Aexe/}) { |f| File.basename(f) }
25
- spec.require_paths = ["lib"]
26
-
27
- spec.add_dependency "openssl", "~> 4.0.2"
28
- spec.add_dependency "base64"
29
- spec.add_dependency "logger"
30
-
31
- spec.add_development_dependency "minitest", "~> 6.0"
32
- spec.add_development_dependency "benchmark"
33
- spec.add_development_dependency "parallel"
34
- end