olyx-guardrails 1.1.0 → 1.1.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.
- checksums.yaml +4 -4
- data/CHANGELOG.md +13 -1
- data/README.md +36 -27
- data/lib/olyx/guardrails/policy/redaction_result.rb +5 -1
- data/lib/olyx/guardrails/policy_scanner.rb +0 -2
- data/lib/olyx/guardrails/rails/configuration_values.rb +4 -2
- data/lib/olyx/guardrails/version.rb +1 -1
- metadata +1 -23
- data/CODE_OF_CONDUCT.md +0 -25
- data/CONTRIBUTING.md +0 -132
- data/SECURITY.md +0 -61
- data/docs/API.md +0 -797
- data/docs/OPERATIONS.md +0 -351
- data/docs/POLICIES.md +0 -293
- data/docs/RAILS.md +0 -443
- data/docs/README.md +0 -56
- data/docs/RELEASING.md +0 -69
- data/examples/custom_policy.rb +0 -47
- data/examples/local_llm_provider.rb +0 -66
- data/examples/notifier.rb +0 -42
- data/examples/rails_opt_in.rb +0 -109
- data/examples/ruby_only.rb +0 -59
- data/lib/olyx/guardrails/policy_redactor.rb +0 -28
- data/lib/olyx/guardrails/rails/path_value.rb +0 -30
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 789eb5e71a301345c3fd0d28e59ffee0b0d9cf67ee9686f0912e5a743ccd093b
|
|
4
|
+
data.tar.gz: d89fc57b450761fe6e530fa116e39413eeb17edeb9c73023fbd8247ace98a727
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 17390bf8cbd4961a4e4a669a5ca0b8f80afcf2663fceaea85e5fe31050e789252b5952ef8063ef80d8ffaa5b78f7e69d4a4c96dba8ce1724fcfe090ccb5f3e50
|
|
7
|
+
data.tar.gz: d3e28269e0760c9c09c83f25f8499b74391ee1d7ebf5d3d9ab1a4fe9236d56c2f90b63daa6c603068f6a40fa2398577d08a2f8631d1c05c37e01a478d9ec3a2a
|
data/CHANGELOG.md
CHANGED
|
@@ -3,6 +3,18 @@
|
|
|
3
3
|
All notable changes to olyx-guardrails are documented here.
|
|
4
4
|
Format follows [Keep a Changelog](https://keepachangelog.com/en/1.1.0/).
|
|
5
5
|
|
|
6
|
+
## [1.1.1] - 2026-07-24
|
|
7
|
+
|
|
8
|
+
### Changed
|
|
9
|
+
|
|
10
|
+
- The published gem now contains only runtime code, generator templates, and
|
|
11
|
+
its README, changelog, and license. Guides and runnable examples remain
|
|
12
|
+
available from the canonical repository.
|
|
13
|
+
- Removed two internal, one-use indirection layers from Rails policy-path
|
|
14
|
+
normalization and policy redaction. Public behavior is unchanged.
|
|
15
|
+
- The package manifest is now tested as an exact consumer-facing contract, and
|
|
16
|
+
path-like Rails policy configuration has direct boundary coverage.
|
|
17
|
+
|
|
6
18
|
## [1.1.0] - 2026-07-23
|
|
7
19
|
|
|
8
20
|
### Changed
|
|
@@ -142,4 +154,4 @@ Initial public release.
|
|
|
142
154
|
compatibility contract.
|
|
143
155
|
- Least-privilege, SHA-pinned CI actions; CodeQL and OpenSSF Scorecard
|
|
144
156
|
scanning; a private vulnerability-reporting process (see
|
|
145
|
-
[
|
|
157
|
+
[security policy](https://github.com/Olyx-labs/olyx-guardrails/security/policy)).
|
data/README.md
CHANGED
|
@@ -97,8 +97,9 @@ The default policy:
|
|
|
97
97
|
- has no custom restricted-content rules.
|
|
98
98
|
|
|
99
99
|
Production applications should construct an explicit policy instead of relying
|
|
100
|
-
on defaults. See the
|
|
101
|
-
|
|
100
|
+
on defaults. See the
|
|
101
|
+
[Policies guide](https://github.com/Olyx-labs/olyx-guardrails/blob/master/docs/POLICIES.md)
|
|
102
|
+
for the complete rule language and YAML examples.
|
|
102
103
|
|
|
103
104
|
## Rails quick start
|
|
104
105
|
|
|
@@ -137,9 +138,10 @@ end
|
|
|
137
138
|
Rails enforcement is opt-in. The gem does not scan parameters, callbacks,
|
|
138
139
|
uploads, jobs, GraphQL operations, or Action Cable messages globally.
|
|
139
140
|
|
|
140
|
-
The
|
|
141
|
-
|
|
142
|
-
|
|
141
|
+
The
|
|
142
|
+
[Rails integration guide](https://github.com/Olyx-labs/olyx-guardrails/blob/master/docs/RAILS.md)
|
|
143
|
+
covers every adapter, boot-time configuration, safe YAML loading,
|
|
144
|
+
instrumentation payloads, and notification delivery.
|
|
143
145
|
|
|
144
146
|
## Choose the right entry point
|
|
145
147
|
|
|
@@ -191,31 +193,34 @@ The gem owns normalization, validation, failure handling, and safe result
|
|
|
191
193
|
merging. The application owns model selection, prompting, authentication,
|
|
192
194
|
timeouts, retries, and transport. LLM analysis findings can add a violation but cannot clear a deterministic finding.
|
|
193
195
|
|
|
194
|
-
See the
|
|
195
|
-
[
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
196
|
+
See the
|
|
197
|
+
[provider contract](https://github.com/Olyx-labs/olyx-guardrails/blob/master/docs/API.md#llm-provider-contract)
|
|
198
|
+
and
|
|
199
|
+
[local HTTP example](https://github.com/Olyx-labs/olyx-guardrails/blob/master/examples/local_llm_provider.rb).
|
|
200
|
+
The example works with an application-owned classifier sidecar backed by any
|
|
201
|
+
inference runtime. Read the
|
|
202
|
+
[model-suitability criteria](https://github.com/Olyx-labs/olyx-guardrails/blob/master/docs/OPERATIONS.md#model-suitability)
|
|
203
|
+
before using semantic analysis as a blocking production control.
|
|
199
204
|
|
|
200
205
|
## Documentation
|
|
201
206
|
|
|
202
|
-
- [Documentation index](docs/README.md)
|
|
203
|
-
- [Policies and restricted content](docs/POLICIES.md)
|
|
204
|
-
- [Rails integration](docs/RAILS.md)
|
|
205
|
-
- [Operations and production behavior](docs/OPERATIONS.md)
|
|
206
|
-
- [API reference](docs/API.md)
|
|
207
|
-
- [Release runbook](docs/RELEASING.md)
|
|
208
|
-
- [Security policy](
|
|
209
|
-
- [Contributing](CONTRIBUTING.md)
|
|
207
|
+
- [Documentation index](https://github.com/Olyx-labs/olyx-guardrails/blob/master/docs/README.md)
|
|
208
|
+
- [Policies and restricted content](https://github.com/Olyx-labs/olyx-guardrails/blob/master/docs/POLICIES.md)
|
|
209
|
+
- [Rails integration](https://github.com/Olyx-labs/olyx-guardrails/blob/master/docs/RAILS.md)
|
|
210
|
+
- [Operations and production behavior](https://github.com/Olyx-labs/olyx-guardrails/blob/master/docs/OPERATIONS.md)
|
|
211
|
+
- [API reference](https://github.com/Olyx-labs/olyx-guardrails/blob/master/docs/API.md)
|
|
212
|
+
- [Release runbook](https://github.com/Olyx-labs/olyx-guardrails/blob/master/docs/RELEASING.md)
|
|
213
|
+
- [Security policy](https://github.com/Olyx-labs/olyx-guardrails/security/policy)
|
|
214
|
+
- [Contributing](https://github.com/Olyx-labs/olyx-guardrails/blob/master/CONTRIBUTING.md)
|
|
210
215
|
- [Changelog](CHANGELOG.md)
|
|
211
216
|
|
|
212
217
|
Examples:
|
|
213
218
|
|
|
214
|
-
- [Framework-free Ruby](examples/ruby_only.rb)
|
|
215
|
-
- [Custom policy](examples/custom_policy.rb)
|
|
216
|
-
- [Rails opt-in boundaries](examples/rails_opt_in.rb)
|
|
217
|
-
- [Local LLM provider](examples/local_llm_provider.rb)
|
|
218
|
-
- [Notifier handlers](examples/notifier.rb)
|
|
219
|
+
- [Framework-free Ruby](https://github.com/Olyx-labs/olyx-guardrails/blob/master/examples/ruby_only.rb)
|
|
220
|
+
- [Custom policy](https://github.com/Olyx-labs/olyx-guardrails/blob/master/examples/custom_policy.rb)
|
|
221
|
+
- [Rails opt-in boundaries](https://github.com/Olyx-labs/olyx-guardrails/blob/master/examples/rails_opt_in.rb)
|
|
222
|
+
- [Local LLM provider](https://github.com/Olyx-labs/olyx-guardrails/blob/master/examples/local_llm_provider.rb)
|
|
223
|
+
- [Notifier handlers](https://github.com/Olyx-labs/olyx-guardrails/blob/master/examples/notifier.rb)
|
|
219
224
|
|
|
220
225
|
The framework-free, custom-policy, and notifier examples run directly. The
|
|
221
226
|
Rails example is application-context code, and the local provider example
|
|
@@ -239,9 +244,12 @@ boundary or data-loss-prevention system.
|
|
|
239
244
|
centralized policy rollout, and audit retention remain application or
|
|
240
245
|
platform responsibilities.
|
|
241
246
|
|
|
242
|
-
The
|
|
243
|
-
|
|
244
|
-
|
|
247
|
+
The
|
|
248
|
+
[operations guide](https://github.com/Olyx-labs/olyx-guardrails/blob/master/docs/OPERATIONS.md)
|
|
249
|
+
describes failure modes, data handling, risk scores, concurrency, and
|
|
250
|
+
deployment boundaries. Report security issues through the
|
|
251
|
+
[security policy](https://github.com/Olyx-labs/olyx-guardrails/security/policy),
|
|
252
|
+
not the public issue tracker.
|
|
245
253
|
|
|
246
254
|
## Development
|
|
247
255
|
|
|
@@ -255,7 +263,8 @@ bin/ci
|
|
|
255
263
|
The development bundle includes Rails so contributors exercise the integration
|
|
256
264
|
from the default test suite; Rails remains an optional runtime dependency for
|
|
257
265
|
gem consumers. The Rails compatibility matrix is managed with Appraisal. See
|
|
258
|
-
[
|
|
266
|
+
[contribution guide](https://github.com/Olyx-labs/olyx-guardrails/blob/master/CONTRIBUTING.md)
|
|
267
|
+
before submitting a change.
|
|
259
268
|
|
|
260
269
|
## License
|
|
261
270
|
|
|
@@ -1,5 +1,9 @@
|
|
|
1
1
|
# frozen_string_literal: true
|
|
2
2
|
|
|
3
|
+
require_relative 'finding_presenter'
|
|
4
|
+
require_relative 'redaction_spans'
|
|
5
|
+
require_relative 'unmatched_transformer'
|
|
6
|
+
|
|
3
7
|
module Olyx
|
|
4
8
|
module Guardrails
|
|
5
9
|
module PolicyComponents
|
|
@@ -9,7 +13,7 @@ module Olyx
|
|
|
9
13
|
|
|
10
14
|
def call(source, findings, transform)
|
|
11
15
|
{
|
|
12
|
-
text:
|
|
16
|
+
text: UnmatchedTransformer.call(source, RedactionSpans.call(findings), transform),
|
|
13
17
|
violated: findings.any?,
|
|
14
18
|
findings: FindingPresenter.call(findings)
|
|
15
19
|
}
|
|
@@ -1,10 +1,8 @@
|
|
|
1
1
|
# frozen_string_literal: true
|
|
2
2
|
|
|
3
|
-
require_relative 'policy/finding_presenter'
|
|
4
3
|
require_relative 'policy/match_collector'
|
|
5
4
|
require_relative 'policy/redaction_result'
|
|
6
5
|
require_relative 'policy/scan_result'
|
|
7
|
-
require_relative 'policy_redactor'
|
|
8
6
|
|
|
9
7
|
module Olyx
|
|
10
8
|
# Policy-driven safety checks and redaction for Ruby applications.
|
|
@@ -2,7 +2,6 @@
|
|
|
2
2
|
|
|
3
3
|
require_relative '../policy'
|
|
4
4
|
require_relative 'filter_parameters'
|
|
5
|
-
require_relative 'path_value'
|
|
6
5
|
|
|
7
6
|
module Olyx
|
|
8
7
|
module Guardrails
|
|
@@ -18,7 +17,10 @@ module Olyx
|
|
|
18
17
|
end
|
|
19
18
|
|
|
20
19
|
def path(value)
|
|
21
|
-
|
|
20
|
+
normalized = value.respond_to?(:to_path) ? value.to_path : value
|
|
21
|
+
return normalized.dup.freeze if normalized.is_a?(String) && !normalized.empty?
|
|
22
|
+
|
|
23
|
+
raise ArgumentError, 'Rails policy_path must be a path-like value'
|
|
22
24
|
end
|
|
23
25
|
|
|
24
26
|
def filter_parameters(value)
|
metadata
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: olyx-guardrails
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 1.1.
|
|
4
|
+
version: 1.1.1
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Moses Njoroge
|
|
@@ -42,30 +42,10 @@ extensions: []
|
|
|
42
42
|
extra_rdoc_files:
|
|
43
43
|
- CHANGELOG.md
|
|
44
44
|
- README.md
|
|
45
|
-
- docs/API.md
|
|
46
|
-
- docs/OPERATIONS.md
|
|
47
|
-
- docs/POLICIES.md
|
|
48
|
-
- docs/RAILS.md
|
|
49
|
-
- docs/README.md
|
|
50
|
-
- docs/RELEASING.md
|
|
51
45
|
files:
|
|
52
46
|
- CHANGELOG.md
|
|
53
|
-
- CODE_OF_CONDUCT.md
|
|
54
|
-
- CONTRIBUTING.md
|
|
55
47
|
- LICENSE
|
|
56
48
|
- README.md
|
|
57
|
-
- SECURITY.md
|
|
58
|
-
- docs/API.md
|
|
59
|
-
- docs/OPERATIONS.md
|
|
60
|
-
- docs/POLICIES.md
|
|
61
|
-
- docs/RAILS.md
|
|
62
|
-
- docs/README.md
|
|
63
|
-
- docs/RELEASING.md
|
|
64
|
-
- examples/custom_policy.rb
|
|
65
|
-
- examples/local_llm_provider.rb
|
|
66
|
-
- examples/notifier.rb
|
|
67
|
-
- examples/rails_opt_in.rb
|
|
68
|
-
- examples/ruby_only.rb
|
|
69
49
|
- lib/generators/olyx_guardrails/install_generator.rb
|
|
70
50
|
- lib/generators/olyx_guardrails/templates/initializer.rb.tt
|
|
71
51
|
- lib/generators/olyx_guardrails/templates/policy.yml.tt
|
|
@@ -158,7 +138,6 @@ files:
|
|
|
158
138
|
- lib/olyx/guardrails/policy/unmatched_segment_builder.rb
|
|
159
139
|
- lib/olyx/guardrails/policy/unmatched_transformer.rb
|
|
160
140
|
- lib/olyx/guardrails/policy_aware_redactor.rb
|
|
161
|
-
- lib/olyx/guardrails/policy_redactor.rb
|
|
162
141
|
- lib/olyx/guardrails/policy_rule.rb
|
|
163
142
|
- lib/olyx/guardrails/policy_rule/configuration.rb
|
|
164
143
|
- lib/olyx/guardrails/policy_rule/description_value.rb
|
|
@@ -195,7 +174,6 @@ files:
|
|
|
195
174
|
- lib/olyx/guardrails/rails/job_argument.rb
|
|
196
175
|
- lib/olyx/guardrails/rails/job_reference.rb
|
|
197
176
|
- lib/olyx/guardrails/rails/notification_dispatcher.rb
|
|
198
|
-
- lib/olyx/guardrails/rails/path_value.rb
|
|
199
177
|
- lib/olyx/guardrails/rails/policy_document.rb
|
|
200
178
|
- lib/olyx/guardrails/rails/policy_file.rb
|
|
201
179
|
- lib/olyx/guardrails/rails/policy_file_error.rb
|
data/CODE_OF_CONDUCT.md
DELETED
|
@@ -1,25 +0,0 @@
|
|
|
1
|
-
# Code of Conduct
|
|
2
|
-
|
|
3
|
-
## Our commitment
|
|
4
|
-
|
|
5
|
-
We are committed to a welcoming, professional, and harassment-free community
|
|
6
|
-
for everyone, regardless of background, identity, experience, or ability.
|
|
7
|
-
|
|
8
|
-
## Expected behavior
|
|
9
|
-
|
|
10
|
-
- Be respectful, constructive, and specific.
|
|
11
|
-
- Assume good intent while addressing harmful impact.
|
|
12
|
-
- Accept technical feedback without personal attacks.
|
|
13
|
-
- Respect privacy and confidentiality.
|
|
14
|
-
- Focus disagreement on ideas, evidence, and project outcomes.
|
|
15
|
-
|
|
16
|
-
Harassment, discrimination, threats, sexualized conduct, sustained disruption, doxing, or publication of another person's private information are not acceptable.
|
|
17
|
-
|
|
18
|
-
## Enforcement
|
|
19
|
-
|
|
20
|
-
Report conduct concerns privately to `conduct@olyxai.io`. Maintainers may edit
|
|
21
|
-
or remove contributions, issue warnings, temporarily restrict participation, or
|
|
22
|
-
permanently ban participants when necessary. Reports will be handled as
|
|
23
|
-
confidentially as reasonably possible, with conflicts of interest recused.
|
|
24
|
-
|
|
25
|
-
This policy applies in project spaces and when someone is publicly representing the project.
|
data/CONTRIBUTING.md
DELETED
|
@@ -1,132 +0,0 @@
|
|
|
1
|
-
# Contributing
|
|
2
|
-
|
|
3
|
-
Thank you for improving Olyx Guardrails.
|
|
4
|
-
|
|
5
|
-
## Development setup
|
|
6
|
-
|
|
7
|
-
Detection logic (`lib/olyx/guardrails/pii/`, `secrets/`, `injection_detector.rb`,
|
|
8
|
-
`policy*`, and friends) remains independent of Rails at gem runtime. The
|
|
9
|
-
repository installs Rails as a development and test dependency so every
|
|
10
|
-
contributor runs the integration tests from the same default bundle. Consuming
|
|
11
|
-
applications that use only `require "olyx/guardrails"` do not load Rails.
|
|
12
|
-
|
|
13
|
-
Prepare the complete development bundle:
|
|
14
|
-
|
|
15
|
-
```bash
|
|
16
|
-
rbenv install
|
|
17
|
-
bin/setup
|
|
18
|
-
```
|
|
19
|
-
|
|
20
|
-
Run the complete pre-pull-request gate:
|
|
21
|
-
|
|
22
|
-
```bash
|
|
23
|
-
bin/ci
|
|
24
|
-
```
|
|
25
|
-
|
|
26
|
-
`bin/ci` runs coverage-enforced tests, documentation validation, public RDoc
|
|
27
|
-
coverage, RuboCop, RubyCritic, and the strict per-file quality gate. Individual
|
|
28
|
-
tests remain runnable through `bundle exec ruby -Itest path/to/test_file.rb`.
|
|
29
|
-
CI separately refreshes the Ruby advisory database and audits the committed
|
|
30
|
-
dependency lockfile. This network-backed check stays outside `bin/ci` so the
|
|
31
|
-
local quality gate remains reproducible offline after setup.
|
|
32
|
-
|
|
33
|
-
### Rails adapter changes
|
|
34
|
-
|
|
35
|
-
```bash
|
|
36
|
-
bundle exec appraisal rake test
|
|
37
|
-
```
|
|
38
|
-
|
|
39
|
-
Run this in addition to the above only when the change touches
|
|
40
|
-
`lib/olyx/guardrails/rails/`, `lib/generators/`, or their tests. The Appraisal
|
|
41
|
-
matrix covers Rails 8.0 and 8.1; Rails integration changes must pass every
|
|
42
|
-
configured line while the standalone core remains free of Rails runtime
|
|
43
|
-
dependencies.
|
|
44
|
-
|
|
45
|
-
Ruby 3.4 or newer is supported. Changes must remain compatible with the oldest
|
|
46
|
-
supported Ruby unless the same pull request deliberately changes the gem's
|
|
47
|
-
requirement.
|
|
48
|
-
|
|
49
|
-
RubyCritic is a blocking regression gate configured in `.rubycritic.yml`.
|
|
50
|
-
Do not lower its baseline to merge a change. Refactor new hot spots and ratchet
|
|
51
|
-
the minimum upward when sustained improvements raise the measured score.
|
|
52
|
-
The minimum score is 95; new files must remain focused on one reason to change,
|
|
53
|
-
and every production file must remain A-rated. RubyCritic smells, duplication,
|
|
54
|
-
and per-file complexity are review signals, not automatic design instructions:
|
|
55
|
-
address genuine responsibility or clarity problems, but do not introduce proxy
|
|
56
|
-
methods, unnecessary indirection, or metaprogramming merely to silence a
|
|
57
|
-
heuristic.
|
|
58
|
-
|
|
59
|
-
RuboCop's `Metrics/AbcSize` (max 10), `Metrics/CyclomaticComplexity` (max 7),
|
|
60
|
-
`Metrics/PerceivedComplexity` (max 7), and `Metrics/ClassLength` (max 60 lines)
|
|
61
|
-
are the blocking structural-complexity gate, calibrated against this
|
|
62
|
-
codebase's measured distribution rather than RuboCop's looser defaults. Do not
|
|
63
|
-
split cohesive code, hide behavior behind dynamic dispatch, or weaken a public
|
|
64
|
-
API merely to improve a score. A public DSL or metaprogramming macro that
|
|
65
|
-
genuinely needs more room is a `# rubocop:disable` with an inline reason, or a
|
|
66
|
-
file-level exclude in `.rubocop.yml` with a comment explaining the constraint
|
|
67
|
-
— reviewed like any other exception, not a separate exemption file.
|
|
68
|
-
|
|
69
|
-
## Documentation
|
|
70
|
-
|
|
71
|
-
Public documentation follows the same contract discipline as production code:
|
|
72
|
-
|
|
73
|
-
- write simple, declarative sentences in the present tense;
|
|
74
|
-
- keep the README focused on the shortest correct integration;
|
|
75
|
-
- place task-oriented explanations in the appropriate guide;
|
|
76
|
-
- keep signatures, defaults, return shapes, and exceptions in `docs/API.md`;
|
|
77
|
-
- use complete, copyable examples with synthetic data;
|
|
78
|
-
- link to one canonical explanation instead of duplicating it; and
|
|
79
|
-
- update documentation and tests in the same change as public behavior.
|
|
80
|
-
|
|
81
|
-
Run `ruby script/documentation_gate.rb` after changing Markdown. The gate checks
|
|
82
|
-
local files and heading anchors. CI also syntax-checks every Ruby example.
|
|
83
|
-
|
|
84
|
-
Public code comments use native RDoc conventions and the same concise,
|
|
85
|
-
declarative style. Document behavior, accepted arguments, return values,
|
|
86
|
-
exceptions, security boundaries, and non-obvious edge cases. Do not narrate
|
|
87
|
-
implementation mechanics or repeat the method name. Add supported source files
|
|
88
|
-
to the RDoc whitelist in `olyx-guardrails.gemspec`; implementation-only
|
|
89
|
-
constants remain outside that manifest and are not compatibility commitments.
|
|
90
|
-
|
|
91
|
-
## Pull requests
|
|
92
|
-
|
|
93
|
-
Contributions follow the same fork-and-pull-request workflow used by established
|
|
94
|
-
open-source projects:
|
|
95
|
-
|
|
96
|
-
1. Open an issue first for substantial API, policy, or architectural changes.
|
|
97
|
-
Small fixes may go directly to a pull request.
|
|
98
|
-
2. Fork the repository and create a focused branch from the latest `master`.
|
|
99
|
-
Do not work directly on `master`.
|
|
100
|
-
3. Add tests for behavior changes and adversarial regression tests for
|
|
101
|
-
security-sensitive fixes.
|
|
102
|
-
4. Update README, API reference, examples, and changelog when public behavior
|
|
103
|
-
changes.
|
|
104
|
-
5. Run `bin/ci` locally, plus the Appraisal Rails matrix when the change touches
|
|
105
|
-
`lib/olyx/guardrails/rails/` or `lib/generators/`.
|
|
106
|
-
6. Open a draft pull request early when maintainer feedback would prevent
|
|
107
|
-
rework. Mark it ready only when its description and validation checklist are
|
|
108
|
-
complete.
|
|
109
|
-
|
|
110
|
-
Pull requests run with read-only GitHub token permissions, including
|
|
111
|
-
contributions from forks. CI never requires repository secrets. The protected
|
|
112
|
-
default branch requires the supported Ruby and Rails matrix, dependency audit,
|
|
113
|
-
quality gate, CodeQL analysis, resolved review conversations, and maintainer
|
|
114
|
-
approval. Maintainers squash approved pull requests, and GitHub deletes the
|
|
115
|
-
source branch after merge.
|
|
116
|
-
|
|
117
|
-
Maintainers may ask for a pull request to be split when unrelated behavior,
|
|
118
|
-
refactoring, or generated dependency changes make review unsafe. Force-pushing
|
|
119
|
-
a contributor branch is acceptable while responding to review; GitHub
|
|
120
|
-
dismisses stale approvals when the protected branch changes.
|
|
121
|
-
|
|
122
|
-
Maintainer releases follow [docs/RELEASING.md](docs/RELEASING.md). Do not
|
|
123
|
-
publish an artifact that has not completed that runbook.
|
|
124
|
-
|
|
125
|
-
Never include real credentials, personal data, production endpoints, or
|
|
126
|
-
customer content in fixtures. Use clearly synthetic values.
|
|
127
|
-
|
|
128
|
-
By submitting a contribution, you agree that it is licensed under the
|
|
129
|
-
Apache-2.0 license used by this project.
|
|
130
|
-
|
|
131
|
-
Security vulnerabilities must follow [SECURITY.md](SECURITY.md), not the public
|
|
132
|
-
issue tracker.
|
data/SECURITY.md
DELETED
|
@@ -1,61 +0,0 @@
|
|
|
1
|
-
# Security Policy
|
|
2
|
-
|
|
3
|
-
## Supported versions
|
|
4
|
-
|
|
5
|
-
Security fixes are provided for the latest released minor version. Users should
|
|
6
|
-
upgrade to the latest patch release before reporting an issue.
|
|
7
|
-
|
|
8
|
-
| Version | Supported |
|
|
9
|
-
|---|---|
|
|
10
|
-
| 1.1.x | Yes |
|
|
11
|
-
| <= 1.0 | No |
|
|
12
|
-
|
|
13
|
-
## Reporting a vulnerability
|
|
14
|
-
|
|
15
|
-
Do not open a public issue for a suspected vulnerability.
|
|
16
|
-
|
|
17
|
-
Use a
|
|
18
|
-
[private GitHub security advisory](https://github.com/Olyx-labs/olyx-guardrails/security/advisories/new)
|
|
19
|
-
or email `mosesnjoroge@olyxai.io` with:
|
|
20
|
-
|
|
21
|
-
- the affected version and component;
|
|
22
|
-
- reproduction steps or a minimal proof of concept;
|
|
23
|
-
- expected and observed behavior;
|
|
24
|
-
- the potential confidentiality, integrity, or availability impact; and
|
|
25
|
-
- any suggested remediation or disclosure constraints;
|
|
26
|
-
- whether the issue is already public; and
|
|
27
|
-
- a secure contact method for follow-up.
|
|
28
|
-
|
|
29
|
-
You should receive an acknowledgement within three business days and an initial
|
|
30
|
-
assessment within seven business days. We will coordinate remediation and
|
|
31
|
-
disclosure with the reporter.
|
|
32
|
-
|
|
33
|
-
## Response process
|
|
34
|
-
|
|
35
|
-
After triage, the maintainer will:
|
|
36
|
-
|
|
37
|
-
1. confirm the affected supported versions and severity;
|
|
38
|
-
2. reproduce the issue using synthetic data;
|
|
39
|
-
3. develop a fix and adversarial regression test in private;
|
|
40
|
-
4. prepare release notes and upgrade guidance;
|
|
41
|
-
5. publish a patched gem; and
|
|
42
|
-
6. disclose the issue after supported users can upgrade.
|
|
43
|
-
|
|
44
|
-
Timelines after the initial assessment depend on severity, exploitability, and
|
|
45
|
-
release coordination. The reporter receives material status changes through
|
|
46
|
-
the private reporting channel.
|
|
47
|
-
|
|
48
|
-
## Safe research
|
|
49
|
-
|
|
50
|
-
Good-faith research must use systems and data the researcher owns or has
|
|
51
|
-
permission to test. Do not access another person's data, degrade a service,
|
|
52
|
-
perform denial-of-service testing, use social engineering, or publicly disclose
|
|
53
|
-
an unpatched issue. Reports that follow these boundaries will not be pursued
|
|
54
|
-
for accidental, non-destructive violations of this policy.
|
|
55
|
-
|
|
56
|
-
## Scope notes
|
|
57
|
-
|
|
58
|
-
Pattern-based guardrails are defense-in-depth controls, not complete semantic
|
|
59
|
-
security boundaries. Documented detection limitations alone are not
|
|
60
|
-
vulnerabilities, but bypasses of a documented invariant—especially redaction,
|
|
61
|
-
blocking, or third-party data-egress guarantees—are in scope.
|