src/jdk.crypto.ucrypto/solaris/native/libj2ucrypto/nativeFunc.h
author jwilhelm
Fri, 02 Mar 2018 21:00:12 +0100
changeset 49331 10b24a3af249
parent 47216 71c04702a3d5
permissions -rw-r--r--
Merge
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
27182
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
     1
/*
37909
38b1efe33344 8000415: Add support for SHA-3
valeriep
parents: 27182
diff changeset
     2
 * Copyright (c) 2014, 2016, Oracle and/or its affiliates. All rights reserved.
27182
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
     3
 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
     4
 *
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
     5
 * This code is free software; you can redistribute it and/or modify it
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
     6
 * under the terms of the GNU General Public License version 2 only, as
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
     7
 * published by the Free Software Foundation.  Oracle designates this
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
     8
 * particular file as subject to the "Classpath" exception as provided
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
     9
 * by Oracle in the LICENSE file that accompanied this code.
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
    10
 *
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
    11
 * This code is distributed in the hope that it will be useful, but WITHOUT
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
    12
 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
    13
 * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
    14
 * version 2 for more details (a copy is included in the LICENSE file that
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
    15
 * accompanied this code).
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
    16
 *
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
    17
 * You should have received a copy of the GNU General Public License version
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
    18
 * 2 along with this work; if not, write to the Free Software Foundation,
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
    19
 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
    20
 *
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
    21
 * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
    22
 * or visit www.oracle.com if you need additional information or have any
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
    23
 * questions.
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
    24
 */
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
    25
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
    26
#ifndef SPARCT4_NATIVE_FUNC_H
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
    27
#define SPARCT4_NATIVE_FUNC_H
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
    28
#include <md5.h>
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
    29
#include <sha1.h>
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
    30
#include <sha2.h>
38878
7213c4599103 8157627: Ucrypto prov need to workaround the renaming of CK_AES_GCM_PARAMS starting S11.3
valeriep
parents: 37909
diff changeset
    31
#include <libsoftcrypto.h> // redirects to libucrypto.h starting 11.3
27182
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
    32
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
    33
jboolean* loadNative();
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
    34
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
    35
/* function pointer definitions */
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
    36
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
    37
typedef void (*MD5INIT_FN_PTR)(MD5_CTX *context);
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
    38
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
    39
typedef void (*MD5UPDATE_FN_PTR)
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
    40
     (MD5_CTX *context, unsigned char *input,
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
    41
      unsigned int inlen);
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
    42
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
    43
typedef void (*MD5FINAL_FN_PTR)
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
    44
     (unsigned char *output, MD5_CTX *context);
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
    45
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
    46
typedef void (*SHA1INIT_FN_PTR)(SHA1_CTX *context);
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
    47
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
    48
typedef void (*SHA1UPDATE_FN_PTR)
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
    49
     (SHA1_CTX *context, unsigned char *input,
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
    50
      unsigned int inlen);
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
    51
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
    52
typedef void (*SHA1FINAL_FN_PTR)
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
    53
     (unsigned char *output, SHA1_CTX *context);
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
    54
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
    55
typedef void (*SHA2INIT_FN_PTR)(uint64_t mech, SHA2_CTX *context);
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
    56
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
    57
typedef void (*SHA2UPDATE_FN_PTR)
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
    58
     (SHA2_CTX *context, unsigned char *input,
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
    59
      unsigned int inlen);
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
    60
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
    61
typedef void (*SHA2FINAL_FN_PTR)
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
    62
     (unsigned char *output, SHA2_CTX *context);
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
    63
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
    64
typedef int (*UCRYPTO_VERSION_FN_PTR)();
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
    65
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
    66
typedef int (*UCRYPTO_GET_MECHLIST_FN_PTR)(char *str);
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
    67
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
    68
typedef int (*UCRYPTO_ENCRYPT_INIT_FN_PTR)
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
    69
     (crypto_ctx_t *context, ucrypto_mech_t mech_type,
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
    70
      uchar_t *key_str, size_t key_len,
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
    71
      void *iv, size_t iv_len);
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
    72
typedef int (*UCRYPTO_ENCRYPT_UPDATE_FN_PTR)
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
    73
     (crypto_ctx_t *context, uchar_t *in,
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
    74
      size_t in_len, uchar_t *out, size_t *out_len);
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
    75
typedef int (*UCRYPTO_ENCRYPT_FINAL_FN_PTR)
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
    76
     (crypto_ctx_t *context, uchar_t *out,
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
    77
      size_t *out_len);
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
    78
