OpenVAS Scanner 23.23.1
charset.h
Go to the documentation of this file.
1/* SPDX-FileCopyrightText: 2023 Greenbone AG
2 * SPDX-FileCopyrightText: 2002 Jelmer Vernooij
3 * SPDX-FileCopyrightText: 2001 Andrew Tridgell
4 *
5 * SPDX-License-Identifier: GPL-2.0-or-later
6 */
7
12
13/* MODIFICATION: This has only those functions that cater to the requirements of
14 * OpenVAS, remaining functions are removed*/
15#ifndef NASL_CHARSET_H
16#define NASL_CHARSET_H
17
18#include "smb.h"
19
20#include <string.h>
21
22/* this defines the charset types used in samba */
23typedef enum
24{
29 CH_DOS = 3,
32} charset_t;
33
34#define NUM_CHARSETS 6
35/*
36 * for each charset we have a function that pushes from that charset to a ucs2
37 * buffer, and a function that pulls from ucs2 buffer to that charset.
38 */
39
41{
42 const char *name;
43 size_t (*pull) (void *, const char **inbuf, size_t *inbytesleft,
44 char **outbuf, size_t *outbytesleft);
45 size_t (*push) (void *, const char **inbuf, size_t *inbytesleft,
46 char **outbuf, size_t *outbytesleft);
48};
49#endif
charset_t
Definition charset.h:24
@ CH_UTF16
Definition charset.h:26
@ CH_DISPLAY
Definition charset.h:28
@ CH_UTF16BE
Definition charset.h:31
@ CH_UNIX
Definition charset.h:27
@ CH_DOS
Definition charset.h:29
@ CH_UTF16LE
Definition charset.h:25
@ CH_UTF8
Definition charset.h:30
Unix SMB/CIFS implementation.
Definition charset.h:41
struct charset_functions_ntlmssp * prev
Definition charset.h:47
struct charset_functions_ntlmssp * next
Definition charset.h:47
size_t(* pull)(void *, const char **inbuf, size_t *inbytesleft, char **outbuf, size_t *outbytesleft)
Definition charset.h:43
const char * name
Definition charset.h:42
size_t(* push)(void *, const char **inbuf, size_t *inbytesleft, char **outbuf, size_t *outbytesleft)
Definition charset.h:45