summaryrefslogtreecommitdiffstats
path: root/services/audioflinger/AudioFlinger.cpp
diff options
context:
space:
mode:
authorJean-Michel Trivi <jmtrivi@google.com>2014-12-12 16:23:43 -0800
committerJean-Michel Trivi <jmtrivi@google.com>2014-12-15 18:13:39 -0800
commit97bb33f58d742539f3382583d7978fca71ffa2d5 (patch)
treebe3e26027b66bfc605a45af032fb91de1bdb7c7a /services/audioflinger/AudioFlinger.cpp
parent6e430fbd927b9cc043639eb728ddc921392a60e8 (diff)
downloadframeworks_av-97bb33f58d742539f3382583d7978fca71ffa2d5.zip
frameworks_av-97bb33f58d742539f3382583d7978fca71ffa2d5.tar.gz
frameworks_av-97bb33f58d742539f3382583d7978fca71ffa2d5.tar.bz2
Fix permission check for audio recording
Define input types covering the different usecases for audio recording, and check the corresponding permissions when starting to record. Move the permission check from audio flinger to audio policy, as only the policy has the information to determine which permission to enforce. Fix missing permission when an application records audio and the audio is injected by an external policy. Bug 18736417 Change-Id: If7ec040502242c990ac8ea464db484339bdce573
Diffstat (limited to 'services/audioflinger/AudioFlinger.cpp')
-rw-r--r--services/audioflinger/AudioFlinger.cpp7
1 files changed, 0 insertions, 7 deletions
diff --git a/services/audioflinger/AudioFlinger.cpp b/services/audioflinger/AudioFlinger.cpp
index 8acfc07..ccc05a1 100644
--- a/services/audioflinger/AudioFlinger.cpp
+++ b/services/audioflinger/AudioFlinger.cpp
@@ -1433,13 +1433,6 @@ sp<IAudioRecord> AudioFlinger::openRecord(
goto Exit;
}
- if (deviceRequiresCaptureAudioOutputPermission(thread->inDevice())
- && !captureAudioOutputAllowed()) {
- ALOGE("openRecord() permission denied: capture not allowed");
- lStatus = PERMISSION_DENIED;
- goto Exit;
- }
-
pid_t pid = IPCThreadState::self()->getCallingPid();
client = registerPid(pid);