author | Edward Pilatowicz <edward.pilatowicz@oracle.com> |
Fri, 10 Mar 2017 17:25:38 -0800 | |
changeset 3528 | 2d9234c9da4e |
parent 3311 | d7bb9c5f4baa |
permissions | -rw-r--r-- |
1618
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
1 |
pkg(5): image packaging system |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
2 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
3 |
LICENSE ACTIONS ACCEPTANCE PROPOSAL |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
4 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
5 |
1. Overview |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
6 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
7 |
License actions provide a way to deliver the textual data |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
8 |
contained within licenses, copyright notices, disclaimers, or |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
9 |
other legally-related documents that need to be associated with |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
10 |
the contents of a package. They also provide a way for packages |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
11 |
to provide guidance to pkg(5) clients as to how this information |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
12 |
should be presented or if it requires acceptance by the user |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
13 |
before the package can be delivered into an image. |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
14 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
15 |
This proposal has the following core goals for the implementation |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
16 |
of license acceptance functionality: |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
17 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
18 |
* Support for non-interactive and interactive package operations |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
19 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
20 |
* Enablement of package creators to provide guidance to pkg(5) |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
21 |
client API consumers as to how licensing or other informational |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
22 |
data should be presented and interacted with |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
23 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
24 |
* Enablement of administrators and users to query and report on |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
25 |
the licensing or other informational data related to packages |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
26 |
contained within an image |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
27 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
28 |
* Enablement of administrators and users to restrict what packages |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
29 |
can be delivered into an image based on the package's provided |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
30 |
licensing information. |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
31 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
32 |
To achieve these goals, changes must be made to the following |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
33 |
pkg(5) components: |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
34 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
35 |
* License Actions |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
36 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
37 |
* Image configuration |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
38 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
39 |
* Client API |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
40 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
41 |
* BUI: pkg.depotd(1m) |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
42 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
43 |
* CLI: pkg(1), pkgsend(1) |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
44 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
45 |
* GUI: packagemanager(1), updatemanager(1) |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
46 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
47 |
This proposal omits the GUI programs as a separate team will |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
48 |
develop and deliver the enhancements related to the changes |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
49 |
discussed here. |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
50 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
51 |
2. License Action attribute changes and additions |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
52 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
53 |
Currently, the license attribute of license actions is not |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
54 |
restrictive enough in what characters are allowed for the |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
55 |
name of the license. To ensure cross-platform compatibility |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
56 |
and consistent naming, it is proposed that the license |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
57 |
attribute's definition be amended as follows: |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
58 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
59 |
license This attribute provides a description for the license |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
60 |
to help describe the license in a meaningful way. Some |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
61 |
examples might include: |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
62 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
63 |
- "GPL v2 only" |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
64 |
- "GPL with Specific Exception" |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
65 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
66 |
A recommended list of descriptions for common open- |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
67 |
source licenses, ang guidelines for custom licenses |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
68 |
will be added to the license action documentation to |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
69 |
encourage consistency. This value must be unique |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
70 |
within a package. |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
71 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
72 |
To support license acceptance functionality, new attributes for |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
73 |
license actions are needed to allow packages to provide guidance |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
74 |
to pkg(5) API consumers: |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
75 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
76 |
class This optional attribute is primarily for use in |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
77 |
filter and query operations. It is intended that |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
78 |
only short, descriptive text be used here. As |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
79 |
such, the content of this value will be limited to |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
80 |
the characters [A-Za-z][A-Za-z0-9 _-.,]*. While |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
81 |
this value is optional, its usage is strongly |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
82 |
encouraged, and so a recommended list of classes |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
83 |
for common open-source licenses, and guidelines |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
84 |
for custom licenses will be added to the license |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
85 |
action documentation. This value must be unique |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
86 |
within a package. |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
87 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
88 |
must-accept A boolean value indicating whether this license |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
89 |
must be accepted by a user before the related |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
90 |
package can be installed or updated. Acceptable |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
91 |
values are "true" or "false". Omission of this |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
92 |
attribute must be considered equivalent to |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
93 |
"false". The reason for this is that many |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
94 |
licenses (especially copyleft ones) do not |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
95 |
require this and clients should not prompt for it |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
96 |
unless provided guidance to do so by the package |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
97 |
creator. |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
98 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
99 |
must-display A boolean value indicating whether the content of |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
100 |
the action's payload must be displayed by clients |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
101 |
during packaging operations. Omission of this |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
102 |
value must be considered equivalent to "false". |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
103 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
104 |
3. Image configuration additions |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
105 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
106 |
Note that changes proposed in this section implicitly depend on |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
107 |
on upcoming changes to the image configuration format for the |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
108 |
client. As such, how policies, etc. are stored is not discussed |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
109 |
here other than to note that they will be stored within the image |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
110 |
configuration. |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
111 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
112 |
To enable administrators and users to effectively manage the |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
113 |
packages contained within an image, users need to be able to |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
114 |
define, on a per-publisher basis, what the behaviour of the |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
115 |
packaging system and clients should be in the following key |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
116 |
areas related to licenses: |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
117 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
118 |
* filtering |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
119 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
120 |
Administrators and users need to be able to define a policy |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
121 |
that can be used to determine what packages are delivered into |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
122 |
an image based on licensing information defined in packages. |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
123 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
124 |
* acceptance |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
125 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
126 |
Administrators and users need to be able to define a policy |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
127 |
that can be used to determine what behaviour clients should |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
128 |
exhibit when encountering a license that requires explicit |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
129 |
acceptance. |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
130 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
131 |
It is believed that a clear delineation between image properties |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
132 |
(which describe the image itself) and policies (which provide |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
133 |
guidance to pkg(5) clients) will be helpful to end-users from a |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
134 |
usage and documentation standpoint. As such, a new policy system |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
135 |
has been devised to allow users to provide guidance to the pkg(5) |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
136 |
system and clients on a per-publisher (and/or global) level based |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
137 |
on the policy in question. Per-publisher values will override |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
138 |
the global value based on the publisher of the package that is |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
139 |
being evaluated by the client API. |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
140 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
141 |
The following new policies will be created, and can all be set at |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
142 |
a global or per-publisher level: |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
143 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
144 |
license-policy A keyword indicating what the behaviour of clients |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
145 |
should be when the license of a package requires |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
146 |
acceptance. The following keywords are supported: |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
147 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
148 |
accept Automatically accepts any license with |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
149 |
must-accept=true after license |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
150 |
filtering has been applied. |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
151 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
152 |
decline Automatically declines any license |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
153 |
with must-accept=false after license |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
154 |
filtering has been applied. |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
155 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
156 |
explicit Requires explicit acceptance of any |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
157 |
licenses with must-accept=true by the |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
158 |
user after licensing filtering has |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
159 |
been applied. This could be |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
160 |
implemented as an interactive prompt, |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
161 |
or by a failure of the client with a |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
162 |
requirement to pass an explicit |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
163 |
command-line option for acceptance. |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
164 |
This is the default value. |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
165 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
166 |
license-accept A list of values that will be used to mark any |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
167 |
license with a matching description or class as |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
168 |
accepted automatically if they require acceptance. |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
169 |
This value is undefined by default. |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
170 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
171 |
license-decline A list of values that will be used to mark any |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
172 |
license with a matching description or class as |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
173 |
declined automatically, regardless of whether they |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
174 |
require acceptance. This value is undefined by |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
175 |
default. |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
176 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
177 |
license-display A keyword indicating what the behaviour of the |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
178 |
client should be when displaying the text of |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
179 |
license actions. The following keywords are |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
180 |
supported: |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
181 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
182 |
all Suggests clients display the text of all |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
183 |
license actions, but must display the text |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
184 |
of license actions that have |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
185 |
must-display=true. |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
186 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
187 |
auto The default value for the image |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
188 |
configuration, which indicates that |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
189 |
clients must display the text of license |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
190 |
actions that have must-display=true. |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
191 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
192 |
The following, existing image properties will become policies and |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
193 |
can only be set on a global basis: |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
194 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
195 |
flush-content-cache-on-success |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
196 |
pursue-latest |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
197 |
require-optional |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
198 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
199 |
The following, existing image properties will become policies and |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
200 |
can be set on a global or per-publisher basis: |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
201 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
202 |
send-uuid |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
203 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
204 |
The following, existing image properties will be removed as they |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
205 |
were never implemented and are being replaced by functionality |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
206 |
discussed in this proposal: |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
207 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
208 |
display-copyrights |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
209 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
210 |
Finally, it should be noted that the existing 'property' subcommands |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
211 |
cannot be used to alter or view policies and the proposed 'policy' |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
212 |
subcommands likewise cannot be used to alter or view properties. |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
213 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
214 |
4. Client API |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
215 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
216 |
4.1 pkg.client.api |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
217 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
218 |
The client API, to enable license acceptance functionality |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
219 |
enforcement and control for clients, will need to change in |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
220 |
the following ways: |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
221 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
222 |
* Plan creation will be changed to analyze and determine license |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
223 |
acceptance and or build a list of licenses and their acceptance |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
224 |
status for packages being installed or updated. |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
225 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
226 |
* The ImagePlan object will have a new method named 'get_licenses' |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
227 |
added. After plan creation is finished, consumers may call this |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
228 |
method to retrieve a list of tuples containing a LicenseInfo |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
229 |
object, whether the license is allowed by image policy, and the |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
230 |
current acceptance status of the license as detailed later. The |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
231 |
default acceptance status of a license will be 'declined' unless |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
232 |
otherwise defined by image policy or operation policy. |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
233 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
234 |
* The ImagePlan object will have a new method named |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
235 |
'set_license_status' which will allow callers to mark the explicit |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
236 |
acceptance of a package's license by a user: |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
237 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
238 |
set_license_status(fmri, class=None, description=None, status) |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
239 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
240 |
Either 'class' or 'description' must be provided. |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
241 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
242 |
* To allow pkg.client.api consumers access to set_license_status |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
243 |
and get_licenses(), equivalent wrapper functions will be added |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
244 |
to the PlanDescription object provided by the API. |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
245 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
246 |
* Two new exceptions will be added to pkg.client.api_errors. The |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
247 |
first will be named 'PlanExecutionError' and be used as a base |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
248 |
exception class for all plan execution errors. The second |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
249 |
exception will be named 'PlanExecutionLicenseError' and will |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
250 |
inherit from the first exception, while being used to indicate |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
251 |
that a licensing related error occurred. |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
252 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
253 |
* Plan execution will be changed to verify that each license |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
254 |
that has must-accept=True has been marked as accepted. If |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
255 |
any license has not been marked as accepted, and requires |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
256 |
acceptance, a 'PlanExecutionLicenseError' will be raised. |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
257 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
258 |
* Plan execution will be changed to record each package that is |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
259 |
part of the operation using pkg.client.history. The full FMRI, |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
260 |
the classes and descriptions identifying the licenses contained |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
261 |
within the package, and acceptance status of each license within |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
262 |
a package will be recorded. The following statuses will be used |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
263 |
to indicate a package's license acceptance: |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
264 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
265 |
* accepted |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
266 |
Indicates that the license was accepted through the API, |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
267 |
presumably by the user. |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
268 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
269 |
* accepted-policy |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
270 |
Indicates that the license was automatically accepted |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
271 |
based on image policy. |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
272 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
273 |
* declined |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
274 |
Indicates that the license required acceptance and was not |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
275 |
marked as accepted. |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
276 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
277 |
* declined-policy |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
278 |
Indicates that the license was automatically rejected |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
279 |
based on image policy. |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
280 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
281 |
* not-applicable |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
282 |
Indicates that the license did not require acceptance and |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
283 |
was not declined by policy. |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
284 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
285 |
4.2 pkg.client.history |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
286 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
287 |
To ease logging of license acceptance information, and to |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
288 |
accurately reflect operation failure, the following changes will |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
289 |
be made to pkg.client.history: |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
290 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
291 |
* New operation result constants will be added: |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
292 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
293 |
RESULT_FAILED_LICENSE_DECLINED |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
294 |
Used to indicate that an operation failed because a |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
295 |
license that required acceptance was not marked as |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
296 |
accepted. |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
297 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
298 |
RESULT_FAILED_LICENSE_POLICY |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
299 |
Used to indicate that an operation failed because a |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
300 |
license was declined based on image policy. |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
301 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
302 |
* log_operation_error() will be changed to ensure that the new |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
303 |
'PlanExecutionLicenseError' triggers an appropriate failure |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
304 |
result as noted above. |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
305 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
306 |
LOG_PKG_OP_INSTALL |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
307 |
LOG_PKG_OP_UPDATE |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
308 |
LOG_PKG_OP_REMOVE |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
309 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
310 |
* A new method to log license status information about a package |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
311 |
will be added: |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
312 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
313 |
log_pkg_license(class=None, description=None, status) |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
314 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
315 |
Either 'class' or 'description' must be provided. |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
316 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
317 |
* A new method to log operation information about a package will |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
318 |
be added: |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
319 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
320 |
log_pkg_operation(operation, old_fmri, new_fmri) |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
321 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
322 |
5. BUI |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
323 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
324 |
5.1. pkg.depotd(1m) |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
325 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
326 |
The pkg.depotd(1m) server that pkg(5) provides will be changed |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
327 |
such that its output matches that of the CLI when listing licenses |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
328 |
as much as possible, such as showing the "license" attribute of |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
329 |
a license action. |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
330 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
331 |
6. CLI |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
332 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
333 |
6.1. pkg(1) |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
334 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
335 |
The pkg(1) client that pkg(5) provides needs to be enhanced to |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
336 |
provide the following functionality: |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
337 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
338 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
339 |
* A mechanism to temporarily override client behaviour, provide |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
340 |
intial policy values during image-creation, or to provide |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
341 |
explicit user intent (such as license acceptance). |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
342 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
343 |
A new command-line option as shown below will be added to the |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
344 |
pkg(1) client that will allow its usage with applicable sub- |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
345 |
commands. Policy names not applicable to the corresponding |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
346 |
subcommand will effectively be ignored (such as pursue-latest |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
347 |
with the 'fix' subcommand). |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
348 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
349 |
--policy <policy-name>=<policy-value> |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
350 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
351 |
The following subcommands will allow this option: |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
352 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
353 |
* contents |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
354 |
* fix |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
355 |
* history |
3311
d7bb9c5f4baa
15748266 SUNBT7140688 pkg authority --help --> traceback
Shawn Walker-Salas <shawn.walker@oracle.com>
parents:
1618
diff
changeset
|
356 |
* update |
1618
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
357 |
* info |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
358 |
* install |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
359 |
* list |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
360 |
* uninstall |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
361 |
* verify |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
362 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
363 |
image-create will also support the --policy option, but instead of |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
364 |
being used as a temporary override, it will be used to specify the |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
365 |
permanent defaults for the image being created. |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
366 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
367 |
* Graceful, informative failure due to license-related exceptions |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
368 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
369 |
If a license-related exception occurs during plan execution, a |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
370 |
failure message similar to the following will be displayed: |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
371 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
372 |
The following packages are not permitted by image policy |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
373 |
due to the current image's license policies: |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
374 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
375 |
-------------------------------------------------- |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
376 |
License A |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
377 |
-------------------------------------------------- |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
378 |
Foo |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
379 |
Bar |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
380 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
381 |
The following packages contain licenses that require |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
382 |
acceptance before they can be installed (use --accept |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
383 |
to accept these licenses): |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
384 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
385 |
-------------------------------------------------- |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
386 |
License B |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
387 |
-------------------------------------------------- |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
388 |
Baz |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
389 |
Quux |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
390 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
391 |
Note that it may be possible for the same license to be marked |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
392 |
as requiring acceptance in one package and not another, and so |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
393 |
the display above may indicate the same license more than |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
394 |
once. |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
395 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
396 |
* Display of licenses that require it during packaging operations |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
397 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
398 |
pkg(1) will be changed to retrieve and display the text of |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
399 |
any licenses that must be displayed or have been requested |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
400 |
for display after plan creation. The default value is based |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
401 |
on image policy as noted in section 3. |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
402 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
403 |
The display of the license text will be the same as the |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
404 |
proposed output for the 'info' subcommand as noted below. |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
405 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
406 |
* Improvement of license display by 'info' subcommand |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
407 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
408 |
Currently, the info subcommand will display license text for |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
409 |
one or more given FMRIs but does so without any visual |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
410 |
separation other than a newline between distinct license text |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
411 |
output, does not indicate which package the license belongs |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
412 |
to, and does not provide any clear indication of the identity |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
413 |
of a license (e.g. CDDL, BSD, etc.). |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
414 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
415 |
The output of this subcommand will be changed so that the |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
416 |
description and class of the license will be shown and a visual |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
417 |
separator will be placed between the output of each license. |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
418 |
The revised output is anticipated to be similar to this: |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
419 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
420 |
------------------------------------------------------------ |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
421 |
Package: Foo |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
422 |
License: copyright |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
423 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
424 |
Copyright 2009 Example Company, Inc. All Rights Reserved. |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
425 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
426 |
------------------------------------------------------------ |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
427 |
Package: Foo |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
428 |
License: Termsv1 "Example Company's License Description v1" |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
429 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
430 |
Lorem ipsum dolor sit amet, consectetur adipiscing elit. |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
431 |
Vivamus in risus sem, id blandit justo. Maecenas nulla massa, |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
432 |
mollis sed lobortis a, placerat vel elit. Quisque eleifend leo |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
433 |
ipsum. Donec feugiat gravida molestie. Nulla facilisi. Nullam |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
434 |
sit amet ligula sed mauris tempor fermentum quis at purus. |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
435 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
436 |
------------------------------------------------------------ |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
437 |
Package: Bar |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
438 |
License: Termsv2 "Example Company's License Description v2" |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
439 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
440 |
Lorem ipsum dolor sit amet, consectetur adipiscing elit. |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
441 |
Vivamus in risus sem, id blandit justo. Maecenas nulla massa, |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
442 |
mollis sed lobortis a, placerat vel elit. |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
443 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
444 |
* A set-policy subcommand will be added to allow setting policy |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
445 |
values that functions as follows: |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
446 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
447 |
set-policy [-p publisher] policy-name policy-value ... ... |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
448 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
449 |
If -p is not provided, the global policy value will be changed. |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
450 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
451 |
One or more pairs of policy name and policy value may be provided |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
452 |
provided to this command to allow setting multiple values using a |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
453 |
single command invocation. |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
454 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
455 |
Some options may not be set at the publisher level and this will |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
456 |
result in an error message such as: |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
457 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
458 |
$ pkg set-policy -p opensolaris.org flush-content-cache-on-success |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
459 |
pkg: set-policy: flush-content-cache-on-success is a global policy |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
460 |
and cannot be set on a per-publisher basis. |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
461 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
462 |
* An unset-policy subcommand will be added to allow unsetting or |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
463 |
resetting policy values that functions as follows: |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
464 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
465 |
unset-policy [-p publisher] policy-name ... |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
466 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
467 |
If -p is not provided, the global policy value will be changed. |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
468 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
469 |
Some options may not be set at the publisher level and this will |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
470 |
result in an error message such as: |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
471 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
472 |
$ pkg unset-policy -p opensolaris.org \ |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
473 |
flush-content-cache-on-success |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
474 |
pkg: unset-policy: flush-content-cache-on-success is a global |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
475 |
policy and cannot be unset on a per-publisher basis. |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
476 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
477 |
* A policy subcommand will be added for retrieving policy values |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
478 |
that functions as follows: |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
479 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
480 |
policy [-H] [-p publisher] policy-name ... |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
481 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
482 |
If -p is not provided, then all matching policy values will be |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
483 |
shown instead of those of a specific publisher. 'All' may be |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
484 |
specified to show global values that do not apply to a specific |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
485 |
publisher. |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
486 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
487 |
If -H is provided, headers will be omitted. |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
488 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
489 |
One or more policy names may be specified separated by whitespace. |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
490 |
If no policy-names are specified, all policies will be displayed. |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
491 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
492 |
Example output: |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
493 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
494 |
$ pkg policy |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
495 |
PUBLISHER POLICY VALUE |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
496 |
All license-accept |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
497 |
All license-decline |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
498 |
All license-display auto |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
499 |
All license-policy decline |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
500 |
opensolaris.org license-accept accept |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
501 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
502 |
$ pkg policy license-accept |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
503 |
PUBLISHER POLICY VALUE |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
504 |
All license-accept |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
505 |
opensolaris.org license-accept accept |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
506 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
507 |
$ pkg policy license-accept license-display |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
508 |
PUBLISHER POLICY VALUE |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
509 |
All license-accept |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
510 |
All license-display auto |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
511 |
opensolaris.org license-accept accept |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
512 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
513 |
$ pkg policy license-accept -H |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
514 |
All license-accept |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
515 |
opensolaris.org license-accept accept |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
516 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
517 |
$ pkg policy license-accept -p All |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
518 |
PUBLISHER POLICY VALUE |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
519 |
All license-accept decline |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
520 |
|
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
521 |
$ pkg policy license-accept -p opensolaris.org |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
522 |
PUBLISHER POLICY VALUE |
04f7471c9e72
5943 add 'must-accept' attribute to license actions
Shawn Walker <srw@sun.com>
parents:
diff
changeset
|
523 |
opensolaris.org license-accept accept |