permissions.rst 4.65 KB
Newer Older
1
2
.. _permissions:

Quentin  LAMY-BESNIER's avatar
Quentin LAMY-BESNIER committed
3
Permissions attached to a data source
4
================================================
5

Bryan  BRANCOTTE's avatar
Bryan BRANCOTTE committed
6
A data source can not only be public, or private. It can also be shared with specific users, and even allow some to edit this data source. Here after are the roles a user can have regarding a data source, and what possibility come with each role.
7

8
Note that when a data source is changed, its owner is notified, according to his/her :ref:`settings<email-changes-label>`.
9
10
11
12

Roles
----------------------------------------

13
14
.. _owner-role-label:

15
16
17
Owner
~~~~~~~~

Bryan  BRANCOTTE's avatar
Bryan BRANCOTTE committed
18
The owner of the :term:`data source` can see all information, and make all possible changes, such as:
19

20
 * Edit the list of :term:`viruses <virus>` and :term:`hosts <host>`
21
 * Edit the information of a :term:`data source`
22
 * Edit the list of viewer/editor
23
 * Edit the responses
24
 * Edit the :ref:`mapping <mapping-label>`
25
 * Upload a new version of the data source
26
 * Delete :term:`viruses <virus>` and :term:`hosts <host>`
27
 * Restore the :term:`data source` to a previous state (see :ref:`history`)
28
29
30
 * Delete the data source
 * Transfer ownership to an other user

31
32
.. _editor-role-label:

33
34
35
36
37
Editor
~~~~~~~~

An editor of the :term:`data source` can deeply changes the :term:`data source`, such as:

38
 * Edit the list of :term:`viruses <virus>` and :term:`hosts <host>`
39
 * Edit the information of a :term:`data source` (except the list of viewer/editor)
40
 * Edit the responses, and see them
41
 * Edit the :ref:`mapping <mapping-label>`
42
 * Upload a new version of the data source
43
 * Delete :term:`viruses <virus>` and :term:`hosts <host>`
44
 * Restore the :term:`data source` to a previous state (see :ref:`history`)
45
46
47

Although, an editor cannot:

48
 * See the list of viewer/editor
49
50
51
52
53
54
55
56
 * Delete the data source
 * Transfer ownership to an other user

Viewer
~~~~~~~~

A viewer of the :term:`data source` **can not** edit it. A viewer can:

57
 * See the list of  :term:`viruses <virus>` and :term:`hosts <host>`.
58
 * See the information of a :term:`data source` (except the the list of viewer/editor)
59
60
61
62
63
64
 * See the responses
 * See the :ref:`mapping <mapping-label>`

A viewer cannot:

 * Edit anything
65
 * See the list of viewer/editor
66

Bryan  BRANCOTTE's avatar
Bryan BRANCOTTE committed
67
When a data source is public, any users are considered as viewers.
68

69
70
.. _curator-role-label:

71
72
73
74
75
76
Curator
~~~~~~~~

A curator can perform changes on **public** data sources even if he/she is not an editor of the data source. The mission
of a curator is to keep naming between viruses, hosts coherent, but also edit data source details when needed.

Bryan  BRANCOTTE's avatar
Bryan BRANCOTTE committed
77
 * Edit the :term:`viruses <virus>` and :term:`hosts <host>`
78
 * Edit the information of a :term:`data source` (except the the list of viewer/editor)
Bryan  BRANCOTTE's avatar
Bryan BRANCOTTE committed
79
 * Edit the mapping
80
 * Switch a :term:`data source` back to private (but not the opposite)
81
82
83

Although, an curator cannot:

Bryan  BRANCOTTE's avatar
Bryan BRANCOTTE committed
84
85
 * Edit the responses
 * Delete :term:`viruses <virus>` or :term:`hosts <host>`
86
 * See the list of viewer/editor, and thus cannot edit it either
Bryan  BRANCOTTE's avatar
Bryan BRANCOTTE committed
87
88
 * Restore the data source to a previous version
 * Download a previous version
89
90
 * Delete the data source
 * Transfer ownership to an other user
91

92
93
94
95
96
97
98
99
100
101
102
103

Permissions with viruses, hosts, and responses
-----------------------------------------------

Permissions of a user regarding a host/virus/response come from the permissions this user have with the data source associated.

Let us consider a virus, if a user can see it, it means that this virus is associated with a data source which can be seen by this user. So does for hosts, and/or edition.

If a user can see a response, it obviously is because this response is in a data source visible to the user.



Quentin  LAMY-BESNIER's avatar
Quentin LAMY-BESNIER committed
104
Consequences of someone editing a virus/host
105
106
--------------------------------------------

107
Let us consider a virus ``MyT4`` present in multiple data source (``ds_1``, ``ds_2``, ..., ``ds_n``). If an owner/curator/editor of one of this data source (``ds_1``) decide to rename this virus ``MyT4`` into ``T4``, all responses formerly associated to  ``MyT4`` in  ``d_1`` are now associated to  ``T4`` in  ``d_1``, but *only in* ``d_1``. It means that ``MyT4`` is still associated to data source ``ds_2``, ..., ``ds_n``.
108
109
110
111
112
113
114


.. graphviz::
   :align: center
   :caption: Before

    digraph G {
115
116
117
118
119
120
121
122
123
124
        dsp [label="Public data source"]
        ds_1 [ color=blue ];
        ds_2
        ds_3 [label="..."]
        ds_n
        ds_1 -> MyT4;
        ds_2 -> MyT4;
        ds_3 -> MyT4;
        ds_n -> MyT4;
        dsp -> T4;
125
126
127
128
129
130
131
    }

.. graphviz::
   :align: center
   :caption: After

    digraph G {
132
133
134
135
136
137
138
139
140
141
        dsp [label="Public data source"]
        ds_1 [ color=blue ];
        ds_2
        ds_3 [label="..."]
        ds_n
        ds_1 -> T4 [ label=" Only edited link"; color=red ];
        ds_2 -> MyT4;
        ds_3 -> MyT4;
        ds_n -> MyT4;
        dsp -> T4;
142
    }
143