Error launching a second app from a web application

Fixed

Description

Web applications making use of the afm API to launch other webapps (currently html5-launcher and application-list ) are only able to launch one webapp, after that whatever you try to launch (web or native) gets this failure:

Oct 16 16:38:54 qemux86-64 tinyproxy[648]: Connect (file descriptor 13): localhost [::1]
Oct 16 16:38:54 qemux86-64 tinyproxy[648]: Request (file descriptor 13): CONNECT localhost:31022 HTTP/1.1
Oct 16 16:38:54 qemux86-64 audit[648]: AVC lsm=SMACK fn=smack_socket_sock_rcv_skb action=denied subject="User::App::webapps-youtube" object="User::App::webapps-application-list" requested=w pid=648 comm="tinyproxy" saddr=127.0.0.1 src=37618 daddr=127.0.0.1 dest=31022 netif=lo
Oct 16 16:38:54 qemux86-64 tinyproxy[648]: No upstream proxy for localhost
Oct 16 16:38:54 qemux86-64 tinyproxy[648]: opensock: opening connection to localhost:31022
Oct 16 16:38:54 qemux86-64 tinyproxy[648]: opensock: getaddrinfo returned for localhost:31022
Oct 16 16:38:54 qemux86-64 kernel: audit: type=1400 audit(1571243934.645:11): lsm=SMACK fn=smack_socket_sock_rcv_skb action=denied subject="User::App::webapps-youtube" object="User::App::webapps-application-list" requested=w pid=648 comm="tinyproxy" saddr=127.0.0.1 src=37618 daddr=127.0.0.1 dest=31022 netif=lo
Oct 16 16:38:55 qemux86-64 kernel: audit: type=1400 audit(1571243935.681:12): lsm=SMACK fn=smack_socket_sock_rcv_skb action=denied subject="User::App::webapps-youtube" object="User::App::webapps-application-list" requested=w pid=9 comm="ksoftirqd/0" saddr=127.0.0.1 src=37618 daddr=127.0.0.1 dest=31022 netif=lo
Oct 16 16:38:55 qemux86-64 audit[9]: AVC lsm=SMACK fn=smack_socket_sock_rcv_skb action=denied subject="User::App::webapps-youtube" object="User::App::webapps-application-list" requested=w pid=9 comm="ksoftirqd/0" saddr=127.0.0.1 src=37618 daddr=127.0.0.1 dest=31022 netif=lo
Oct 16 16:38:55 qemux86-64 tinyproxy[648]: opensock: Could not establish a connection to localhost
Oct 16 16:38:55 qemux86-64 tinyproxy[648]: no entity
Oct 16 16:38:55 qemux86-64 kernel: audit: type=1300 audit(1571243934.645:11): arch=c000003e syscall=42 success=no exit=-113 a0=e a1=5628654153a0 a2=10 a3=4000 items=0 ppid=612 pid=648 auid=4294967295 uid=1001 gid=1001 euid=1001 suid=1001 fsuid=1001 egid=1001 sgid=1001 fsgid=1001 tty=(none) ses=4294967295 comm="tinyproxy" exe="/usr/bin/tinyproxy" subj=User::App::webapps-youtube key=(null)
Oct 16 16:38:55 qemux86-64 kernel: audit: type=1327 audit(1571243934.645:11): proctitle=74696E7970726F7879002D70003534393537
Oct 16 16:38:54 qemux86-64 audit[648]: SYSCALL arch=c000003e syscall=42 success=no exit=-113 a0=e a1=5628654153a0 a2=10 a3=4000 items=0 ppid=612 pid=648 auid=4294967295 uid=1001 gid=1001 euid=1001 suid=1001 fsuid=1001 egid=1001 sgid=1001 fsgid=1001 tty=(none) ses=4294967295 comm="tinyproxy" exe="/usr/bin/tinyproxy" subj=User::App::webapps-youtube key=(null)
Oct 16 16:38:54 qemux86-64 audit: PROCTITLE proctitle=74696E7970726F7879002D70003534393537
Oct 16 16:38:55 qemux86-64 WebAppMgr[419]: [1016/163855.686962:INFO:CONSOLE(77)] "WebSocket connection to 'ws://localhost:31022/api?x-afb-token=HELLO' failed: Establishing a tunnel via proxy server failed.", source: http://localhost:31022/AFB.js (77)

Additional info:

qemux86-64:~# ps auxZ
LABEL                      USER     PID %CPU %MEM  VSZ  RSS TTY STAT START TIME COMMAND
...
User::App::webapps-youtube agl-dri+ 648  0.0  0.4 5204 4320   ?    S 16:36 0:00 tinyproxy -p 54957

The port for webapps-youtube is 31043.

The port for webapps-application-list is 31022.

Environment

None

Activity

Show:

Walt Miner 
April 9, 2020 at 3:47 PM

Close for Icefish 9.0.1 release

Walt Miner 
April 7, 2020 at 10:36 PM

SRCREV bump merged.

 

Walt Miner 
February 19, 2020 at 9:16 PM

Waiting for SRCREV bump to be integrated for Icefish  https://gerrit.automotivelinux.org/gerrit/c/AGL/meta-agl-devel/+/24046 

Antia Puentes 
February 18, 2020 at 8:47 AM

Created https://lf-automotivelinux.atlassian.net/browse/SPEC-3185#icft=SPEC-3185 to track the TODO mentioned by Jacobo in the comment above. We can mark this issue as resolved.

Jacobo Aragunde Pérez 
January 29, 2020 at 4:22 AM

This should be gone after this PR:

  https://github.com/webosose/wam/pull/29

Let's not forget about the TODO in that commit.

Details

Assignee

Reporter

Labels

Affects versions

Priority

Created October 16, 2019 at 4:55 PM
Updated April 9, 2020 at 3:47 PM
Resolved February 18, 2020 at 8:47 AM

Flag notifications