Merge lp:~mandel/ubuntu-touch-session/pulse-trust-store into lp:ubuntu-touch-session

Proposed by Manuel de la Peña on 2015-08-25
Status: Merged
Approved by: Alfonso Sanchez-Beato on 2015-09-01
Approved revision: 279
Merged at revision: 275
Proposed branch: lp:~mandel/ubuntu-touch-session/pulse-trust-store
Merge into: lp:ubuntu-touch-session
Diff against target: 95 lines (+67/-0)
4 files modified
debian/changelog (+8/-0)
touch.pa (+5/-0)
upstart-session/cameraservice-trust-stored.conf (+33/-0)
upstart-session/pulseaudio-trust-stored.conf (+21/-0)
To merge this branch: bzr merge lp:~mandel/ubuntu-touch-session/pulse-trust-store
Reviewer Review Type Date Requested Status
Alfonso Sanchez-Beato Approve on 2015-09-01
Ken VanDine 2015-08-25 Needs Fixing on 2015-08-25
Review via email: mp+269044@code.launchpad.net

This proposal supersedes a proposal from 2015-08-07.

Commit Message

* Add upstart job for trust-store for camera service
* Add upstart job for trust-store for pulseaudio
* Load trust-store module for pulseaudio

Description of the Change

* Add upstart job for trust-store for camera service
* Add upstart job for trust-store for pulseaudio
* Load trust-store module for pulseaudio

To post a comment you must log in.
279. By Manuel de la Peña on 2015-08-25

Tabs vs spaces.

Ken VanDine (ken-vandine) wrote :

Please drop the debian/changelog entry, we can't build it in the silo like this.

review: Needs Fixing
review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'debian/changelog'
2--- debian/changelog 2015-08-03 13:33:43 +0000
3+++ debian/changelog 2015-08-25 11:13:15 +0000
4@@ -1,3 +1,11 @@
5+ubuntu-touch-session (0.108+15.10.20150807-0ubuntu1) UNRELEASED; urgency=medium
6+
7+ * Add upstart job for trust-store for camera service
8+ * Add upstart job for trust-store for pulseaudio
9+ * Load trust-store module for pulseaudio
10+
11+ -- Alfonso Sanchez-Beato (email Canonical) <alfonso.sanchez-beato@canonical.com> Fri, 07 Aug 2015 17:23:11 +0200
12+
13 ubuntu-touch-session (0.108+15.10.20150803-0ubuntu1) wily; urgency=medium
14
15 [ Tiago Salem Herrmann ]
16
17=== modified file 'touch.pa'
18--- touch.pa 2015-03-31 02:49:56 +0000
19+++ touch.pa 2015-08-25 11:13:15 +0000
20@@ -42,6 +42,11 @@
21 load-module module-droid-card voice_virtual_stream=true
22 .endif
23
24+### Automatically load the trust-store module
25+.ifexists module-trust-store.so
26+load-module module-trust-store
27+.endif
28+
29 ### Fake sink and source used by HSP
30 load-module module-null-sink sink_name=sink.fake.sco rate=8000 channels=1
31 load-module module-null-source source_name=source.fake.sco rate=8000 channels=1
32
33=== added file 'upstart-session/cameraservice-trust-stored.conf'
34--- upstart-session/cameraservice-trust-stored.conf 1970-01-01 00:00:00 +0000
35+++ upstart-session/cameraservice-trust-stored.conf 2015-08-25 11:13:15 +0000
36@@ -0,0 +1,33 @@
37+description "CameraService Trust Store Daemon"
38+
39+start on started dbus and xsession SESSION=ubuntu-touch
40+stop on runlevel [06]
41+
42+respawn
43+
44+script
45+ timeout=800
46+ service_socket=/dev/socket/camera_service/camera_service_to_trust
47+ # loop and then exit, if camera service isnt up after 80 sec
48+ # it is likely not starting at all (or not there)
49+ while [ ! -e $service_socket ]; do
50+ sleep 0.1
51+ if [ "$timeout" -le 0 ]; then
52+ stop; exit 0
53+ fi
54+ timeout=$(($timeout - 1))
55+ done
56+
57+ # Extra security to make sure the service is bound to the sockec
58+ # TODO check if needed by inspection of trust store library / camera service
59+ sleep 1
60+
61+ exec /usr/bin/trust-stored-skeleton \
62+ --remote-agent UnixDomainSocketRemoteAgent --endpoint=$service_socket \
63+ --local-agent MirAgent \
64+ --trusted-mir-socket=/var/run/user/$(id -u)/mir_socket_trusted \
65+ --for-service CameraService \
66+ --with-text-domain CameraService \
67+ --store-bus session \
68+ --disable-whitelisting=yes
69+end script
70
71=== added file 'upstart-session/pulseaudio-trust-stored.conf'
72--- upstart-session/pulseaudio-trust-stored.conf 1970-01-01 00:00:00 +0000
73+++ upstart-session/pulseaudio-trust-stored.conf 2015-08-25 11:13:15 +0000
74@@ -0,0 +1,21 @@
75+description "Pulseaudio Trust Store Daemon"
76+
77+start on started pulseaudio
78+stop on stopped pulseaudio
79+
80+respawn
81+
82+script
83+ # Extra security until trust-stored handles DBus name owner changes
84+ # for the service
85+ sleep 2
86+
87+ exec /usr/bin/trust-stored-skeleton \
88+ --remote-agent DBusRemoteAgent --bus=session \
89+ --local-agent MirAgent \
90+ --trusted-mir-socket=/var/run/user/$(id -u)/mir_socket_trusted \
91+ --for-service PulseAudio \
92+ --with-text-domain PulseAudio \
93+ --store-bus session \
94+ --disable-whitelisting=yes
95+end script

Subscribers

People subscribed via source and target branches