Home | History | Annotate | Line # | Download | only in pk11
      1 /*	$NetBSD: result.h,v 1.1 2024/02/18 20:57:55 christos Exp $	*/
      2 
      3 /*
      4  * Copyright (C) Internet Systems Consortium, Inc. ("ISC")
      5  *
      6  * SPDX-License-Identifier: MPL-2.0
      7  *
      8  * This Source Code Form is subject to the terms of the Mozilla Public
      9  * License, v. 2.0.  If a copy of the MPL was not distributed with this
     10  * file, you can obtain one at https://mozilla.org/MPL/2.0/.
     11  *
     12  * See the COPYRIGHT file distributed with this work for additional
     13  * information regarding copyright ownership.
     14  */
     15 
     16 #ifndef PK11_RESULT_H
     17 #define PK11_RESULT_H 1
     18 
     19 /*! \file pk11/result.h */
     20 
     21 #include <isc/lang.h>
     22 #include <isc/resultclass.h>
     23 #include <isc/types.h>
     24 
     25 /*
     26  * Nothing in this file truly depends on <isc/result.h>, but the
     27  * PK11 result codes are considered to be publicly derived from
     28  * the ISC result codes, so including this file buys you the ISC_R_
     29  * namespace too.
     30  */
     31 #include <isc/result.h> /* Contractual promise. */
     32 
     33 #define PK11_R_INITFAILED      (ISC_RESULTCLASS_PK11 + 0)
     34 #define PK11_R_NOPROVIDER      (ISC_RESULTCLASS_PK11 + 1)
     35 #define PK11_R_NORANDOMSERVICE (ISC_RESULTCLASS_PK11 + 2)
     36 #define PK11_R_NODIGESTSERVICE (ISC_RESULTCLASS_PK11 + 3)
     37 #define PK11_R_NOAESSERVICE    (ISC_RESULTCLASS_PK11 + 4)
     38 
     39 #define PK11_R_NRESULTS 5 /* Number of results */
     40 
     41 ISC_LANG_BEGINDECLS
     42 
     43 const char *pk11_result_totext(isc_result_t);
     44 
     45 void
     46 pk11_result_register(void);
     47 
     48 ISC_LANG_ENDDECLS
     49 
     50 #endif /* PK11_RESULT_H */
     51