bosh-director 1.2859.0 → 1.2862.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: 2c36256ca6fc35e0902659c0f9ca8e7ab1b682dc
4
- data.tar.gz: abe7a4560d667a385ca6f558488b0d0de2e07b3c
3
+ metadata.gz: 90797724c4418af74e74de81c8b5c9955ebfbd31
4
+ data.tar.gz: fdac207018629e7463ba22a05dee08e0493e3a12
5
5
  SHA512:
6
- metadata.gz: 345b751a2d762ddd0e30b947b9a53ce589f7f2a6ef45c3609b9f5f7903db6de4af86b2b9995c5c18c6a0a9149db88b1a3b798caf17f80eb1ea44e5f421d4438f
7
- data.tar.gz: d5ed0dcd36016d78a97deac726f0e4a288a6b80cd1028a9f337c3570f3c641c68b9dccf1a23865f262312cc00d5704678928d4968ef9d197c105d2e5577f04de
6
+ metadata.gz: a4f2dfa82f0e1c11acac4fb2d01342f6da5056d61107eb625ae2f30468ebfcccdfd52629d900ede43a86492d2d78066d73607f036792d27f78409e95f10420d4
7
+ data.tar.gz: b5dfff754b5543d8896537bf3774a826f5f51f641e671c7154845fd71ea0200a5ffc53af59c2cdf356d4d477915a8e69526cc7204ff827147f13e44b8da3111f
@@ -39,7 +39,9 @@ module Bosh
39
39
  def identity_provider
40
40
  @identity_provider ||= begin
41
41
  # no fetching w defaults?
42
- user_management_provider = @config.hash['user_management']['provider']
42
+ user_management = @config.hash['user_management']
43
+ user_management ||= { 'provider' => 'local' }
44
+ user_management_provider = user_management['provider']
43
45
 
44
46
  unless USER_MANAGEMENT_PROVIDERS.include?(user_management_provider)
45
47
  raise ArgumentError,
@@ -48,7 +50,11 @@ module Bosh
48
50
  end
49
51
  if user_management_provider == 'uaa'
50
52
  Config.logger.debug("Director configured with 'uaa' user management provider")
51
- Bosh::Director::Api::UAAIdentityProvider.new
53
+ unless user_management['options'] && user_management['options']['key']
54
+ raise ArgumentError, "Missing UAA secret key in user_management.options.key"
55
+ end
56
+
57
+ Bosh::Director::Api::UAAIdentityProvider.new(user_management['options']['key'])
52
58
  else
53
59
  Config.logger.debug("Director configured with 'local' user management provider")
54
60
  Bosh::Director::Api::LocalIdentityProvider.new(Bosh::Director::Api::UserManager.new)
@@ -1,9 +1,19 @@
1
+ require 'uaa'
2
+
1
3
  module Bosh
2
4
  module Director
3
5
  module Api
4
6
  class UAAIdentityProvider
7
+ def initialize(key)
8
+ @token_coder = CF::UAA::TokenCoder.new(skey: key, audience_ids: ['bosh'])
9
+ end
10
+
5
11
  def corroborate_user(request_env)
6
- raise AuthenticationError
12
+ auth_header = request_env['HTTP_AUTHORIZATION']
13
+ token = @token_coder.decode(auth_header)
14
+ token["user_id"]
15
+ rescue CF::UAA::DecodeError, CF::UAA::AuthError => e
16
+ raise AuthenticationError, e.message
7
17
  end
8
18
  end
9
19
  end
@@ -200,7 +200,7 @@ module Bosh::Director
200
200
 
201
201
  def cloud_type
202
202
  if @cloud_options
203
- @cloud_options['plugin']
203
+ @cloud_options['plugin'] || @cloud_options['provider']['name']
204
204
  end
205
205
  end
206
206
 
@@ -1,5 +1,5 @@
1
1
  module Bosh
2
2
  module Director
3
- VERSION = '1.2859.0'
3
+ VERSION = '1.2862.0'
4
4
  end
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: bosh-director
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.2859.0
4
+ version: 1.2862.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - VMware
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2015-02-26 00:00:00.000000000 Z
11
+ date: 2015-03-03 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bcrypt-ruby
@@ -30,126 +30,126 @@ dependencies:
30
30
  requirements:
31
31
  - - "~>"
32
32
  - !ruby/object:Gem::Version
33
- version: 1.2859.0
33
+ version: 1.2862.0
34
34
  type: :runtime
35
35
  prerelease: false
36
36
  version_requirements: !ruby/object:Gem::Requirement
37
37
  requirements:
38
38
  - - "~>"
39
39
  - !ruby/object:Gem::Version
40
- version: 1.2859.0
40
+ version: 1.2862.0
41
41
  - !ruby/object:Gem::Dependency
42
42
  name: bosh-core
43
43
  requirement: !ruby/object:Gem::Requirement
44
44
  requirements:
45
45
  - - "~>"
46
46
  - !ruby/object:Gem::Version
47
- version: 1.2859.0
47
+ version: 1.2862.0
48
48
  type: :runtime
49
49
  prerelease: false
50
50
  version_requirements: !ruby/object:Gem::Requirement
51
51
  requirements:
52
52
  - - "~>"
53
53
  - !ruby/object:Gem::Version
54
- version: 1.2859.0
54
+ version: 1.2862.0
55
55
  - !ruby/object:Gem::Dependency
56
56
  name: bosh-director-core
57
57
  requirement: !ruby/object:Gem::Requirement
58
58
  requirements:
59
59
  - - "~>"
