blob: 970ef1d37c04c7b2f5c553e55f80ded2362acbd2 [file] [log] [blame]
Petr Jedinýdd6387a2017-08-01 15:50:17 +02001
Petr Jediný1ff6f562017-08-09 14:38:09 +02002================
3Barbican formula
4================
Petr Jedinýdd6387a2017-08-01 15:50:17 +02005
6Barbican is a REST API designed for the secure storage, provisioning and
7management of secrets such as passwords, encryption keys and X.509 Certificates.
8It is aimed at being useful for all environments, including large ephemeral
9Clouds.
10
11Sample pillars
12==============
13
Petr Jediný1ff6f562017-08-09 14:38:09 +020014Barbican cluster service
Petr Jedinýdd6387a2017-08-01 15:50:17 +020015
16.. code-block:: yaml
17
18 barbican:
19 server:
20 enabled: true
21 version: ocata
Petr Jediný1ff6f562017-08-09 14:38:09 +020022 host_href: ''
23 is_proxied: true
24 plugin:
25 simple_crypto:
26 kek: "YWJjZGVmZ2hpamtsbW5vcHFyc3R1dnd4eXoxMjM0NTY="
27 store:
28 software:
29 crypto_plugin: simple_crypto
30 store_plugin: store_crypto
31 global_default: True
32 database:
33 engine: "mysql+pymysql"
34 host: 10.0.106.20
35 port: 3306
36 name: barbican
37 user: barbican
38 password: password
39 bind:
40 address: 10.0.106.20
41 port: 9311
42 admin_port: 9312
43 identity:
44 engine: keystone
45 host: 10.0.106.20
46 port: 35357
47 domain: default
48 tenant: service
49 user: barbican
50 password: password
51 message_queue:
52 engine: rabbitmq
53 user: openstack
54 password: password
55 virtual_host: '/openstack'
56 members:
57 - host: 10.10.10.10
58 port: 5672
59 - host: 10.10.10.11
60 port: 5672
61 - host: 10.10.10.12
62 port: 5672
63 cache:
64 members:
65 - host: 10.10.10.10
66 port: 11211
67 - host: 10.10.10.11
68 port: 11211
69 - host: 10.10.10.12
70 port: 11211
71
72Running behind loadbalancer
73
74If you are running behind loadbalancer, set the `host_href` to load balancer's
75address. You can set `host_href` empty and the api attempts autodetect correct
76address from http requests.
77
78.. code-block:: yaml
79
80 barbican:
81 server:
82 enabled: true
83 version: ocata
84 host_href: ''
85
86
87Running behind proxy
88
89If you are running behind proxy, set the `is_proxied` parameter to `true`. This
90will allow `host_href` autodetection with help of proxy headers such as
91`X-FORWARDED-FOR` and `X-FORWARDED-PROTO`.
92
93.. code-block:: yaml
94
95 barbican:
96 server:
97 enabled: true
98 version: ocata
99 host_href: ''
100 is_proxied: true
101
102Queuing asynchronous messaging
103
104By default is `async_queues_enable` set `false` to invoke worker tasks
105synchronously (i.e. no-queue standalone mode). To enable queuing asynchronous
106messaging you need to set it true.
107
108.. code-block:: yaml
109
110 barbican:
111 server:
112 enabled: true
113 version: ocata
114 async_queues_enable: true
115
116Keystone notification listener
117
118To enable keystone notification listener, set the `ks_notification_enable`
119to true.
120`ks_notifications_allow_requeue` enables requeue feature in case of
121notification processing error. Enable this only when underlying transport
122supports this feature.
123
124
125.. code-block:: yaml
126
127 barbican:
128 server:
129 enabled: true
130 version: ocata
131 ks_notifications_enable: true
132 ks_notifications_allow_requeue: true
133
134
Petr Jediný6e745fb2017-09-05 10:20:05 +0200135MySQL server has gone away
136
137MySQL uses a default `wait_timeout` of 8 hours, after which it will drop
138idle connections. This can result in 'MySQL Gone Away' exceptions. If you
139notice this, you can lower `sql_idle_timeout` to ensure that SQLAlchemy
140reconnects before MySQL can drop the connection.
141
142.. code-block:: yaml
143
144 barbican:
145 server:
146 enabled: true
147 version: ocata
148 database:
149 engine: "mysql+pymysql"
150 host: 10.0.106.20
151 port: 3306
152 name: barbican
153 user: barbican
154 password: password
155 sql_idle_timeout: 1200
156
157
Petr Jediný1ff6f562017-08-09 14:38:09 +0200158Configuring plugins
159-------------------
160
161Dogtag KRA
162
163.. code block:: yaml
164
165 barbican:
166 server:
167 plugin:
168 dogtag:
169 pem_path: '/etc/barbican/kra_admin_cert.pem'
170 dogtag_host: localhost
171 dogtag_port: 8433
172 nss_db_path: '/etc/barbican/alias'
173 nss_db_path_ca: '/etc/barbican/alias-ca'
174 nss_password: 'password123'
175 simple_cmc_profile: 'caOtherCert'
176 ca_expiration_time: 1
177 plugin_working_dir: '/etc/barbican/dogtag'
178
179KMIP HSM
180
181.. code block:: yaml
182
183 barbican:
184 server:
185 plugin:
186 kmip:
187 username: 'admin'
188 password: 'password'
189 host: localhost
190 port: 5696
191 keyfile: '/path/to/certs/cert.key'
192 certfile: '/path/to/certs/cert.crt'
193 ca_certs: '/path/to/certs/LocalCA.crt'
194
195
196PKCS11 HSM
197
198.. code block:: yaml
199
200 barbican:
201 server:
202 plugin:
203 p11_crypto:
204 library_path: '/usr/lib/libCryptoki2_64.so'
205 login: 'mypassword'
206 mkek_label: 'an_mkek'
207 mkek_length: 32
208 hmac_label: 'my_hmac_label'
209
210
211
212Software Only Crypto
213
214`kek` is key encryption key created from 32 bytes encoded as Base64. You should
215not use this in production.
216
217.. code block:: yaml
218
219 barbican:
220 server:
221 plugin:
222 simple_crypto:
223 kek: 'YWJjZGVmZ2hpamtsbW5vcHFyc3R1dnd4eXoxMjM0NTY='
224
225
226Secret stores
227-------------
228
229.. code-block:: yaml
230
231 barbican:
232 server:
233 plugin:
234 simple_crypto:
235 kek: "YWJjZGVmZ2hpamtsbW5vcHFyc3R1dnd4eXoxMjM0NTY="
236 p11_crypto:
237 library_path: '/usr/lib/libCryptoki2_64.so'
238 login: 'mypassword'
239 mkek_label: 'an_mkek'
240 mkek_length: 32
241 hmac_label: 'my_hmac_label'
242 kmip:
243 username: 'admin'
244 password: 'password'
245 host: localhost
246 port: 5696
247 keyfile: '/path/to/certs/cert.key'
248 certfile: '/path/to/certs/cert.crt'
249 ca_certs: '/path/to/certs/LocalCA.crt'
250 dogtag:
251 pem_path: '/etc/barbican/kra_admin_cert.pem'
252 dogtag_host: localhost
253 dogtag_port: 8433
254 nss_db_path: '/etc/barbican/alias'
255 nss_db_path_ca: '/etc/barbican/alias-ca'
256 nss_password: 'password123'
257 simple_cmc_profile: 'caOtherCert'
258 ca_expiration_time: 1
259 plugin_working_dir: '/etc/barbican/dogtag'
260 store:
261 software:
262 crypto_plugin: simple_crypto
263 store_plugin: store_crypto
264 global_default: True
265 kmip:
266 store_plugin: kmip_plugin
267 dogtag:
268 store_plugin: dogtag_plugin
269 pkcs11:
270 store_plugin: store_crypto
271 crypto_plugin: p11_crypto
272
Petr Jedinýdd6387a2017-08-01 15:50:17 +0200273
274Documentation and Bugs
275======================
276
277To learn how to install and update salt-formulas, consult the documentation
278available online at:
279
280 http://salt-formulas.readthedocs.io/
281
282In the unfortunate event that bugs are discovered, they should be reported to
283the appropriate issue tracker. Use GitHub issue tracker for specific salt
284formula:
285
286 https://github.com/salt-formulas/salt-formula-barbican/issues
287
288For feature requests, bug reports or blueprints affecting entire ecosystem,
289use Launchpad salt-formulas project:
290
291 https://launchpad.net/salt-formulas
292
293Developers wishing to work on the salt-formulas projects should always base
294their work on master branch and submit pull request against specific formula.
295
296You should also subscribe to mailing list (salt-formulas@freelists.org):
297
298 https://www.freelists.org/list/salt-formulas
299
300Any questions or feedback is always welcome so feel free to join our IRC
301channel:
302
303 #salt-formulas @ irc.freenode.net
304
305Read more
306=========
307
308* https://docs.openstack.org/barbican/latest/