← Back to team overview

ubuntu-phone team mailing list archive

Re: [Development] Override user agent string in WebApp

 

On Thu, Aug 13, 2015 at 10:27:41AM -0400, Robert Schroll wrote:
> On Thu, Aug 13, 2015 at 9:48 AM, Peter Bittner
> <peter.bittner@xxxxxxx> wrote:
> >It seems like adding "push-notification-client" to the .apparmor file
> >doesn't make push notifications work in a WebApp. Is the documentation
> >on [1] only applicable for native apps?
> >
> >[...]
> >
> >(I must confess, I've simply added the value to the .apparmor file and
> >restarted the WebApp (after clearing cache and configuration). I've
> >not tested reinstalling a .click package e.g. via the Ubuntu Store.)
> 
> That's not enough.  The JSON-formatted file included in your click
> package is not read by apparmor.  Instead, it is used to create the
> actual apparmor configuration file (in /var/lib/apparmor/profiles)
> during the installation process.  To have a new configuration file
> created from your JSON file, you must either reinstall the click
> package or run `sudo aa-clickhook -f` after changing the file on the
> device.
> 
> That said, I have no idea if push notifications work with webapps.
> Apparmor denials are logged in /var/log/syslog.  If it doesn't work,
> check there to see whether apparmor blocked it or not.

I'm not entirely sure it does work with webapps, but the push server
needs to know about this and that is not done through apparmor.

There is more to be done on the client side and the server would need to
know about this as well

https://developer.ubuntu.com/en/start/platform/guides/push-notifications-client-guide/
https://developer.ubuntu.com/en/start/platform/guides/push-notifications-server-guide/



Follow ups

References