typedef int (*UCRYPTO_ENCRYPT_FN_PTR)
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
    79
     (ucrypto_mech_t mech_type, uchar_t *key_str,
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
    80
      size_t key_len, void *iv, size_t iv_len, uchar_t *in,
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
    81
      size_t in_len, uchar_t *out, size_t *out_len);
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
    82
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
    83
typedef int (*UCRYPTO_DECRYPT_INIT_FN_PTR)
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
    84
     (crypto_ctx_t *context,
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
    85
      ucrypto_mech_t mech_type, uchar_t *key_str, size_t key_len,
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
    86
      void *iv, size_t iv_len);
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
    87
typedef int (*UCRYPTO_DECRYPT_UPDATE_FN_PTR)
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
    88
     (crypto_ctx_t *context, uchar_t *in,
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
    89
      size_t in_len, uchar_t *out, size_t *out_len);
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
    90
typedef int (*UCRYPTO_DECRYPT_FINAL_FN_PTR)
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
    91
     (crypto_ctx_t *context, uchar_t *out,
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
    92
      size_t *out_len);
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
    93
typedef int (*UCRYPTO_DECRYPT_FN_PTR)
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
    94
     (ucrypto_mech_t mech_type, uchar_t *key_str,
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
    95
      size_t key_len, void *iv, size_t iv_len, uchar_t *in,
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
    96
      size_t in_len, uchar_t *out, size_t *out_len);
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
    97
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
    98
typedef int (*UCRYPTO_SIGN_INIT_FN_PTR)
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
    99
     (crypto_ctx_t *context, ucrypto_mech_t mech_type,
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
   100
      uchar_t *key_str, size_t key_len,
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
   101
      void *iv, size_t iv_len);
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
   102
typedef int (*UCRYPTO_SIGN_UPDATE_FN_PTR)
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
   103
     (crypto_ctx_t *context, uchar_t *data_str, size_t data_len);
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
   104
typedef int (*UCRYPTO_SIGN_FINAL_FN_PTR)
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
   105
     (crypto_ctx_t *context, uchar_t *sig_str, size_t *sig_len);
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
   106
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
   107
typedef int (*UCRYPTO_VERIFY_INIT_FN_PTR)
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
   108
     (crypto_ctx_t *context, ucrypto_mech_t mech_type,
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
   109
      uchar_t *key_str, size_t key_len,
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
   110
      void *iv, size_t iv_len);
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
   111
typedef int (*UCRYPTO_VERIFY_UPDATE_FN_PTR)
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
   112
     (crypto_ctx_t *context, uchar_t *data_str, size_t data_len);
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
   113
typedef int (*UCRYPTO_VERIFY_FINAL_FN_PTR)
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
   114
     (crypto_ctx_t *context, uchar_t *sig_str, size_t *sig_len);
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
   115
37909
38b1efe33344 8000415: Add support for SHA-3
valeriep
parents: 27182
diff changeset
   116
typedef int (*UCRYPTO_DIGEST_INIT_FN_PTR)
38b1efe33344 8000415: Add support for SHA-3
valeriep
parents: 27182
diff changeset
   117
     (crypto_ctx_t *context, ucrypto_mech_t mech_type,
38b1efe33344 8000415: Add support for SHA-3
valeriep
parents: 27182
diff changeset
   118
      void *param, size_t param_len);
38b1efe33344 8000415: Add support for SHA-3
valeriep
parents: 27182
diff changeset
   119
typedef int (*UCRYPTO_DIGEST_UPDATE_FN_PTR)
38b1efe33344 8000415: Add support for SHA-3
valeriep
parents: 27182
diff changeset
   120
     (crypto_ctx_t *context, const uchar_t *data, size_t data_len);
38b1efe33344 8000415: Add support for SHA-3
valeriep
parents: 27182
diff changeset
   121
typedef int (*UCRYPTO_DIGEST_FINAL_FN_PTR)
38b1efe33344 8000415: Add support for SHA-3
valeriep
parents: 27182
diff changeset
   122
     (crypto_ctx_t *context, uchar_t *digest, size_t *digest_len);
38b1efe33344 8000415: Add support for SHA-3
valeriep
parents: 27182
diff changeset
   123
38b1efe33344 8000415: Add support for SHA-3
valeriep
parents: 27182
diff changeset
   124
typedef void (*UCRYPTO_FREE_CONTEXT_FN_PTR)
38b1efe33344 8000415: Add support for SHA-3
valeriep
parents: 27182
diff changeset
   125
     (crypto_ctx_t *context);
