openstack相关知识
ec2 credentials
创建ec2的密钥可指定project,user等,创建/删除/查询命令参考:
https://docs.openstack.org/python-openstackclient/pike/cli/command-objects/ec2-credentials.html
v3 credentials
与ec2 credentials相比,增加了可指定密钥的值,例如:
openstack credential create --type ec2 --project haj haj '{"access": "haj-haj-ak","secret":"haj-haj-sk","trust_id": null}'
https://docs.openstack.org/python-openstackclient/pike/cli/command-objects/credential.html
barbican
https://docs.openstack.org/barbican/latest/
https://www.cnblogs.com/jonc/p/11194716.html
测试barbican功能:
生成secret:
openstack secret store --name mysecret --payload j4=]d21
获取secret:
openstack secret get http://10.0.2.15:9311/v1/secrets/655d7d30-c11a-49d9-a0f1-34cdf53a36fa
barbican
https://docs.openstack.org/barbican/latest/
https://www.cnblogs.com/jonc/p/11194716.html
测试barbican功能:
生成secret:
openstack secret store --name mysecret --payload j4=]d21
获取secret:
openstack secret get http://10.0.2.15:9311/v1/secrets/655d7d30-c11a-49d9-a0f1-34cdf53a36fa
获取token
https://www.jianshu.com/p/0aaeb9358e11
结论
1.使用keystone来做身份校验相较于ceph本地身份校验相比效率低,需要curl到keystone服务器。
2.keystone不能实现同一个ceph user 下的多个key有不同的bucket访问权限。
3.使用barbican服务器加密:首先用户去barbican创建key对(key-id/actual-key),上传需加密的文件时带上key-id参数,key-id永久有效可多次/多人使用,下载加密的文件无特殊要求。
4.用户端加密:用户上传需加密的文件时带上key/key-MD5,key/key-MD5永久有效可多次/多人使用,下载加密的文件时也需要带上key/key-MD5。