xref: /freebsd-src/crypto/openssl/include/openssl/ebcdic.h (revision b077aed33b7b6aefca7b17ddb250cf521f938613)
1e71b7053SJung-uk Kim /*
2e71b7053SJung-uk Kim  * Copyright 1999-2016 The OpenSSL Project Authors. All Rights Reserved.
3e71b7053SJung-uk Kim  *
4*b077aed3SPierre Pronchery  * Licensed under the Apache License 2.0 (the "License").  You may not use
5e71b7053SJung-uk Kim  * this file except in compliance with the License.  You can obtain a copy
6e71b7053SJung-uk Kim  * in the file LICENSE in the source distribution or at
7e71b7053SJung-uk Kim  * https://www.openssl.org/source/license.html
8e71b7053SJung-uk Kim  */
9e71b7053SJung-uk Kim 
10*b077aed3SPierre Pronchery #ifndef OPENSSL_EBCDIC_H
11*b077aed3SPierre Pronchery # define OPENSSL_EBCDIC_H
12*b077aed3SPierre Pronchery # pragma once
13*b077aed3SPierre Pronchery 
14*b077aed3SPierre Pronchery # include <openssl/macros.h>
15*b077aed3SPierre Pronchery # ifndef OPENSSL_NO_DEPRECATED_3_0
16e71b7053SJung-uk Kim #  define HEADER_EBCDIC_H
17*b077aed3SPierre Pronchery # endif
18e71b7053SJung-uk Kim 
19e71b7053SJung-uk Kim # include <stdlib.h>
20e71b7053SJung-uk Kim 
21e71b7053SJung-uk Kim #ifdef  __cplusplus
22e71b7053SJung-uk Kim extern "C" {
23e71b7053SJung-uk Kim #endif
24e71b7053SJung-uk Kim 
25e71b7053SJung-uk Kim /* Avoid name clashes with other applications */
26e71b7053SJung-uk Kim # define os_toascii   _openssl_os_toascii
27e71b7053SJung-uk Kim # define os_toebcdic  _openssl_os_toebcdic
28e71b7053SJung-uk Kim # define ebcdic2ascii _openssl_ebcdic2ascii
29e71b7053SJung-uk Kim # define ascii2ebcdic _openssl_ascii2ebcdic
30e71b7053SJung-uk Kim 
31e71b7053SJung-uk Kim extern const unsigned char os_toascii[256];
32e71b7053SJung-uk Kim extern const unsigned char os_toebcdic[256];
33e71b7053SJung-uk Kim void *ebcdic2ascii(void *dest, const void *srce, size_t count);
34e71b7053SJung-uk Kim void *ascii2ebcdic(void *dest, const void *srce, size_t count);
35e71b7053SJung-uk Kim 
36e71b7053SJung-uk Kim #ifdef  __cplusplus
37e71b7053SJung-uk Kim }
38e71b7053SJung-uk Kim #endif
39e71b7053SJung-uk Kim #endif
40