60
60
  - !ruby/object:Gem::Version
61
- version: 1.2859.0
61
+ version: 1.2862.0
62
62
  type: :runtime
63
63
  prerelease: false
64
64
  version_requirements: !ruby/object:Gem::Requirement
65
65
  requirements:
66
66
  - - "~>"
67
67
  - !ruby/object:Gem::Version
68
- version: 1.2859.0
68
+ version: 1.2862.0
69
69
  - !ruby/object:Gem::Dependency
70
70
  name: bosh_common
71
71
  requirement: !ruby/object:Gem::Requirement
72
72
  requirements:
73
73
  - - "~>"
74
74
  - !ruby/object:Gem::Version
75
- version: 1.2859.0
75
+ version: 1.2862.0
76
76
  type: :runtime
77
77
  prerelease: false
78
78
  version_requirements: !ruby/object:Gem::Requirement
79
79
  requirements:
80
80
  - - "~>"
81
81
  - !ruby/object:Gem::Version
82
- version: 1.2859.0
82
+ version: 1.2862.0
83
83
  - !ruby/object:Gem::Dependency
84
84
  name: bosh-template
85
85
  requirement: !ruby/object:Gem::Requirement
86
86
  requirements:
87
87
  - - "~>"
88
88
  - !ruby/object:Gem::Version
89
- version: 1.2859.0
89
+ version: 1.2862.0
90
90
  type: :runtime
91
91
  prerelease: false
92
92
  version_requirements: !ruby/object:Gem::Requirement
93
93
  requirements:
94
94
  - - "~>"
95
95
  - !ruby/object:Gem::Version
96
- version: 1.2859.0
96
+ version: 1.2862.0
97
97
  - !ruby/object:Gem::Dependency
98
98
  name: bosh_cpi
99
99
  requirement: !ruby/object:Gem::Requirement
100
100
  requirements:
101
101
  - - "~>"
102
102
  - !ruby/object:Gem::Version
103
- version: 1.2859.0
103
+ version: 1.2862.0
104
104
  type: :runtime
105
105
  prerelease: false
106
106
  version_requirements: !ruby/object:Gem::Requirement
107
107
  requirements:
108
108
  - - "~>"
109
109
  - !ruby/object:Gem::Version
110
- version: 1.2859.0
110
+ version: 1.2862.0
111
111
  - !ruby/object:Gem::Dependency
112
112
  name: bosh_openstack_cpi
113
113
  requirement: !ruby/object:Gem::Requirement
114
114
  requirements:
115
115
  - - "~>"
116
116
  - !ruby/object:Gem::Version
117
- version: 1.2859.0
117
+ version: 1.2862.0
118
118
  type: :runtime
119
119
  prerelease: false
120
120
  version_requirements: !ruby/object:Gem::Requirement
121
121
  requirements:
122
122
  - - "~>"
123
123
  - !ruby/object:Gem::Version
124
- version: 1.2859.0
124
+ version: 1.2862.0
125
125
  - !ruby/object:Gem::Dependency
126
126
  name: bosh_aws_cpi
127
127
  requirement: !ruby/object:Gem::Requirement
128
128
  requirements:
129
129
  - - "~>"
130
130
  - !ruby/object:Gem::Version
131
- version: 1.2859.0
131
+ version: 1.2862.0
132
132
  type: :runtime
133
133
  prerelease: false
134
134
  version_requirements: !ruby/object:Gem::Requirement
135
135
  requirements:
136
136
  - - "~>"
137
137
  - !ruby/object:Gem::Version
138
- version: 1.2859.0
138
+ version: 1.2862.0
139
139
  - !ruby/object:Gem::Dependency
140
140
  name: bosh_vsphere_cpi
141
141
  requirement: !ruby/object:Gem::Requirement
142
142
  requirements:
143
143
  - - "~>"
144
144
  - !ruby/object:Gem::Version
145
- version: 1.2859.0
145
+ version: 1.2862.0
146
146
  type: :runtime
147
147
  prerelease: false
148
148
  version_requirements: !ruby/object:Gem::Requirement
149
149
  requirements:
150
150
  - - "~>"
151
151
  - !ruby/object:Gem::Version
152
- version: 1.2859.0
152
+ version: 1.2862.0
153
153
  - !ruby/object:Gem::Dependency
154
154
  name: bosh_vcloud_cpi
155
155
  requirement: !ruby/object:Gem::Requirement
@@ -430,6 +430,20 @@ dependencies:
430
430
  - - "~>"
431
431
  - !ruby/object:Gem::Version
432
432
  version: 1.1.0
433
+ - !ruby/object:Gem::Dependency
434
+ name: cf-uaa-lib
435
+ requirement: !ruby/object:Gem::Requirement
436
+ requirements:
437
+ - - "~>"
438
+ - !ruby/object:Gem::Version
439
+ version: 3.1.0
440
+ type: :runtime
441
+ prerelease: false
442
+ version_requirements: !ruby/object:Gem::Requirement
443
+ requirements:
444
+ - - "~>"
445
+ - !ruby/object:Gem::Version
446
+ version: 3.1.0
433
447
  - !ruby/object:Gem::Dependency
434
448
  name: timecop
435
449
  requirement: !ruby/object:Gem::Requirement
@@ -446,7 +460,7 @@ dependencies:
446
460
  version: '0'
447
461
  description: |-
448
462
  BOSH Director
449
- 8b7528
463
+ c8ad5c
450
464
  email: support@cloudfoundry.com
451
465
  executables:
452
466
  - bosh-director