Merge lp:~jtv/maas/pkg-bug-1089802 into lp:~maas-maintainers/maas/packaging

Proposed by Jeroen T. Vermeulen
Status: Merged
Approved by: Jeroen T. Vermeulen
Approved revision: no longer in the source branch.
Merged at revision: 159
Proposed branch: lp:~jtv/maas/pkg-bug-1089802
Merge into: lp:~maas-maintainers/maas/packaging
Diff against target: 31 lines (+9/-6)
1 file modified
debian/maas-cluster-controller.postinst (+9/-6)
To merge this branch: bzr merge lp:~jtv/maas/pkg-bug-1089802
Reviewer Review Type Date Requested Status
Gavin Panella (community) Approve
Review via email: mp+139645@code.launchpad.net

Commit message

Make maas_cluster.conf non-world-readable, now that it contains the cluster UUID.

Description of the change

We like to keep the cluster uuid confidential. But now that it's been duplicated into maas_cluster.conf, it is exposed to anyone with filesystem access on the cluster controller. This branch fixes that.

To post a comment you must log in.
Revision history for this message
Gavin Panella (allenap) :
review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'debian/maas-cluster-controller.postinst'
2--- debian/maas-cluster-controller.postinst 2012-12-12 17:44:39 +0000
3+++ debian/maas-cluster-controller.postinst 2012-12-13 10:11:25 +0000
4@@ -69,12 +69,6 @@
5 if [ "$1" = "configure" ] && [ -z "$2" ]; then
6 # logging
7 create_log_dir
8-
9- # The local celery config may contain a private cluster UUID. Only
10- # maas can read it; only root can write it.
11- chown root:maas /etc/maas/maas_local_celeryconfig_cluster.py
12- chmod 0640 /etc/maas/maas_local_celeryconfig_cluster.py
13-
14 configure_maas_tgt
15 fi
16
17@@ -97,6 +91,15 @@
18 fi
19
20 if [ "$1" = "configure" ]; then
21+ # These config files may contain a private cluster UUID. Only maas
22+ # can read them; only root can write them
23+ chown root:maas \
24+ /etc/maas/maas_local_celeryconfig_cluster.py \
25+ /etc/maas/maas_cluster.conf
26+ chmod 0640 \
27+ /etc/maas/maas_local_celeryconfig_cluster.py \
28+ /etc/maas/maas_cluster.conf
29+
30 configure_cluster_uuid
31 fi
32

Subscribers

People subscribed via source and target branches