pm_ticket.h

Go to the documentation of this file.
00001 /******************************* */
00002 /* Rule Set Based Access Control */
00003 /* Author and (c) 1999-2005:     */
00004 /*   Amon Ott <ao@rsbac.org>     */
00005 /* API: Data types for privacy   */
00006 /*      model calls / tickets    */
00007 /* Last modified: 09/Feb/2005    */
00008 /******************************* */
00009 
00010 #ifndef __RSBAC_PM_TICKET_H
00011 #define __RSBAC_PM_TICKET_H
00012 
00013 #include <linux/types.h>
00014 
00015 enum    rsbac_pm_tkt_function_type_t {/* issued by data_prot_officer */
00016                                       PTF_add_na, PTF_delete_na, PTF_add_task,
00017                                       PTF_delete_task, PTF_add_object_class,
00018                                       PTF_delete_object_class,
00019                                       PTF_add_authorized_tp,
00020                                       PTF_delete_authorized_tp,
00021                                       PTF_add_consent, PTF_delete_consent,
00022                                       PTF_add_purpose, PTF_delete_purpose,
00023                                       PTF_add_responsible_user,
00024                                       PTF_delete_responsible_user,
00025                                       PTF_delete_user_aci,
00026                                       PTF_set_role,
00027                                       PTF_set_object_class,
00028                                       PTF_switch_pm,
00029                                       PTF_switch_auth,
00030                                       PTF_set_device_object_type,
00031                                       PTF_set_auth_may_setuid,
00032                                       PTF_set_auth_may_set_cap,
00033                                       /* issued by user also */
00034                                       PTF_add_authorized_task,
00035                                       PTF_delete_authorized_task,
00036                                       /* never issued, internal */
00037                                       PTF_none};
00038 
00039 struct rsbac_pm_add_na_t
00040   {
00041     rsbac_pm_task_id_t            task;
00042     rsbac_pm_object_class_id_t    object_class;
00043     rsbac_pm_tp_id_t              tp;
00044     rsbac_pm_accesses_t           accesses;
00045   };
00046 
00047 struct rsbac_pm_delete_na_t
00048   {
00049     rsbac_pm_task_id_t            task;
00050     rsbac_pm_object_class_id_t    object_class;
00051     rsbac_pm_tp_id_t              tp;
00052     rsbac_pm_accesses_t           accesses;
00053   };
00054 
00055 struct rsbac_pm_add_task_t
00056   {
00057     rsbac_pm_task_id_t            id;
00058     rsbac_pm_purpose_id_t         purpose;
00059   };
00060 
00061 struct rsbac_pm_delete_task_t
00062   {
00063     rsbac_pm_task_id_t            id;
00064   };
00065 
00066 #ifdef __KERNEL__
00067 struct rsbac_pm_tkt_add_object_class_t
00068   {
00069     rsbac_pm_object_class_id_t            id;
00070     rsbac_pm_pp_set_id_t                  pp_set;
00071   };
00072 #endif
00073 
00074 struct rsbac_pm_add_object_class_t
00075   {
00076     rsbac_pm_object_class_id_t            id;
00077     struct rsbac_pm_purpose_list_item_t * pp_list_p;
00078   };
00079 
00080 struct rsbac_pm_delete_object_class_t
00081   {
00082     rsbac_pm_object_class_id_t    id;
00083   };
00084 
00085 struct rsbac_pm_add_authorized_tp_t
00086   {
00087     rsbac_pm_task_id_t            task;
00088     rsbac_pm_tp_id_t              tp;
00089   };
00090 
00091 struct rsbac_pm_delete_authorized_tp_t
00092   {
00093     rsbac_pm_task_id_t            task;
00094     rsbac_pm_tp_id_t              tp;
00095   };
00096 
00097 #ifdef __KERNEL__
00098 struct rsbac_pm_tkt_add_consent_t
00099   {
00100     struct rsbac_fs_file_t        file;
00101     rsbac_pm_purpose_id_t         purpose;
00102   };
00103 #endif
00104 
00105 struct rsbac_pm_add_consent_t
00106   {
00107     char                        * filename;
00108            rsbac_pm_purpose_id_t  purpose;
00109   };
00110 
00111 #ifdef __KERNEL__
00112 struct rsbac_pm_tkt_delete_consent_t
00113   {
00114     struct rsbac_fs_file_t        file;
00115     rsbac_pm_purpose_id_t         purpose;
00116   };
00117 #endif
00118 
00119 struct rsbac_pm_delete_consent_t
00120   {
00121     char                        * filename;
00122     rsbac_pm_purpose_id_t         purpose;
00123   };
00124 
00125 struct rsbac_pm_add_purpose_t
00126   {
00127     rsbac_pm_purpose_id_t         id;
00128     rsbac_pm_object_class_id_t    def_class;
00129   };
00130 
00131 struct rsbac_pm_delete_purpose_t
00132   {
00133     rsbac_pm_purpose_id_t         id;
00134   };
00135 
00136 struct rsbac_pm_add_responsible_user_t
00137   {
00138     rsbac_uid_t                   user;
00139     rsbac_pm_task_id_t            task;
00140   };
00141 
00142 struct rsbac_pm_delete_responsible_user_t
00143   {
00144     rsbac_uid_t                   user;
00145     rsbac_pm_task_id_t            task;
00146   };
00147 
00148 struct rsbac_pm_delete_user_aci_t
00149   {
00150     rsbac_uid_t                   id;
00151   };
00152 
00153 struct rsbac_pm_set_role_t
00154   {
00155     rsbac_uid_t                   user;
00156     enum rsbac_pm_role_t          role;
00157   };
00158 
00159 #ifdef __KERNEL__
00160 struct rsbac_pm_tkt_set_object_class_t
00161   {
00162     struct rsbac_fs_file_t        file;
00163     rsbac_pm_object_class_id_t    object_class;
00164   };
00165 #endif
00166 
00167 struct rsbac_pm_set_object_class_t
00168   {
00169     char                        * filename;
00170     rsbac_pm_object_class_id_t    object_class;
00171   };
00172 
00173 struct rsbac_pm_switch_pm_t
00174   {
00175     rsbac_boolean_t               value;
00176   };
00177 
00178 struct rsbac_pm_switch_auth_t
00179   {
00180     rsbac_boolean_t               value;
00181   };
00182 
00183 #ifdef __KERNEL__
00184 struct rsbac_pm_tkt_set_device_object_type_t
00185   {
00186     struct rsbac_dev_t            dev;
00187     enum rsbac_pm_object_type_t   object_type;
00188     rsbac_pm_object_class_id_t    object_class;
00189   };
00190 #endif
00191 
00192 struct rsbac_pm_set_device_object_type_t
00193   {
00194     char                        * filename;
00195     enum rsbac_pm_object_type_t   object_type;
00196     rsbac_pm_object_class_id_t    object_class;
00197   };
00198 
00199 #ifdef __KERNEL__
00200 struct rsbac_pm_tkt_set_auth_may_setuid_t
00201   {
00202     struct rsbac_fs_file_t        file;
00203     rsbac_boolean_t               value;
00204   };
00205 #endif
00206 
00207 struct rsbac_pm_set_auth_may_setuid_t
00208   {
00209     char                        * filename;
00210     rsbac_boolean_t               value;
00211   };
00212 
00213 #ifdef __KERNEL__
00214 struct rsbac_pm_tkt_set_auth_may_set_cap_t
00215   {
00216     struct rsbac_fs_file_t        file;
00217     rsbac_boolean_t               value;
00218   };
00219 #endif
00220 
00221 struct rsbac_pm_set_auth_may_set_cap_t
00222   {
00223     char                        * filename;
00224     rsbac_boolean_t               value;
00225   };
00226 
00227 /***************/
00228 
00229 struct rsbac_pm_add_authorized_task_t
00230   {
00231     rsbac_uid_t                   user;
00232     rsbac_pm_task_id_t            task;
00233   };
00234 
00235 struct rsbac_pm_delete_authorized_task_t
00236   {
00237     rsbac_uid_t                   user;
00238     rsbac_pm_task_id_t            task;
00239   };
00240 
00241 /***************/
00242 
00243 struct rsbac_pm_create_tp_t
00244   {
00245     rsbac_pm_tp_id_t              id;
00246   };
00247 
00248 struct rsbac_pm_delete_tp_t
00249   {
00250     rsbac_pm_tp_id_t              id;
00251   };
00252 
00253 struct rsbac_pm_set_tp_t
00254   {
00255     char                        * filename;
00256     rsbac_pm_tp_id_t              tp;
00257   };
00258 
00259 /***************/
00260 
00261 #ifdef __KERNEL__
00262 union   rsbac_pm_tkt_internal_function_param_t
00263          {
00264            struct rsbac_pm_add_na_t                   add_na;
00265            struct rsbac_pm_delete_na_t                delete_na;
00266            struct rsbac_pm_add_task_t                 add_task;
00267            struct rsbac_pm_delete_task_t              delete_task;
00268            struct rsbac_pm_tkt_add_object_class_t     tkt_add_object_class;
00269            struct rsbac_pm_delete_object_class_t      delete_object_class;
00270            struct rsbac_pm_add_authorized_tp_t        add_authorized_tp;
00271            struct rsbac_pm_delete_authorized_tp_t     delete_authorized_tp;
00272            struct rsbac_pm_tkt_add_consent_t          tkt_add_consent;
00273            struct rsbac_pm_tkt_delete_consent_t       tkt_delete_consent;
00274            struct rsbac_pm_add_purpose_t              add_purpose;
00275            struct rsbac_pm_delete_purpose_t           delete_purpose;
00276            struct rsbac_pm_add_responsible_user_t     add_responsible_user;
00277            struct rsbac_pm_delete_responsible_user_t  delete_responsible_user;
00278            struct rsbac_pm_delete_user_aci_t          delete_user_aci;
00279            struct rsbac_pm_set_role_t                 set_role;
00280            struct rsbac_pm_tkt_set_object_class_t     tkt_set_object_class;
00281            struct rsbac_pm_switch_pm_t                switch_pm;
00282            struct rsbac_pm_switch_pm_t                switch_auth;
00283            struct rsbac_pm_tkt_set_device_object_type_t tkt_set_device_object_type;
00284            struct rsbac_pm_tkt_set_auth_may_setuid_t  tkt_set_auth_may_setuid;
00285            struct rsbac_pm_tkt_set_auth_may_set_cap_t tkt_set_auth_may_set_cap;
00286            struct rsbac_pm_add_authorized_task_t      add_authorized_task;
00287            struct rsbac_pm_delete_authorized_task_t   delete_authorized_task;
00288            int                                        dummy;
00289          };
00290 #endif
00291 
00292 union   rsbac_pm_tkt_function_param_t
00293          {
00294            struct rsbac_pm_add_na_t                   add_na;
00295            struct rsbac_pm_delete_na_t                delete_na;
00296            struct rsbac_pm_add_task_t                 add_task;
00297            struct rsbac_pm_delete_task_t              delete_task;
00298            struct rsbac_pm_add_object_class_t         add_object_class;
00299            struct rsbac_pm_delete_object_class_t      delete_object_class;
00300            struct rsbac_pm_add_authorized_tp_t        add_authorized_tp;
00301            struct rsbac_pm_delete_authorized_tp_t     delete_authorized_tp;
00302            struct rsbac_pm_add_consent_t              add_consent;
00303            struct rsbac_pm_delete_consent_t           delete_consent;
00304            struct rsbac_pm_add_purpose_t              add_purpose;
00305            struct rsbac_pm_delete_purpose_t           delete_purpose;
00306            struct rsbac_pm_add_responsible_user_t     add_responsible_user;
00307            struct rsbac_pm_delete_responsible_user_t  delete_responsible_user;
00308            struct rsbac_pm_delete_user_aci_t          delete_user_aci;
00309            struct rsbac_pm_set_role_t                 set_role;
00310            struct rsbac_pm_set_object_class_t         set_object_class;
00311            struct rsbac_pm_switch_pm_t                switch_pm;
00312            struct rsbac_pm_switch_pm_t                switch_auth;
00313            struct rsbac_pm_set_device_object_type_t   set_device_object_type;
00314            struct rsbac_pm_set_auth_may_setuid_t      set_auth_may_setuid;
00315            struct rsbac_pm_set_auth_may_set_cap_t     set_auth_may_set_cap;
00316            struct rsbac_pm_add_authorized_task_t      add_authorized_task;
00317            struct rsbac_pm_delete_authorized_task_t   delete_authorized_task;
00318            int                                        dummy;
00319          };
00320 
00321 /***********************/
00322 
00323 enum    rsbac_pm_function_type_t     {/* tkt issued by data_prot_officer, */
00324                                       /* called by security_officer */
00325                                       PF_add_na, PF_delete_na, PF_add_task,
00326                                       PF_delete_task, PF_add_object_class,
00327                                       PF_delete_object_class,
00328                                       PF_add_authorized_tp,
00329                                       PF_delete_authorized_tp,
00330                                       PF_add_consent, PF_delete_consent,
00331                                       PF_add_purpose, PF_delete_purpose,
00332                                       PF_add_responsible_user,
00333                                       PF_delete_responsible_user,
00334                                       PF_delete_user_aci,
00335                                       PF_set_role,
00336                                       PF_set_object_class,
00337                                       PF_switch_pm,
00338                                       PF_switch_auth,
00339                                       PF_set_device_object_type,
00340                                       PF_set_auth_may_setuid,
00341                                       PF_set_auth_may_set_cap,
00342                                       /* tkt issued by data_prot_officer and */
00343                                       /* resp. user, called by security_officer */
00344                                       PF_add_authorized_task,
00345                                       PF_delete_authorized_task,
00346                                       /* called by tp_manager, no ticket */
00347                                       PF_create_tp, PF_delete_tp, PF_set_tp,
00348                                       /* called by data_prot_officer and */
00349                                       /* responsible user */
00350                                       PF_create_ticket,
00351                                       /* never to be called, internal */
00352                                       PF_none};
00353 
00354 struct rsbac_pm_create_ticket_t
00355   {
00356            rsbac_pm_tkt_id_t              id;
00357            rsbac_pm_time_stamp_t          valid_for;  /* validity in secs */
00358     enum   rsbac_pm_tkt_function_type_t   function_type;
00359     union  rsbac_pm_tkt_function_param_t  function_param;
00360   };
00361 
00362 union   rsbac_pm_function_param_t
00363          {
00364            struct rsbac_pm_add_na_t                   add_na;
00365            struct rsbac_pm_delete_na_t                delete_na;
00366            struct rsbac_pm_add_task_t                 add_task;
00367            struct rsbac_pm_delete_task_t              delete_task;
00368            struct rsbac_pm_add_object_class_t         add_object_class;
00369            struct rsbac_pm_delete_object_class_t      delete_object_class;
00370            struct rsbac_pm_add_authorized_tp_t        add_authorized_tp;
00371            struct rsbac_pm_delete_authorized_tp_t     delete_authorized_tp;
00372            struct rsbac_pm_add_consent_t              add_consent;
00373            struct rsbac_pm_delete_consent_t           delete_consent;
00374            struct rsbac_pm_add_purpose_t              add_purpose;
00375            struct rsbac_pm_delete_purpose_t           delete_purpose;
00376            struct rsbac_pm_add_responsible_user_t     add_responsible_user;
00377            struct rsbac_pm_delete_responsible_user_t  delete_responsible_user;
00378            struct rsbac_pm_delete_user_aci_t          delete_user_aci;
00379            struct rsbac_pm_set_role_t                 set_role;
00380            struct rsbac_pm_set_object_class_t         set_object_class;
00381            struct rsbac_pm_switch_pm_t                switch_pm;
00382            struct rsbac_pm_switch_pm_t                switch_auth;
00383            struct rsbac_pm_set_device_object_type_t   set_device_object_type;
00384            struct rsbac_pm_set_auth_may_setuid_t      set_auth_may_setuid;
00385            struct rsbac_pm_set_auth_may_set_cap_t     set_auth_may_set_cap;
00386            struct rsbac_pm_add_authorized_task_t      add_authorized_task;
00387            struct rsbac_pm_delete_authorized_task_t   delete_authorized_task;
00388            struct rsbac_pm_create_tp_t                create_tp;
00389            struct rsbac_pm_delete_tp_t                delete_tp;
00390            struct rsbac_pm_set_tp_t                   set_tp;
00391            struct rsbac_pm_create_ticket_t            create_ticket;
00392            int                                        dummy;
00393          };
00394 
00395 
00396 /*******************/
00397 
00398 #ifdef __KERNEL__
00399 struct rsbac_pm_old_tkt_data_t
00400     {
00401              rsbac_pm_tkt_id_t                       id;
00402              rsbac_old_uid_t                         issuer;
00403       enum   rsbac_pm_tkt_function_type_t            function_type;
00404       union  rsbac_pm_tkt_internal_function_param_t  function_param;
00405              rsbac_pm_time_stamp_t                   valid_until;
00406     };
00407 
00408 struct rsbac_pm_tkt_data_t
00409     {
00410              rsbac_pm_tkt_id_t                       id;
00411              rsbac_uid_t                             issuer;
00412       enum   rsbac_pm_tkt_function_type_t            function_type;
00413       union  rsbac_pm_tkt_internal_function_param_t  function_param;
00414              rsbac_pm_time_stamp_t                   valid_until;
00415     };
00416 #endif
00417 
00418 #endif

Generated on Fri Jun 17 09:45:18 2005 for RSBAC by  doxygen 1.4.2