On 08/11/2013 09:12 PM, Ted Gould wrote: > Hey folks, > > I know that basically the App ID format is this: > > $(pkg)_$(app)_$(version) > > But what I haven't seen is a formal definition of things like which characters > are allowed in each section. Does such a thing exist? I'm guessing everyone > has coded different implementation of that check, we should probably make sure > that they align. >
$(pkg)_$(app)_$(version) is also what is used for the AppArmor profile name, so yes, we need to agree. :) Based on conversations elsewhere, this is what we have defined for AppArmor easyprof[1]: "... a name that consists only of lower case letters (a-z), upper case letters (A-Z), digits (0-9), plus (+) and minus (-) signs, periods (.), colons (:), underscores (_) and tildes (~) (essentially a combination of the allowed characters for Ubuntu package names and versions, plus underscores)" Click uses deb files and dpkg underneath, so many of the rules come from Debian/Ubuntu policy. Ie: * 'pkg' is any legal character for a Debian package[2] * 'version' is any legal character in a Debian version[3] * 'app' doesn't have an any Debian policy surrounding it that I am aware of, but we've defined it elsewhere as anything in the set of characters in "profile name" (above) except '_' since it is a delimiter I noticed that the click documentation[4] does not formally define this, but I believe it should. I will prepare a merge request. [1]https://wiki.ubuntu.com/SecurityTeam/Specifications/ApplicationConfinement/Manifest [2]http://www.debian.org/doc/debian-policy/ch-controlfields.html#s-f-Source [3]http://www.debian.org/doc/debian-policy/ch-controlfields.html#s-f-Version [4]http://bazaar.launchpad.net/~click-hackers/click/trunk/view/head:/doc/file-format.rst -- Jamie Strandboge http://www.ubuntu.com/
signature.asc
Description: OpenPGP digital signature
-- Mailing list: https://launchpad.net/~ubuntu-appstore-developers Post to : ubuntu-appstore-developers@lists.launchpad.net Unsubscribe : https://launchpad.net/~ubuntu-appstore-developers More help : https://help.launchpad.net/ListHelp