38b1efe33344 8000415: Add support for SHA-3
valeriep
parents: 27182
diff changeset
   126
38b1efe33344 8000415: Add support for SHA-3
valeriep
parents: 27182
diff changeset
   127
typedef char* (*UCRYPTO_STRERROR_FN_PTR)(int rv);
38b1efe33344 8000415: Add support for SHA-3
valeriep
parents: 27182
diff changeset
   128
27182
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
   129
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
   130
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
   131
/* dynamically resolved functions from libmd, and libsoftcrypto
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
   132
   libraries */
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
   133
typedef struct T4CRYPTO_FUNCTION_TABLE {
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
   134
  MD5INIT_FN_PTR                 md5Init;
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
   135
  MD5UPDATE_FN_PTR               md5Update;
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
   136
  MD5FINAL_FN_PTR                md5Final;
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
   137
  SHA1INIT_FN_PTR                sha1Init;
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
   138
  SHA1UPDATE_FN_PTR              sha1Update;
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
   139
  SHA1FINAL_FN_PTR               sha1Final;
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
   140
  SHA2INIT_FN_PTR                sha2Init;
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
   141
  SHA2UPDATE_FN_PTR              sha2Update;
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
   142
  SHA2FINAL_FN_PTR               sha2Final;
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
   143
  UCRYPTO_VERSION_FN_PTR         ucryptoVersion;
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
   144
  UCRYPTO_GET_MECHLIST_FN_PTR    ucryptoGetMechList;
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
   145
  UCRYPTO_ENCRYPT_INIT_FN_PTR    ucryptoEncryptInit;
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
   146
  UCRYPTO_ENCRYPT_UPDATE_FN_PTR  ucryptoEncryptUpdate;
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
   147
  UCRYPTO_ENCRYPT_FINAL_FN_PTR   ucryptoEncryptFinal;
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
   148
  UCRYPTO_ENCRYPT_FN_PTR         ucryptoEncrypt;
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
   149
  UCRYPTO_DECRYPT_INIT_FN_PTR    ucryptoDecryptInit;
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
   150
  UCRYPTO_DECRYPT_UPDATE_FN_PTR  ucryptoDecryptUpdate;
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
   151
  UCRYPTO_DECRYPT_FINAL_FN_PTR   ucryptoDecryptFinal;
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
   152
  UCRYPTO_DECRYPT_FN_PTR         ucryptoDecrypt;
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
   153
  UCRYPTO_SIGN_INIT_FN_PTR       ucryptoSignInit;
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
   154
  UCRYPTO_SIGN_UPDATE_FN_PTR     ucryptoSignUpdate;
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
   155
  UCRYPTO_SIGN_FINAL_FN_PTR      ucryptoSignFinal;
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
   156
  UCRYPTO_VERIFY_INIT_FN_PTR     ucryptoVerifyInit;
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
   157
  UCRYPTO_VERIFY_UPDATE_FN_PTR   ucryptoVerifyUpdate;
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
   158
  UCRYPTO_VERIFY_FINAL_FN_PTR    ucryptoVerifyFinal;
37909
38b1efe33344 8000415: Add support for SHA-3
valeriep
parents: 27182
diff changeset
   159
  UCRYPTO_DIGEST_INIT_FN_PTR     ucryptoDigestInit;
38b1efe33344 8000415: Add support for SHA-3
valeriep
parents: 27182
diff changeset
   160
  UCRYPTO_DIGEST_UPDATE_FN_PTR   ucryptoDigestUpdate;
38b1efe33344 8000415: Add support for SHA-3
valeriep
parents: 27182
diff changeset
   161
  UCRYPTO_DIGEST_FINAL_FN_PTR    ucryptoDigestFinal;
38b1efe33344 8000415: Add support for SHA-3
valeriep
parents: 27182
diff changeset
   162
  UCRYPTO_FREE_CONTEXT_FN_PTR    ucryptoFreeContext;
38b1efe33344 8000415: Add support for SHA-3
valeriep
parents: 27182
diff changeset
   163
  UCRYPTO_STRERROR_FN_PTR        ucryptoStrerror;
27182
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
   164
} T4CRYPTO_FUNCTION_TABLE;
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
   165
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
   166
typedef T4CRYPTO_FUNCTION_TABLE *T4CRYPTO_FUNCTION_TABLE_PTR;
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
   167
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
   168
/* global function table */
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
   169
T4CRYPTO_FUNCTION_TABLE_PTR ftab;
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
   170
4525d13b8af1 8046002: Move Ucrypto to the open jdk repo
valeriep
parents:
diff changeset
   171
#endif