omf_common 6.0.8.pre.1 → 6.0.8.pre.2
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 +8 -8
- data/example/auth_test.rb +2 -6
- data/lib/omf_common.rb +1 -1
- data/lib/omf_common/default_logging.rb +1 -2
- metadata +2 -2
checksums.yaml
CHANGED
|
@@ -1,15 +1,15 @@
|
|
|
1
1
|
---
|
|
2
2
|
!binary "U0hBMQ==":
|
|
3
3
|
metadata.gz: !binary |-
|
|
4
|
-
|
|
4
|
+
ZDY5YWU0MWI3YjNmMGE5M2IyM2M3OThiOGViYjFiN2VjYjM2ODliMw==
|
|
5
5
|
data.tar.gz: !binary |-
|
|
6
|
-
|
|
6
|
+
NGM5NmZlYjlmYjUxZGY3YjY5ODkwYzZmYjhlZWRjNTU1ODhmYjFkMw==
|
|
7
7
|
!binary "U0hBNTEy":
|
|
8
8
|
metadata.gz: !binary |-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
9
|
+
NzFjOWU5MzY2OWE3NjkzM2RjMjQ3MGUyMzYwOTUxOTQxNDg5OTU4Njc5NTFi
|
|
10
|
+
YjNlOTI1YjY0YTY1ZjRhZTRjMmY1MjE5OWIyZjYxNDU3MzA5ODg5MTk0MDRj
|
|
11
|
+
MTQ0ODkyMjYxMDA0YzY4ZjYyYjRmYzkxNDk1ZDBiM2Y0ZTE0MDk=
|
|
12
12
|
data.tar.gz: !binary |-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
13
|
+
MDRlYWRiYzQ2NWMyMDFjNTc2NmM5NjJjNDBjODg4NzYxMGEwZWZjNDM0YmY2
|
|
14
|
+
MzI2NWUwM2NkOGQzZTcwMjgyZmU1MmQ2Mjc0ZDFhZjU1YzFjNTMxZDRjZGE0
|
|
15
|
+
MzhjMGUyMTUzOWVmZjc4MDI2NTRlODVlOWY3NTc2YjEwMDg3NWI=
|
data/example/auth_test.rb
CHANGED
|
@@ -10,13 +10,11 @@ $: << File.join(TOP_DIR, 'lib')
|
|
|
10
10
|
|
|
11
11
|
begin; require 'json/jwt'; rescue Exception; end
|
|
12
12
|
require 'omf_common'
|
|
13
|
-
require 'pry'
|
|
14
13
|
|
|
15
14
|
OP_MODE = :development
|
|
16
15
|
|
|
17
16
|
opts = {
|
|
18
17
|
communication: {
|
|
19
|
-
url: 'xmpp://srv.mytestbed.net',
|
|
20
18
|
auth: {
|
|
21
19
|
authenticate: true,
|
|
22
20
|
pdp: {
|
|
@@ -37,7 +35,6 @@ class TestPDP
|
|
|
37
35
|
end
|
|
38
36
|
|
|
39
37
|
def authorize(msg, &block)
|
|
40
|
-
info msg.to_s
|
|
41
38
|
iss = msg.issuer.resource_id
|
|
42
39
|
if @trust.include? iss
|
|
43
40
|
puts "AUTH(#{iss}) >>> PASS"
|
|
@@ -65,12 +62,11 @@ def init_auth_store(comm)
|
|
|
65
62
|
|
|
66
63
|
root_ca.create_for_resource 'adam', :requester
|
|
67
64
|
root_ca.create_for_resource 'eve', :requester
|
|
68
|
-
OmfCommon::Auth::CertificateStore.instance.pry
|
|
69
65
|
end
|
|
70
66
|
|
|
71
|
-
OmfCommon.init(:
|
|
67
|
+
OmfCommon.init(:local, opts) do |el|
|
|
72
68
|
OmfCommon.comm.on_connected do |comm|
|
|
73
69
|
doit(comm, el)
|
|
74
70
|
end
|
|
75
71
|
el.after(3) do puts "AFTER" end
|
|
76
|
-
end
|
|
72
|
+
end
|
data/lib/omf_common.rb
CHANGED
|
@@ -13,8 +13,7 @@ module OmfCommon
|
|
|
13
13
|
Logging.appenders.stdout(
|
|
14
14
|
'default_stdout',
|
|
15
15
|
:layout => Logging.layouts.pattern(:date_pattern => '%F %T %z',
|
|
16
|
-
:pattern => '[%d] %-5l %c: %m\n'
|
|
17
|
-
:color_scheme => 'default'))
|
|
16
|
+
:pattern => '[%d] %-5l %c: %m\n'))
|
|
18
17
|
Logging.logger.root.appenders = 'default_stdout'
|
|
19
18
|
Logging.logger.root.level = :info
|
|
20
19
|
|
metadata
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: omf_common
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 6.0.8.pre.
|
|
4
|
+
version: 6.0.8.pre.2
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- NICTA
|
|
8
8
|
autorequire:
|
|
9
9
|
bindir: bin
|
|
10
10
|
cert_chain: []
|
|
11
|
-
date: 2013-11-
|
|
11
|
+
date: 2013-11-25 00:00:00.000000000 Z
|
|
12
12
|
dependencies:
|
|
13
13
|
- !ruby/object:Gem::Dependency
|
|
14
14
|
name: minitest
|