nova.conf should not be readable from other users

Bug #1369411 reported by LeileiZhou
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
OpenStack + Chef
Fix Released
Medium
LeileiZhou

Bug Description

Currently, nova.conf mode is set as
[2014-09-10T03:35:47-04:00] INFO: template[/etc/nova/nova.conf] mode changed to 644

However it contains password properties like:
qpid_password=W02CTTp2MV1kY3ZxcHl2cmFn
neutron_admin_password=W02CTTp2MV1iY3JhZmducHgtYXJnamJleA==

To avoid unauthorized user to access it and decode the password, this file will be set as 640.

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Change abandoned on cookbook-openstack-compute (master)

Change abandoned by LeileiZhou (<email address hidden>) on branch: master
Review: https://review.openstack.org/121005

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to cookbook-openstack-compute (master)

Fix proposed to branch: master
Review: https://review.openstack.org/121453

LeileiZhou (leileiz)
Changed in openstack-chef:
assignee: nobody → LeileiZhou (leileiz)
description: updated
Revision history for this message
LeileiZhou (leileiz) wrote :
Download full text (9.5 KiB)

With following conf with 0640, have did some basic testing

[root@c582f1-n34-vm1 Downloads]# ls -la /etc/nova/nova.conf
-rw-r----- 1 nova nova 12520 Sep 5 02:19 /etc/nova/nova.conf
[root@c582f1-n34-vm1 Downloads]# ls -la /etc/neutron/neutron.conf
-rw-r----- 1 neutron neutron 18167 Sep 5 02:17 /etc/neutron/neutron.conf
[root@c582f1-n34-vm1 Downloads]# ls -la /etc/cinder/cinder.conf
-rw-r----- 1 cinder cinder 18940 Sep 5 02:32 /etc/cinder/cinder.conf
[root@c582f1-n34-vm1 Downloads]# ls -la /etc/keystone/keystone.conf
-rw-r----- 1 keystone keystone 45559 Sep 5 02:15 /etc/keystone/keystone.conf
[root@c582f1-n34-vm1 Downloads]# glance image-create --name ubuntu-12.04-amd64 --disk-format qcow2 --container-format bare --file ./ubuntu-12.04-server-cloudimg-amd64-disk1.img
+------------------+--------------------------------------+
| Property | Value |
+------------------+--------------------------------------+
| checksum | e95b30903cad9a58390943aa98931581 |
| container_format | bare |
| created_at | 2014-09-16T05:58:38.779889 |
| deleted | False |
| deleted_at | None |
| disk_format | qcow2 |
| id | 58b1e6ac-1261-4588-99e2-0deb01b8deb4 |
| is_public | False |
| min_disk | 0 |
| min_ram | 0 |
| name | ubuntu-12.04-amd64 |
| owner | 66f9e78ffcc24ebdbc66d77644920456 |
| protected | False |
| size | 261095936 |
| status | active |
| updated_at | 2014-09-16T05:58:40.637377 |
| virtual_size | None |
+------------------+--------------------------------------+
[root@c582f1-n34-vm1 Downloads]# neutron net-create test
Created a new network:
+---------------------------+--------------------------------------+
| Field | Value |
+---------------------------+--------------------------------------+
| admin_state_up | True |
| id | d22a5990-6b28-4333-be31-51caad995c8f |
| name | test |
| provider:network_type | local |
| provider:physical_network | |
| provider:segmentation_id | |
| router:external | False |
| shared | False |
| status | ACTIVE |
| subnets | |
| tenant_id | 66f9e78ffcc24ebdbc66d77644920456 |
+---------------------------+--------------------------------------+
[root@c582f1-n34-vm1 Downloads]# neutron subne...

Read more...

Changed in openstack-chef:
importance: Undecided → Medium
status: New → Confirmed
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to cookbook-openstack-compute (master)

Reviewed: https://review.openstack.org/121453
Committed: https://git.openstack.org/cgit/stackforge/cookbook-openstack-compute/commit/?id=95982ca2265d50ebee49d86a69b54b84d0728309
Submitter: Jenkins
Branch: master

commit 95982ca2265d50ebee49d86a69b54b84d0728309
Author: leileiz <email address hidden>
Date: Mon Sep 15 02:50:12 2014 -0400

    Update nova.conf permission

    contains password properties like:
    qpid_password=
    neutron_admin_password=
    To avoid unauthorized user to access it and decode the password, this file will be set as 640

    Fix bug 1369411
    Change-Id: I66c7d742ce814be7d39e61180e896a9d02ccb800

LeileiZhou (leileiz)
Changed in openstack-chef:
status: Confirmed → Fix Committed
Changed in openstack-chef:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.