/[hurd]/hurd-l4/libhurd-cap-server/cap-server.h
ViewVC logotype

Diff of /hurd-l4/libhurd-cap-server/cap-server.h

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.14 by neal, Tue Nov 30 17:47:08 2004 UTC revision 1.15 by neal, Tue Mar 8 17:39:09 2005 UTC
# Line 91  struct hurd_cap_rpc_context Line 91  struct hurd_cap_rpc_context
91    /* The capability object on which the RPC was invoked.  */    /* The capability object on which the RPC was invoked.  */
92    hurd_cap_obj_t obj;    hurd_cap_obj_t obj;
93    
94      /* The capability handle on which the RPC was invoked.  */
95      hurd_cap_handle_t handle;
96    
97    /* Private members.  */    /* Private members.  */
98    
# Line 528  void hurd_cap_bucket_resume (hurd_cap_bu Line 530  void hurd_cap_bucket_resume (hurd_cap_bu
530     must be inhibited.  */     must be inhibited.  */
531  error_t hurd_cap_bucket_end (hurd_cap_bucket_t bucket, bool force);  error_t hurd_cap_bucket_end (hurd_cap_bucket_t bucket, bool force);
532    
533    
534    /* If you want to use other capabilities in an RPC handler beside the
535       one on which the RPC was invoked, you need to make sure that
536       inhibition works on those other capabilities and cancel your
537       operation.  For this, the following interfaces are provided.  */
538    
539    /* Forward.  */
540    struct hurd_cap_ctx_cap_use;
541    
542    /* Return the number of bytes required for a hurd_cap_ctx_cap_use
543       structure.  */
544    size_t hurd_cap_ctx_size (void) __attribute__ ((const));
545    
546    /* The calling thread wishes to execute an RPC on the the handle
547       HANDLE.  The calling thread must already be registered as executing
548       an RPC.  RPC_CTX is the cooresponding RPC context.  The function
549       uses the structure CAP_USE, which must point to the number of bytes
550       returned by hurd_cap_ctx_size, to store data required by
551       hurd_cap_ctx_end_cap_use.  The capability object corresponding to
552       HANDLE is locked and returned in *OBJP.
553    
554       Returns EINVAL if the capability handle is invalid for the client.
555    
556       Returns ENOENT if there is no object associated with handle HANDLE.
557    
558       Returns EBAD if the capability is dead.
559    
560       Returns EDOM if the object associated with HANDLE is not in class
561       REQUIRED_CLASS.  If no type check is required, it will be skipped
562       if REQURIED_CLASS is NULL.  */
563    error_t hurd_cap_ctx_start_cap_use (hurd_cap_rpc_context_t rpc_ctx,
564                                        hurd_cap_handle_t handle,
565                                        hurd_cap_class_t required_class,
566                                        struct hurd_cap_ctx_cap_use *cap_use,
567                                        hurd_cap_obj_t *objp);
568    
569    /* End the use of the object CAP_USE->OBJ, which must be locked.  */
570    void hurd_cap_ctx_end_cap_use (hurd_cap_rpc_context_t rpc_ctx,
571                                   struct hurd_cap_ctx_cap_use *cap_use);
572    
573  #endif  /* _HURD_CAP_SERVER_H */  #endif  /* _HURD_CAP_SERVER_H */

Legend:
Removed from v.1.14  
changed lines
  Added in v.1.15

savannah-hackers-public@gnu.org
ViewVC Help
Powered by ViewVC 1.1.26