oso-oso 0.24.0 → 0.25.0

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
2
  SHA1:
3
- metadata.gz: 719c88b2531d9c6d1e638928e6be3abba68b67d0
4
- data.tar.gz: 327124db69d3aa57ff06a1089c24124d60175c26
3
+ metadata.gz: c65ea3a330a9a56b2ac4e58594e379409f6a4617
4
+ data.tar.gz: 51cbba24a5b9f529df29a059f1cfe0230c50d36a
5
5
  SHA512:
6
- metadata.gz: 4af7eba0a1bcac195ae51719991191ea78d4c0437bf7aacad7f09fce54d848559178485e098b5a9b150353c3feececd415533e7f311592e38cd6df8d263772c1
7
- data.tar.gz: 57bca613ce91ddf645d7cafb89641286c1c41f1aec70cb4c9378b3157b8cd4291315e08083f19add35dad38325e423539831ffdcce2bc610bd685d328d2703e1
6
+ metadata.gz: 324927c416971e4a1b8baa5eebb19b1c155b0f66607277ca416482d1e2e588ed44efe8a05824cf939fe85bb13b8bbf400769c1f979b0bdf5865b8630123c4d53
7
+ data.tar.gz: 4437ddc46fbcf28ade62f9537fcdb180cea4b7ceb11c065bb94ed9e3868c61276dbd9e9e107d7d61a4dc25e40d7ef52551bdb493a36b7a27f63e9a2c70dc157f
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- oso-oso (0.24.0)
4
+ oso-oso (0.25.0)
5
5
  ffi (~> 1.0)
6
6
 
7
7
  GEM
Binary file
Binary file
Binary file
@@ -29,7 +29,8 @@ module Oso
29
29
  end
30
30
 
31
31
  OPS = {
32
- 'Eq' => '=', 'In' => 'IN', 'Nin' => 'NOT IN', 'Neq' => '!='
32
+ 'Eq' => '=', 'In' => 'IN', 'Nin' => 'NOT IN', 'Neq' => '!=',
33
+ 'Lt' => '<', 'Gt' => '>', 'Leq' => '<=', 'Geq' => '>='
33
34
  }.freeze
34
35
 
35
36
  private
@@ -320,7 +320,18 @@ module Oso
320
320
  else
321
321
  instance_id = nil
322
322
  instance_id = types[value].id if value.is_a?(Class) && types.key?(value)
323
- { 'ExternalInstance' => { 'instance_id' => cache_instance(value, id: instance_id), 'repr' => nil } }
323
+
324
+ # only pass class_repr for registered types
325
+ class_repr = nil
326
+ class_repr = value.class.to_s if types.key?(value.class)
327
+
328
+ {
329
+ 'ExternalInstance' => {
330
+ 'instance_id' => cache_instance(value, id: instance_id),
331
+ 'repr' => nil,
332
+ 'class_repr' => class_repr
333
+ }
334
+ }
324
335
  end
325
336
  { 'value' => value }
326
337
  end
data/lib/oso/version.rb CHANGED
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module Oso
4
- VERSION = '0.24.0'
4
+ VERSION = '0.25.0'
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: oso-oso
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.24.0
4
+ version: 0.25.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Oso Security, Inc.
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2021-12-01 00:00:00.000000000 Z
11
+ date: 2021-12-21 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: ffi