VSHL-Core Permissions issue #permissions #automotive #voiceagents #vshl-core


Ezequiel Cervantes
 

Hi all,

 

I’m need help figuring out how I can get VSHL-CORE to properly register the Alexa voice agent. I’m seeing the permissions issue below.

 

I built an AGL image from master (Icefish) without the Alexa voice agent. I built the Alexa voice agent on my own using the Icefish toolchain and our current Alexa Auto SDK. I applied all the patches that you guys currently apply

 

https://git.automotivelinux.org/AGL/meta-agl-devel/tree/meta-speech-framework/meta-aac

 

I also modified the Alexa config json as needed. The alexa voice agent starts up, but I can the vshl core plugin does not read the voice-high.json that I placed under /etc/xdg/AGL/ 

I also placed alexa.json to /etc/xdg/AGL/voiceagents/ (following what the receipes are doing).  

 

Apr 07 22:00:51 m3ulcb afbd-vshl-core[59202]:  WARNING: [API vshl-core] CTL-LOAD-CONFIG:REQUIRE Fail to get=signal-composer [/usr/src/debug/libappcontroller/9.90.0-r0/git/ctl-lib/ctl-config.c:115,DispatchRequireOneApi]

Apr 07 22:00:51 m3ulcb audit[59202]: AVC lsm=SMACK fn=smack_inode_getattr action=denied subject="User::App::vshl-core" object="System" requested=r pid=59202 comm="afbd-vshl-core" path="/etc/xdg/AGL/voice-high.json" dev="mmcblk1p1" ino=980

Apr 07 22:00:51 m3ulcb afbd-vshl-core[59202]: terminate called after throwing an instance of 'std::filesystem::__cxx11::filesystem_error'

Apr 07 22:00:51 m3ulcb afbd-vshl-core[59202]:   what():  filesystem error: status: Permission denied [/etc/xdg/AGL/voice-high.json]

Apr 07 22:00:51 m3ulcb afbd-vshl-core[59202]:  ERROR: Terminating signal 6 received: Aborted [/usr/src/debug/af-binder/master+gitAUTOINC+7901c6dada-r0/git/src/sig-monitor.c:351,on_signal_terminate]

Apr 07 22:00:51 m3ulcb afbd-vshl-core[59202]:  ERROR: BACKTRACE due to signal Aborted/6:

Apr 07 22:00:51 m3ulcb afbd-vshl-core[59202]:  [1/22] /usr/lib/libstdc++.so.6(_ZN9__gnu_cxx27__verbose_terminate_handlerEv+0x188) [0xffffbd0defb0]

Apr 07 22:00:51 m3ulcb afbd-vshl-core[59202]:  [2/22] /usr/lib/libstdc++.so.6(+0x9dd14) [0xffffbd0dcd14]

Apr 07 22:00:51 m3ulcb afbd-vshl-core[59202]:  [3/22] /usr/lib/libstdc++.so.6(+0x9dd60) [0xffffbd0dcd60]

Apr 07 22:00:51 m3ulcb afbd-vshl-core[59202]:  [4/22] /usr/lib/libstdc++.so.6(__cxa_rethrow+0) [0xffffbd0dd020]

Apr 07 22:00:51 m3ulcb afbd-vshl-core[59202]:  [5/22] /usr/lib/libstdc++.so.6(_ZNSt10filesystem6statusERKNS_7__cxx114pathE+0xa4) [0xffffbd18bbd4]

Apr 07 22:00:51 m3ulcb afbd-vshl-core[59202]:  [6/22] /var/local/lib/afm/applications/vshl-core/lib/plugins/vshl-core-api.ctlso(loadVoiceAgentsConfig+0x14c) [0xffffbd24224c]

 

Is there anything additional I need to do to solve that permission error.

 

Thanks,

 

-eze

Alexa Auto SDK


Scott Murray
 

On Wed, 8 Apr 2020, Ezequiel Cervantes via lists.automotivelinux.org wrote:

Hi all,

I’m need help figuring out how I can get VSHL-CORE to properly register the Alexa voice agent. I’m seeing the permissions issue below.

I built an AGL image from master (Icefish) without the Alexa voice agent. I built the Alexa voice agent on my own using the Icefish toolchain ( https://download.automotivelinux.org/AGL/release/icefish/latest/m3ulcb-nogfx/deploy/sdk/poky-agl-glibc-x86_64-agl-image-ivi-crosssdk-aarch64-toolchain-9.0.0.sh ) and our current Alexa Auto SDK. I applied all the patches that you guys currently apply

https://git.automotivelinux.org/AGL/meta-agl-devel/tree/meta-speech-framework/meta-aac

I also modified the Alexa config json as needed. The alexa voice agent starts up, but I can the vshl core plugin does not read the voice-high.json ( https://git.automotivelinux.org/AGL/meta-agl-devel/tree/meta-speech-framework/meta-aac/recipes-apis/alexa-voiceagent-service/alexa-voice-high-config/voice-high.json ) that I placed under /etc/xdg/AGL/

I also placed alexa.json ( https://git.automotivelinux.org/AGL/meta-agl-devel/tree/meta-speech-framework/meta-aac/recipes-apis/alexa-voiceagent-service/alexa-voiceagent-service/alexa.json ) to /etc/xdg/AGL/voiceagents/ (following what the receipes are doing).
[snip]
Is there anything additional I need to do to solve that permission error.
Any files you create down in /etc/xdg need to have their SMACK label set
to '_' (floor permission) so that the binding can read them, e.g.

chsmack -a _ /etc/xdg/AGL/voiceagents/alexa.json

That should fix the permission problem. This isn't required when building
the images with the agl-voiceagent-alexa feature because that label is the
default for those files.

Scott


Ezequiel Cervantes
 

Thanks Scott! That solved my issue.