Compare commits

...

8 Commits

Author SHA1 Message Date
Luis Ibanez c5fb90f411 ENH: Removed .d files, since they are regenerated.
The .d files are generated at build time, and do not need a working
mumps compiler in order to be generated. We can therefore remove
them from this branch.
2012-02-07 10:33:45 -05:00
Luis Ibanez 80a7a83745 ENH: Added error files that were generated.
These files are generated during the build process, and are also deleted
before the build finishes. Here we keep them around.
2012-02-07 09:02:35 -05:00
Luis Ibanez ac082c302a ENH: Introducing fake mumps binary surrogate.
Introduced a shell script to be used as if it was the mumps binary,
and try the build script into going along.
2012-02-07 06:49:44 -05:00
Luis Ibanez 6018262ce6 ENH: Added .d files that seem to be Makefile helpers.
Each one of the .d file has a Makefile-like rule for
building a .o from a .c and a set of .h header files.
2012-02-05 17:28:37 -05:00
Luis Ibanez 1deff11805 ENH: Added .gitignore file
In this way it is easier to ignore the .o, .a, .so files and
other binary files resulting from the build.
2012-02-05 17:24:29 -05:00
Luis Ibanez 41c5df66e1 ENH: Added generated .c and .h files.
These files were generated at configuration time in the ./pro directory.
2012-02-05 17:20:28 -05:00
Luis Ibanez ce975451e5 ENH: Added file that was generated during configuration.
The file name is: sr_linux/gtm_threadgbl_deftypes.h
2012-02-05 17:13:48 -05:00
Luis Ibanez 3d4e0f0813 ENH: Configured a tcsh script according to README.
The README file has instructions on how to setup environment
variables, and then invoke a configuration script. Here we
tuned such variables for the case of a Debian 64 bits build.
2012-02-05 17:07:38 -05:00
37 changed files with 8383 additions and 0 deletions

6
.gitignore vendored Normal file
View File

@ -0,0 +1,6 @@
# Compiled source #
###################
*.o
*.a
*.so

2
fake-binary-surrogates/mumps Executable file
View File

@ -0,0 +1,2 @@
#!/bin/bash
echo "FAKE MUMPS",$*

64
pro/gtm_limits.h Normal file
View File

@ -0,0 +1,64 @@
/****************************************************************
* *
* Copyright 2002, 2011 Fidelity Information Services, Inc *
* *
* This source code contains the intellectual property *
* of its copyright holder(s), and is made available *
* under a license. If you do not know the terms of *
* the license, please stop and do not read further. *
* *
****************************************************************/
/* Interlude to <limits.h> */
#ifndef GTM_LIMITSH
#define GTM_LIMITSH
#include <limits.h>
#ifdef __hpux
#include <inttypes.h>
#endif
/* The value 1023 for PATH_MAX is derived using pathconf("path", _PC_PATH_MAX) on z/OS.
* Since we cant afford calling a function on each use of PATH_MAX/GTM_PATH_MAX,
* this value is hardcoded here.
*/
#if defined (__MVS__)
#ifndef PATH_MAX
#define PATH_MAX 1023
#endif
#define GTM_PATH_MAX PATH_MAX + 1
#else
#define GTM_PATH_MAX 1024 /* includes terminating NULL */
#endif
#if defined(LLONG_MAX) /* C99 and others */
#define GTM_INT64_MIN LLONG_MIN
#define GTM_INT64_MAX LLONG_MAX
#define GTM_UINT64_MAX ULLONG_MAX
#elif defined(LONG_LONG_MAX)
#define GTM_INT64_MIN LONG_LONG_MIN
#define GTM_INT64_MAX LONG_LONG_MAX
#define GTM_UINT64_MAX ULONG_LONG_MAX
#elif defined(LONGLONG_MAX)
#define GTM_INT64_MIN LONGLONG_MIN
#define GTM_INT64_MAX LONGLONG_MAX
#define GTM_UINT64_MAX ULONGLONG_MAX
#elif defined(__INT64_MAX) /* OpenVMS Alpha */
#define GTM_INT64_MIN __INT64_MIN
#define GTM_INT64_MAX __INT64_MAX
#define GTM_UINT64_MAX __UINT64_MAX
#elif defined(INTMAX_MAX) /* HP-UX */
#define GTM_INT64_MIN INTMAX_MIN
#define GTM_INT64_MAX INTMAX_MAX
#define GTM_UINT64_MAX UINTMAX_MAX
#elif LONG_MAX != INT_MAX /* Tru64 */
#define GTM_INT64_MIN LONG_MIN
#define GTM_INT64_MAX LONG_MAX
#define GTM_UINT64_MAX ULONG_MAX
#else
#error Unable to determine 64 bit MAX in gtm_limits.h
#endif
#endif

137
pro/gtm_stdio.h Normal file
View File

@ -0,0 +1,137 @@
/****************************************************************
* *
* Copyright 2010 Fidelity Information Services, Inc *
* *
* This source code contains the intellectual property *
* of its copyright holder(s), and is made available *
* under a license. If you do not know the terms of *
* the license, please stop and do not read further. *
* *
****************************************************************/
/* gtm_stdio.h - gtm interface to stdio.h */
#ifndef GTM_STDIOH
#define GTM_STDIOH
/* This header is split between sr_unix and sr_vvms because there are several test system and standalone modules
* that do not #define UNIX or VMS for us to know which defines to proceed with. So now this split makes
* that determination unnecessary. Note we still use the definition of UNIX or not in THIS header to indicate the
* compilation of a GTM source file or a standalone file not needing (or able to get to) libgtmshr wrappers.
*/
#include <stdio.h>
#define FDOPEN fdopen
#define FGETS(strg, n, strm, fgets_res) (fgets_res = fgets(strg,n,strm))
#define Fopen fopen
#define GETS(buffer, gets_res) syntax error
#define PERROR perror
#define POPEN popen
#define TEMPNAM tempnam
#ifndef P_tmpdir
#define P_tmpdir "/tmp"
#endif
#define DEFAULT_GTM_TMP P_tmpdir
#define RENAME rename
#define SETVBUF setvbuf
#ifdef UNIX
/* We are compiling a GTM source module if UNIX is defined */
# define FPRINTF gtm_fprintf
# define PRINTF gtm_printf
# define SPRINTF gtm_sprintf
# define SNPRINTF gtm_snprintf
int gtm_printf(const char *format, ...);
int gtm_fprintf(FILE *stream, const char *format, ...);
int gtm_sprintf(char *str, const char *format, ...);
int gtm_snprintf(char *str, size_t size, const char *format, ...);
#else
/* We are compiling a standalone or test system module so no override (This is NOT VMS) */
# define FPRINTF fprintf
# define PRINTF printf
# define SPRINTF sprintf
# define SNPRINTF snprintf
#endif
/* Similar to above for *scanf invocations. Note however that TRU64 does NOT have
* the v*scanf functions used by the wrappers so always use the non-wrapper versions.
*/
#if defined(UNIX) && !defined(__osf__)
# define SCANF gtm_scanf
# define SSCANF gtm_sscanf
# define FSCANF gtm_fscanf
int gtm_scanf(const char *format, ...);
int gtm_fscanf(FILE *stream, const char *format, ...);
int gtm_sscanf(char *str, const char *format, ...);
#else
# define SCANF scanf
# define SSCANF sscanf
# define FSCANF fscanf
#endif
#define VPRINTF(FORMAT, VALUE, RC) \
{ \
do \
{ \
RC = vprintf(FORMAT, VALUE); \
} while(-1 == RC && EINTR == errno); \
}
#define VFPRINTF(STREAM, FORMAT, VALUE, RC) \
{ \
do \
{ \
RC = vfprintf(STREAM, FORMAT, VALUE); \
} while(-1 == RC && EINTR == errno); \
}
#define VSPRINTF(STRING, FORMAT, VALUE, RC) \
{ \
do \
{ \
RC = vsprintf(STRING, FORMAT, VALUE); \
} while(-1 == RC && EINTR == errno); \
}
#define VSNPRINTF(STRING, SIZE, FORMAT, VALUE, RC) \
{ \
do \
{ \
RC = vsnprintf(STRING, SIZE, FORMAT, VALUE); \
} while(-1 == RC && EINTR == errno); \
}
/* Note TRU64 does not have these v*scanf() functions so they will generate errors if used */
#define VSCANF(FORMAT, POINTER, RC) \
{ \
do \
{ \
RC = vscanf(FORMAT, POINTER); \
} while(-1 == RC && EINTR == errno); \
}
#define VSSCANF(STRING, FORMAT, POINTER, RC) \
{ \
do \
{ \
RC = vsscanf(STRING, FORMAT, POINTER); \
} while(-1 == RC && EINTR == errno); \
}
#define VFSCANF(STREAM, FORMAT, POINTER, RC) \
{ \
do \
{ \
RC = vfscanf(STREAM, FORMAT, POINTER); \
} while(-1 == RC && EINTR == errno); \
}
#define SPRINTF_ENV_NUM(BUFF, ENV_VAR, ENV_VAL, ENV_IND) \
{ \
assert(NULL == strchr(ENV_VAR, '=')); /* strchr() done in ojstartchild() relies on this */ \
SPRINTF(BUFF, "%s=%d", ENV_VAR, ENV_VAL); *ENV_IND++ = BUFF; \
}
#define SPRINTF_ENV_STR(BUFF, ENV_VAR, ENV_VAL, ENV_IND) \
{ \
assert(NULL == strchr(ENV_VAR, '=')); /* strchr() done in ojstartchild() relies on this */ \
SPRINTF(BUFF, "%s=%s", ENV_VAR, ENV_VAL); *ENV_IND++ = BUFF; \
}
#endif

50
pro/gtm_stdlib.h Normal file
View File

@ -0,0 +1,50 @@
/****************************************************************
* *
* Copyright 2001, 2007 Fidelity Information Services, Inc *
* *
* This source code contains the intellectual property *
* of its copyright holder(s), and is made available *
* under a license. If you do not know the terms of *
* the license, please stop and do not read further. *
* *
****************************************************************/
/* gtm_stdlib.h - interlude to <stdlib.h> system header file. */
#ifndef GTM_STDLIBH
#define GTM_STDLIBH
#include <stdlib.h>
#ifndef __CYGWIN__
#define GETENV getenv
#else
char *gtm_getenv(char *varname);
#define GETENV gtm_getenv
#endif
#define ATOI atoi
#define ATOL atol
#define ATOF atof
#define PUTENV putenv
#define STRTOL strtol
#define STRTOLL strtoll
#define STRTOUL strtoul
#if INT_MAX < LONG_MAX /* like Tru64 */
#define STRTO64L strtol
#define STRTOU64L strtoul
#elif defined(__hpux)
#include <inttypes.h>
#define STRTO64L strtoimax
#define STRTOU64L strtoumax
#else
#define STRTO64L strtoll
#define STRTOU64L strtoull
#endif
#define MKSTEMP(template,mkstemp_res) (mkstemp_res = mkstemp(template))
#ifndef __CYGWIN__
#define SYSTEM system
#else
#define SYSTEM gtm_system
int gtm_system(const char *line);
#endif
#endif

32
pro/gtm_string.h Normal file
View File

@ -0,0 +1,32 @@
/****************************************************************
* *
* Copyright 2001, 2011 Fidelity Information Services, Inc *
* *
* This source code contains the intellectual property *
* of its copyright holder(s), and is made available *
* under a license. If you do not know the terms of *
* the license, please stop and do not read further. *
* *
****************************************************************/
/* If this is not the vax, define string.h. This is because the Vax
has its own built-in instructions for string manipulation.
*/
#ifndef GTM_STRINGH
#define GTM_STRINGH
#ifndef __vax
# include <string.h>
#endif
#define STRERROR strerror
#define STRCPY(SOURCE, DEST) strcpy((char *)(SOURCE), (char *)(DEST))
#define STRNCPY_LIT(SOURCE, LITERAL) strncpy((char *)(SOURCE), (char *)(LITERAL), SIZEOF(LITERAL) - 1) /* BYPASSOK */
#define STRNCPY_STR(SOURCE, STRING, LEN) strncpy((char *)(SOURCE), (char *)(STRING), LEN)
#define STRCMP(SOURCE, DEST) strcmp((char *)(SOURCE), (char *)(DEST))
#define STRNCMP_LIT(SOURCE, LITERAL) strncmp(SOURCE, LITERAL, SIZEOF(LITERAL) - 1) /* BYPASSOK */
#define STRNCMP_STR(SOURCE, STRING, LEN) strncmp(SOURCE, STRING, LEN)
#endif

20
pro/gtm_strings.h Normal file
View File

@ -0,0 +1,20 @@
/****************************************************************
* *
* Copyright 2009 Fidelity Information Services, Inc *
* *
* This source code contains the intellectual property *
* of its copyright holder(s), and is made available *
* under a license. If you do not know the terms of *
* the license, please stop and do not read further. *
* *
****************************************************************/
#ifndef GTM_STRINGSH
#define GTM_STRINGSH
#include <strings.h>
#define STRCASECMP strcasecmp
#define STRNCASECMP strncasecmp
#endif

87
pro/gtmxc_types.h Normal file
View File

@ -0,0 +1,87 @@
/****************************************************************
* *
* Copyright 2001, 2011 Fidelity Information Services, Inc *
* *
* This source code contains the intellectual property *
* of its copyright holder(s), and is made available *
* under a license. If you do not know the terms of *
* the license, please stop and do not read further. *
* *
****************************************************************/
/* gtmxc_types.h - GT.M, Unix Edition External Call type definitions. */
#ifndef GTMXC_TYPES_H
#define GTMXC_TYPES_H
#ifdef __osf__
/* Ensure 32-bit pointers for compatibility with GT.M internal representations. */
#pragma pointer_size (save)
#pragma pointer_size (short)
#endif
typedef int xc_status_t;
typedef int xc_int_t;
typedef unsigned int xc_uint_t;
#if defined(__osf__)
typedef int xc_long_t;
typedef unsigned int xc_ulong_t;
#else
typedef long xc_long_t;
typedef unsigned long xc_ulong_t;
#endif
typedef float xc_float_t;
typedef double xc_double_t;
typedef char xc_char_t;
typedef int (*xc_pointertofunc_t)();
typedef struct
{
xc_long_t length;
xc_char_t *address;
} xc_string_t;
#ifdef __osf__
#pragma pointer_size (restore)
#endif
/* new types for external/call-in user - xc_* types still valid for backward compatibility */
typedef xc_status_t gtm_status_t;
typedef xc_int_t gtm_int_t;
typedef xc_uint_t gtm_uint_t;
typedef xc_long_t gtm_long_t;
typedef xc_ulong_t gtm_ulong_t;
typedef xc_float_t gtm_float_t;
typedef xc_double_t gtm_double_t;
typedef xc_char_t gtm_char_t;
typedef xc_string_t gtm_string_t;
typedef xc_pointertofunc_t gtm_pointertofunc_t;
typedef struct
{
gtm_string_t rtn_name;
void* handle;
} ci_name_descriptor;
/* call-in interface */
xc_status_t gtm_ci(const char *c_rtn_name, ...);
xc_status_t gtm_cip(ci_name_descriptor *ci_info, ...);
xc_status_t gtm_init(void);
xc_status_t gtm_exit(void);
void gtm_zstatus(char* msg, int len);
typedef int gtmcrypt_key_t;
typedef void *xc_fileid_ptr_t;
xc_status_t gtm_filename_to_id(xc_string_t *filename, xc_fileid_ptr_t *fileid);
xc_status_t gtm_is_file_identical(xc_fileid_ptr_t fileid1, xc_fileid_ptr_t fileid2);
void gtm_xcfileid_free(xc_fileid_ptr_t fileid);
void *gtm_malloc(size_t);
void gtm_free(void *);
#endif /* GTMXC_TYPES_H */

21
pro/main_pragma.h Normal file
View File

@ -0,0 +1,21 @@
/****************************************************************
* *
* Copyright 2009 Fidelity Information Services, Inc *
* *
* This source code contains the intellectual property *
* of its copyright holder(s), and is made available *
* under a license. If you do not know the terms of *
* the license, please stop and do not read further. *
* *
****************************************************************/
#ifndef MAIN_PRAGMA_included
#define MAIN_PRAGMA_included
#ifdef __MVS__
#pragma runopts(ENVAR(_BPXK_AUTOCVT=ON))
#pragma runopts(FILETAG(AUTOCVT,AUTOTAG))
#endif
#endif /* MAIN_PRAGMA_included */

35
pro/obj/cmerrors_ctl.c Normal file
View File

@ -0,0 +1,35 @@
/****************************************************************
* *
* Copyright 2001,2012 Fidelity Information Services, Inc *
* *
* This source code contains the intellectual property *
* of its copyright holder(s), and is made available *
* under a license. If you do not know the terms of *
* the license, please stop and do not read further. *
* *
****************************************************************/
#include "mdef.h"
#include "error.h"
LITDEF err_msg cmerrors[] = {
"INVPROT", "Invalid protocol specified by remote partner", 0,
"REGNTFND", "Region referenced not initialized", 0,
"CMINTQUE", "Interlock failure accessing GT.CM server queue", 0,
"INVINTMSG", "Invalid interrupt message received.", 0,
"CMEXCDASTLM", "Exceeded AST limit. Cannot open database.", 0,
"CMSYSSRV", "Error doing system service, status:", 0,
};
LITDEF int CMERR_INVPROT = 150568970;
LITDEF int CMERR_REGNTFND = 150568978;
LITDEF int CMERR_CMINTQUE = 150568988;
LITDEF int CMERR_INVINTMSG = 150568994;
LITDEF int CMERR_CMEXCDASTLM = 150569002;
LITDEF int CMERR_CMSYSSRV = 150569010;
GBLDEF err_ctl cmerrors_ctl = {
249,
"GTCM",
&cmerrors[0],
6};

73
pro/obj/cmierrors_ctl.c Normal file
View File

@ -0,0 +1,73 @@
/****************************************************************
* *
* Copyright 2001,2012 Fidelity Information Services, Inc *
* *
* This source code contains the intellectual property *
* of its copyright holder(s), and is made available *
* under a license. If you do not know the terms of *
* the license, please stop and do not read further. *
* *
****************************************************************/
#include "mdef.h"
#include "error.h"
LITDEF err_msg cmierrors[] = {
"DCNINPROG", "Attempt to initiate operation while disconnect was in progress", 0,
"LNKNOTIDLE", "Attempt to initiate operation before previous operation completed", 0,
"ASSERT", "Assert failed !AD line !UL", 3,
"CMICHECK", "Internal CMI error. Report to your GT.M Support Channel.", 0,
"NETFAIL", "Failure of Net operation", 0,
"BADPORT", "Environment variable GTCM_TCP_PORT is not an integer", 0,
"NOTND", "tnd argument to cmi_init is NULL", 0,
"OVERRUN", "mbf argument in CLB is not large enough for packet", 0,
"NOSERVENT", "Sevices data lookup failure", 0,
"BADIPADDRPORT", "Bad specification of [ip address:port] in tnd", 0,
"REASON_CONNECT", "Incoming connection", 0,
"REASON_INTMSG", "Incoming urgent data", 0,
"REASON_DISCON", "Disconnect encountered", 0,
"REASON_ABORT", "Link aborted", 0,
"REASON_EXIT", "Exit", 0,
"REASON_PATHLOST", "Network path lost", 0,
"REASON_PROTOCOL", "Protocol error", 0,
"REASON_THIRDPARTY", "Thirdparty error", 0,
"REASON_TIMEOUT", "Network timeout", 0,
"REASON_NETSHUT", "Shutdown received", 0,
"REASON_REJECT", "Connection rejected", 0,
"REASON_IODONE", "I/O done", 0,
"REASON_OVERRUN", "Input overran buffer", 0,
"REASON_STATUS", "Status", 0,
"REASON_CONFIRM", "Confirm", 0,
};
LITDEF int CMI_DCNINPROG = 150634508;
LITDEF int CMI_LNKNOTIDLE = 150634516;
LITDEF int CMI_ASSERT = 150634522;
LITDEF int CMI_CMICHECK = 150634532;
LITDEF int CMI_NETFAIL = 150634538;
LITDEF int CMI_BADPORT = 150634546;
LITDEF int CMI_NOTND = 150634556;
LITDEF int CMI_OVERRUN = 150634562;
LITDEF int CMI_NOSERVENT = 150634570;
LITDEF int CMI_BADIPADDRPORT = 150634578;
LITDEF int CMI_REASON_CONNECT = 150634586;
LITDEF int CMI_REASON_INTMSG = 150634594;
LITDEF int CMI_REASON_DISCON = 150634602;
LITDEF int CMI_REASON_ABORT = 150634610;
LITDEF int CMI_REASON_EXIT = 150634618;
LITDEF int CMI_REASON_PATHLOST = 150634626;
LITDEF int CMI_REASON_PROTOCOL = 150634634;
LITDEF int CMI_REASON_THIRDPARTY = 150634642;
LITDEF int CMI_REASON_TIMEOUT = 150634650;
LITDEF int CMI_REASON_NETSHUT = 150634658;
LITDEF int CMI_REASON_REJECT = 150634666;
LITDEF int CMI_REASON_IODONE = 150634674;
LITDEF int CMI_REASON_OVERRUN = 150634682;
LITDEF int CMI_REASON_STATUS = 150634690;
LITDEF int CMI_REASON_CONFIRM = 150634698;
GBLDEF err_ctl cmierrors_ctl = {
250,
"CMI",
&cmierrors[0],
25};

135
pro/obj/gdeerrors_ctl.c Normal file
View File

@ -0,0 +1,135 @@
/****************************************************************
* *
* Copyright 2001,2012 Fidelity Information Services, Inc *
* *
* This source code contains the intellectual property *
* of its copyright holder(s), and is made available *
* under a license. If you do not know the terms of *
* the license, please stop and do not read further. *
* *
****************************************************************/
#include "mdef.h"
#include "error.h"
LITDEF err_msg gdeerrors[] = {
"BLKSIZ512", "Block size !AD rounds to !AD", 4,
"EXECOM", "Executing command file !AD", 2,
"FNF", "File not found: !AD", 2,
"GDCREATE", "Creating Global Directory file !/ !AD", 2,
"GDECHECK", "Internal GDE consistency check", 0,
"GDUNKNFMT", "!AD !/ is not formatted as a Global Directory", 2,
"GDUPDATE", "Updating Global Directory file !/ !AD", 2,
"GDUSEDEFS", "Using defaults for Global Directory !/ !AD", 2,
"ILLCHAR", "!AD is not a legal character in this context", 2,
"INPINTEG", "Input integrity error -- aborting load", 0,
"KEYTOOBIG", "But record size !AD can only support key size !AD", 4,
"KEYSIZIS", "Key size is !AD", 2,
"KEYWRDAMB", "!AD is ambiguous for !AD", 4,
"KEYWRDBAD", "!AD is not a valid !AD", 4,
"LOADGD", "Loading Global Directory file !/ !AD", 2,
"LOGOFF", "No longer logging to file !AD", 2,
"LOGON", "Logging to file !AD", 2,
"LVSTARALON", "The * name cannot be deleted or renamed", 0,
"MAPBAD", "!AD !AD for !AD !AD does not exist", 8,
"MAPDUP", "!AD !AD and !AD both map to !AD !AD", 10,
"NAMSTARTBAD", "!AD must start with '%' or an alphabetic character", 2,
"NOACTION", "Not updating Global Directory !AD", 2,
"RPAREN", "List must end with right parenthesis or continue with comma", 0,
"NOEXIT", "Cannot exit because of verification failure", 0,
"NOLOG", "Logging is currently disabled!/ Log file is !AD.", 2,
"NOVALUE", "Qualifier !AD does not take a value", 2,
"NONEGATE", "Qualifier !AD cannot be negated", 2,
"OBJDUP", "!AD !AD already exists", 4,
"OBJNOTADD", "Not adding !AD !AD", 4,
"OBJNOTCHG", "Not changing !AD !AD", 4,
"OBJNOTFND", "!AD !AD does not exist", 4,
"OBJREQD", "!AD required", 2,
"PREFIXBAD", "!AD must start with an alphabetic character to be a !AD", 4,
"QUALBAD", "!AD is not a valid qualifier", 2,
"QUALDUP", "!AD qualifier appears more than once in the list", 2,
"QUALREQD", "!AD required", 2,
"RECTOOBIG", "Block size !AD and !AD reserved bytes limit record size to !AD", 6,
"RECSIZIS", "Record size is !AD", 2,
"REGIS", "in region !AD", 2,
"SEGIS", "in !AD segment !AD", 4,
"VALTOOBIG", "!AD is larger than the maximum of !AD for a !AD", 6,
"VALTOOLONG", "!AD exceeds the maximum length of !AD for a !AD", 6,
"VALTOOSMALL", "!AD is less than the minimum of !AD for a !AD", 6,
"VALUEBAD", "!AD is not a valid !AD", 4,
"VALUEREQD", "Qualifier !AD requires a value", 2,
"VERIFY", "Verification !AD", 2,
"BUFSIZIS", "Journal Buffer size is !AD", 2,
"BUFTOOSMALL", "But block size !AD requires buffer size !AD", 4,
"MMNOBEFORIMG", "MM segments do not support before image jounaling", 0,
"NOJNL", "!AD segments do not support journaling", 2,
"GDREADERR", "Error reading Global Directory: !AD", 2,
"GDNOTSET", "Global Directory not changed because the current GD cannot be written", 0,
"INVGBLDIR", "Invalid Global Directory spec: !AD.!/Continuing with !AD", 4,
"WRITEERROR", "Cannot exit because of write failure. Reason for failure: !AD", 2,
"NONASCII", "!AD is illegal for a !AD as it contains non-ASCII characters", 4,
"ENCNOMM", "!AD No encryption support for MM access method", 2,
};
LITDEF int GDE_BLKSIZ512 = 150503435;
LITDEF int GDE_EXECOM = 150503443;
LITDEF int GDE_FNF = 150503451;
LITDEF int GDE_GDCREATE = 150503459;
LITDEF int GDE_GDECHECK = 150503467;
LITDEF int GDE_GDUNKNFMT = 150503475;
LITDEF int GDE_GDUPDATE = 150503483;
LITDEF int GDE_GDUSEDEFS = 150503491;
LITDEF int GDE_ILLCHAR = 150503498;
LITDEF int GDE_INPINTEG = 150503508;
LITDEF int GDE_KEYTOOBIG = 150503515;
LITDEF int GDE_KEYSIZIS = 150503523;
LITDEF int GDE_KEYWRDAMB = 150503530;
LITDEF int GDE_KEYWRDBAD = 150503538;
LITDEF int GDE_LOADGD = 150503547;
LITDEF int GDE_LOGOFF = 150503555;
LITDEF int GDE_LOGON = 150503563;
LITDEF int GDE_LVSTARALON = 150503570;
LITDEF int GDE_MAPBAD = 150503579;
LITDEF int GDE_MAPDUP = 150503587;
LITDEF int GDE_NAMSTARTBAD = 150503594;
LITDEF int GDE_NOACTION = 150503603;
LITDEF int GDE_RPAREN = 150503610;
LITDEF int GDE_NOEXIT = 150503619;
LITDEF int GDE_NOLOG = 150503627;
LITDEF int GDE_NOVALUE = 150503634;
LITDEF int GDE_NONEGATE = 150503642;
LITDEF int GDE_OBJDUP = 150503650;
LITDEF int GDE_OBJNOTADD = 150503658;
LITDEF int GDE_OBJNOTCHG = 150503666;
LITDEF int GDE_OBJNOTFND = 150503674;
LITDEF int GDE_OBJREQD = 150503682;
LITDEF int GDE_PREFIXBAD = 150503690;
LITDEF int GDE_QUALBAD = 150503698;
LITDEF int GDE_QUALDUP = 150503706;
LITDEF int GDE_QUALREQD = 150503714;
LITDEF int GDE_RECTOOBIG = 150503723;
LITDEF int GDE_RECSIZIS = 150503731;
LITDEF int GDE_REGIS = 150503739;
LITDEF int GDE_SEGIS = 150503747;
LITDEF int GDE_VALTOOBIG = 150503755;
LITDEF int GDE_VALTOOLONG = 150503762;
LITDEF int GDE_VALTOOSMALL = 150503771;
LITDEF int GDE_VALUEBAD = 150503778;
LITDEF int GDE_VALUEREQD = 150503786;
LITDEF int GDE_VERIFY = 150503795;
LITDEF int GDE_BUFSIZIS = 150503803;
LITDEF int GDE_BUFTOOSMALL = 150503811;
LITDEF int GDE_MMNOBEFORIMG = 150503819;
LITDEF int GDE_NOJNL = 150503827;
LITDEF int GDE_GDREADERR = 150503835;
LITDEF int GDE_GDNOTSET = 150503843;
LITDEF int GDE_INVGBLDIR = 150503851;
LITDEF int GDE_WRITEERROR = 150503859;
LITDEF int GDE_NONASCII = 150503866;
LITDEF int GDE_ENCNOMM = 150503874;
GBLDEF err_ctl gdeerrors_ctl = {
248,
"GDE",
&gdeerrors[0],
56};

View File

@ -0,0 +1,442 @@
/****************************************************************
* *
* Copyright 2010, 2012 Fidelity Information Services, Inc *
* *
* This source code contains the intellectual property *
* of its copyright holder(s), and is made available *
* under a license. If you do not know the terms of *
* the license, please stop and do not read further. *
* *
****************************************************************/
/* Generated by /home/ibanez/src/fis-gtm/sr_linux/gen_gtm_threadgbl_deftypes.csh */
#ifndef GTM_THREADGBL_DEFTYPES_INCLUDED
#define GTM_THREADGBL_DEFTYPES_INCLUDED
/* Output selection criteria for PRO build */
#if !defined(DEBUG) || defined(PRO_BUILD)
# define ggo_grabbing_crit 0
# define ggt_grabbing_crit gd_region *
# define ggo_code_generated 4
# define ggt_code_generated boolean_t
# define ggo_compile_time 8
# define ggt_compile_time boolean_t
# define ggo_dollar_zcstatus 12
# define ggt_dollar_zcstatus int4
# define ggo_expr_depth 16
# define ggt_expr_depth unsigned int
# define ggo_expr_start 20
# define ggt_expr_start triple *
# define ggo_expr_start_orig 24
# define ggt_expr_start_orig triple *
# define ggo_for_nest_level 28
# define ggt_for_nest_level uint4
# define ggo_for_stack_ptr 32
# define ggt_for_stack_ptr oprtype **
# define ggo_gtm_fullbool 36
# define ggt_gtm_fullbool unsigned int
# define ggo_last_source_column 40
# define ggt_last_source_column short int
# define ggo_pos_in_chain 44
# define ggt_pos_in_chain triple
# define ggo_s2n_intlit 116
# define ggt_s2n_intlit boolean_t
# define ggo_shift_side_effects 120
# define ggt_shift_side_effects int
# define ggo_source_error_found 124
# define ggt_source_error_found int4
# define ggo_temp_subs 128
# define ggt_temp_subs boolean_t
# define ggo_trigger_compile 132
# define ggt_trigger_compile boolean_t
# define ggo_donot_commit 136
# define ggt_donot_commit boolean_t
# define ggo_gd_targ_addr 140
# define ggt_gd_targ_addr gd_addr *
# define ggo_gtm_gvundef_fatal 144
# define ggt_gtm_gvundef_fatal boolean_t
# define ggo_gv_extname_size 148
# define ggt_gv_extname_size int4
# define ggo_gv_last_subsc_null 152
# define ggt_gv_last_subsc_null boolean_t
# define ggo_gv_mergekey2 156
# define ggt_gv_mergekey2 gv_key *
# define ggo_gv_reorgkey 160
# define ggt_gv_reorgkey gv_key *
# define ggo_gv_some_subsc_null 164
# define ggt_gv_some_subsc_null boolean_t
# define ggo_gv_sparekey 168
# define ggt_gv_sparekey gv_key *
# define ggo_gv_sparekey_mval 172
# define ggt_gv_sparekey_mval mval
# define ggo_gv_sparekey_size 196
# define ggt_gv_sparekey_size int4
# define ggo_gv_tporigkey_ptr 200
# define ggt_gv_tporigkey_ptr gv_orig_key_array *
# define ggo_in_op_gvget 204
# define ggt_in_op_gvget boolean_t
# define ggo_last_fnquery_return_subcnt 208
# define ggt_last_fnquery_return_subcnt int
# define ggo_last_fnquery_return_varname 212
# define ggt_last_fnquery_return_varname mval
# define ggo_ok_to_call_wcs_recover 236
# define ggt_ok_to_call_wcs_recover boolean_t
# define ggo_prev_gv_target 240
# define ggt_prev_gv_target gv_namehead *
# define ggo_ready2signal_gvundef 244
# define ggt_ready2signal_gvundef boolean_t
# define ggo_semop2long 248
# define ggt_semop2long volatile boolean_t
# define ggo_semwait2long 252
# define ggt_semwait2long volatile boolean_t
# define ggo_tp_restart_count 256
# define ggt_tp_restart_count uint4
# define ggo_tp_restart_dont_counts 260
# define ggt_tp_restart_dont_counts uint4
# define ggo_tp_restart_entryref 264
# define ggt_tp_restart_entryref mval
# define ggo_tp_restart_failhist_indx 288
# define ggt_tp_restart_failhist_indx int4
# define ggo_tp_restart_needlock_tn 292
# define ggt_tp_restart_needlock_tn trans_num
# define ggo_tp_restart_needlock_cnt 300
# define ggt_tp_restart_needlock_cnt uint4
# define ggo_transform 304
# define ggt_transform boolean_t
# define ggo_in_op_fnnext 308
# define ggt_in_op_fnnext boolean_t
# define ggo_local_collseq 312
# define ggt_local_collseq collseq *
# define ggo_local_collseq_stdnull 316
# define ggt_local_collseq_stdnull boolean_t
# define ggo_lv_null_subs 320
# define ggt_lv_null_subs int
# define ggo_max_lcl_coll_xform_bufsiz 324
# define ggt_max_lcl_coll_xform_bufsiz int
# define ggo_replgbl 328
# define ggt_replgbl replgbl_t
# define ggo_collseq_list 360
# define ggt_collseq_list collseq *
# define ggo_create_fatal_error_zshow_dmp_fptr 364
# define ggt_create_fatal_error_zshow_dmp_fptr void
# define gga_create_fatal_error_zshow_dmp_fptr ()
typedef void (*ggf_create_fatal_error_zshow_dmp_fptr)();
# define ggo_disable_sigcont 368
# define ggt_disable_sigcont boolean_t
# define ggo_dollar_zcompile 372
# define ggt_dollar_zcompile mstr
# define ggo_dollar_zmode 384
# define ggt_dollar_zmode mval
# define ggo_dollar_zroutines 408
# define ggt_dollar_zroutines mstr
# define ggo_error_on_jnl_file_lost 420
# define ggt_error_on_jnl_file_lost unsigned int
# define ggo_fnzsearch_lv_vars 424
# define ggt_fnzsearch_lv_vars lv_val *
# define ggo_fnzsearch_sub_mval 428
# define ggt_fnzsearch_sub_mval mval
# define ggo_fnzsearch_nullsubs_sav 452
# define ggt_fnzsearch_nullsubs_sav int
# define ggo_gtm_env_init_done 456
# define ggt_gtm_env_init_done boolean_t
# define ggo_gtm_env_xlate_entry 460
# define ggt_gtm_env_xlate_entry int
# define gga_gtm_env_xlate_entry ()
typedef int (*ggf_gtm_env_xlate_entry)();
# define ggo_gtm_environment_init 464
# define ggt_gtm_environment_init boolean_t
# define ggo_gtm_sigusr1_handler 468
# define ggt_gtm_sigusr1_handler void
# define gga_gtm_sigusr1_handler ()
typedef void (*ggf_gtm_sigusr1_handler)();
# define ggo_gtm_waitstuck_script 472
# define ggt_gtm_waitstuck_script mstr
# define ggo_gtmprompt 484
# define ggt_gtmprompt mstr
# define ggo_in_zwrite 496
# define ggt_in_zwrite boolean_t
# define ggo_mprof_chunk_avail_size 500
# define ggt_mprof_chunk_avail_size int
# define ggo_mprof_ptr 504
# define ggt_mprof_ptr mprof_wrapper *
# define ggo_mprof_stack_curr_frame 508
# define ggt_mprof_stack_curr_frame mprof_stack_frame *
# define ggo_mprof_stack_next_frame 512
# define ggt_mprof_stack_next_frame mprof_stack_frame *
# define ggo_open_shlib_root 516
# define ggt_open_shlib_root open_shlib *
# define ggo_parms_cnt 520
# define ggt_parms_cnt unsigned int
# define ggo_pipefifo_interrupt 524
# define ggt_pipefifo_interrupt int
# define ggo_prof_fp 528
# define ggt_prof_fp mprof_stack_frame *
# define ggo_trans_code_pop 532
# define ggt_trans_code_pop mval *
# define ggo_view_ydirt_str 536
# define ggt_view_ydirt_str char *
# define ggo_view_ydirt_str_len 540
# define ggt_view_ydirt_str_len int4
# define ggo_zdate_form 544
# define ggt_zdate_form int4
# define ggo_zro_root 548
# define ggt_zro_root zro_ent *
# define ggo_zsearch_var 552
# define ggt_zsearch_var lv_val *
# define ggo_zsearch_dir1 556
# define ggt_zsearch_dir1 lv_val *
# define ggo_zsearch_dir2 560
# define ggt_zsearch_dir2 lv_val *
# define ggo_fnpca 564
# define ggt_fnpca fnpc_area
# define ggo_for_stack 18372
# define ggt_for_stack oprtype *
# define ggl_for_stack 128
# define ggo_for_temps 18500
# define ggt_for_temps boolean_t
# define ggl_for_temps 128
# define ggo_last_fnquery_return_sub 18628
# define ggt_last_fnquery_return_sub mval
# define ggl_last_fnquery_return_sub 768
# define ggo_lcl_coll_xform_buff 19396
# define ggt_lcl_coll_xform_buff char *
# define ggo_parm_ary 19400
# define ggt_parm_ary char *
# define ggl_parm_ary 20
# define ggo_parm_ary_len 19420
# define ggt_parm_ary_len int
# define ggl_parm_ary_len 20
# define ggo_parm_str_len 19440
# define ggt_parm_str_len int
# define ggl_parm_str_len 20
# define ggo_prombuf 19460
# define ggt_prombuf char
# define ggl_prombuf 32
# define ggo_rt_name_tbl 19492
# define ggt_rt_name_tbl hash_table_mname
# define ggo_tp_restart_failhist_arry 19548
# define ggt_tp_restart_failhist_arry char
# define ggl_tp_restart_failhist_arry 32
# define ggo_callin_hashtab 19580
# define ggt_callin_hashtab hash_table_str *
# define ggo_ci_table 19584
# define ggt_ci_table callin_entry_list *
# define ggo_extcall_package_root 19588
# define ggt_extcall_package_root struct extcall_package_list *
# define ggo_gtmci_nested_level 19592
# define ggt_gtmci_nested_level unsigned int
# define size_gtm_threadgbl_struct 19596
#else
# define ggo_grabbing_crit 0
# define ggt_grabbing_crit gd_region *
# define ggo_code_generated 4
# define ggt_code_generated boolean_t
# define ggo_compile_time 8
# define ggt_compile_time boolean_t
# define ggo_dollar_zcstatus 12
# define ggt_dollar_zcstatus int4
# define ggo_expr_depth 16
# define ggt_expr_depth unsigned int
# define ggo_expr_start 20
# define ggt_expr_start triple *
# define ggo_expr_start_orig 24
# define ggt_expr_start_orig triple *
# define ggo_for_nest_level 28
# define ggt_for_nest_level uint4
# define ggo_for_stack_ptr 32
# define ggt_for_stack_ptr oprtype **
# define ggo_gtm_fullbool 36
# define ggt_gtm_fullbool unsigned int
# define ggo_last_source_column 40
# define ggt_last_source_column short int
# define ggo_pos_in_chain 44
# define ggt_pos_in_chain triple
# define ggo_s2n_intlit 116
# define ggt_s2n_intlit boolean_t
# define ggo_shift_side_effects 120
# define ggt_shift_side_effects int
# define ggo_source_error_found 124
# define ggt_source_error_found int4
# define ggo_temp_subs 128
# define ggt_temp_subs boolean_t
# define ggo_trigger_compile 132
# define ggt_trigger_compile boolean_t
# define ggo_donot_commit 136
# define ggt_donot_commit boolean_t
# define ggo_gd_targ_addr 140
# define ggt_gd_targ_addr gd_addr *
# define ggo_gtm_gvundef_fatal 144
# define ggt_gtm_gvundef_fatal boolean_t
# define ggo_gv_extname_size 148
# define ggt_gv_extname_size int4
# define ggo_gv_last_subsc_null 152
# define ggt_gv_last_subsc_null boolean_t
# define ggo_gv_mergekey2 156
# define ggt_gv_mergekey2 gv_key *
# define ggo_gv_reorgkey 160
# define ggt_gv_reorgkey gv_key *
# define ggo_gv_some_subsc_null 164
# define ggt_gv_some_subsc_null boolean_t
# define ggo_gv_sparekey 168
# define ggt_gv_sparekey gv_key *
# define ggo_gv_sparekey_mval 172
# define ggt_gv_sparekey_mval mval
# define ggo_gv_sparekey_size 196
# define ggt_gv_sparekey_size int4
# define ggo_gv_tporigkey_ptr 200
# define ggt_gv_tporigkey_ptr gv_orig_key_array *
# define ggo_in_op_gvget 204
# define ggt_in_op_gvget boolean_t
# define ggo_last_fnquery_return_subcnt 208
# define ggt_last_fnquery_return_subcnt int
# define ggo_last_fnquery_return_varname 212
# define ggt_last_fnquery_return_varname mval
# define ggo_ok_to_call_wcs_recover 236
# define ggt_ok_to_call_wcs_recover boolean_t
# define ggo_prev_gv_target 240
# define ggt_prev_gv_target gv_namehead *
# define ggo_ready2signal_gvundef 244
# define ggt_ready2signal_gvundef boolean_t
# define ggo_semop2long 248
# define ggt_semop2long volatile boolean_t
# define ggo_semwait2long 252
# define ggt_semwait2long volatile boolean_t
# define ggo_tp_restart_count 256
# define ggt_tp_restart_count uint4
# define ggo_tp_restart_dont_counts 260
# define ggt_tp_restart_dont_counts uint4
# define ggo_tp_restart_entryref 264
# define ggt_tp_restart_entryref mval
# define ggo_tp_restart_failhist_indx 288
# define ggt_tp_restart_failhist_indx int4
# define ggo_tp_restart_needlock_tn 292
# define ggt_tp_restart_needlock_tn trans_num
# define ggo_tp_restart_needlock_cnt 300
# define ggt_tp_restart_needlock_cnt uint4
# define ggo_transform 304
# define ggt_transform boolean_t
# define ggo_in_op_fnnext 308
# define ggt_in_op_fnnext boolean_t
# define ggo_local_collseq 312
# define ggt_local_collseq collseq *
# define ggo_local_collseq_stdnull 316
# define ggt_local_collseq_stdnull boolean_t
# define ggo_lv_null_subs 320
# define ggt_lv_null_subs int
# define ggo_max_lcl_coll_xform_bufsiz 324
# define ggt_max_lcl_coll_xform_bufsiz int
# define ggo_replgbl 328
# define ggt_replgbl replgbl_t
# define ggo_collseq_list 360
# define ggt_collseq_list collseq *
# define ggo_create_fatal_error_zshow_dmp_fptr 364
# define ggt_create_fatal_error_zshow_dmp_fptr void
# define gga_create_fatal_error_zshow_dmp_fptr ()
typedef void (*ggf_create_fatal_error_zshow_dmp_fptr)();
# define ggo_disable_sigcont 368
# define ggt_disable_sigcont boolean_t
# define ggo_dollar_zcompile 372
# define ggt_dollar_zcompile mstr
# define ggo_dollar_zmode 384
# define ggt_dollar_zmode mval
# define ggo_dollar_zroutines 408
# define ggt_dollar_zroutines mstr
# define ggo_error_on_jnl_file_lost 420
# define ggt_error_on_jnl_file_lost unsigned int
# define ggo_fnzsearch_lv_vars 424
# define ggt_fnzsearch_lv_vars lv_val *
# define ggo_fnzsearch_sub_mval 428
# define ggt_fnzsearch_sub_mval mval
# define ggo_fnzsearch_nullsubs_sav 452
# define ggt_fnzsearch_nullsubs_sav int
# define ggo_gtm_env_init_done 456
# define ggt_gtm_env_init_done boolean_t
# define ggo_gtm_env_xlate_entry 460
# define ggt_gtm_env_xlate_entry int
# define gga_gtm_env_xlate_entry ()
typedef int (*ggf_gtm_env_xlate_entry)();
# define ggo_gtm_environment_init 464
# define ggt_gtm_environment_init boolean_t
# define ggo_gtm_sigusr1_handler 468
# define ggt_gtm_sigusr1_handler void
# define gga_gtm_sigusr1_handler ()
typedef void (*ggf_gtm_sigusr1_handler)();
# define ggo_gtm_waitstuck_script 472
# define ggt_gtm_waitstuck_script mstr
# define ggo_gtmprompt 484
# define ggt_gtmprompt mstr
# define ggo_in_zwrite 496
# define ggt_in_zwrite boolean_t
# define ggo_mprof_chunk_avail_size 500
# define ggt_mprof_chunk_avail_size int
# define ggo_mprof_ptr 504
# define ggt_mprof_ptr mprof_wrapper *
# define ggo_mprof_stack_curr_frame 508
# define ggt_mprof_stack_curr_frame mprof_stack_frame *
# define ggo_mprof_stack_next_frame 512
# define ggt_mprof_stack_next_frame mprof_stack_frame *
# define ggo_open_shlib_root 516
# define ggt_open_shlib_root open_shlib *
# define ggo_parms_cnt 520
# define ggt_parms_cnt unsigned int
# define ggo_pipefifo_interrupt 524
# define ggt_pipefifo_interrupt int
# define ggo_prof_fp 528
# define ggt_prof_fp mprof_stack_frame *
# define ggo_trans_code_pop 532
# define ggt_trans_code_pop mval *
# define ggo_view_ydirt_str 536
# define ggt_view_ydirt_str char *
# define ggo_view_ydirt_str_len 540
# define ggt_view_ydirt_str_len int4
# define ggo_zdate_form 544
# define ggt_zdate_form int4
# define ggo_zro_root 548
# define ggt_zro_root zro_ent *
# define ggo_zsearch_var 552
# define ggt_zsearch_var lv_val *
# define ggo_zsearch_dir1 556
# define ggt_zsearch_dir1 lv_val *
# define ggo_zsearch_dir2 560
# define ggt_zsearch_dir2 lv_val *
# define ggo_fnpca 564
# define ggt_fnpca fnpc_area
# define ggo_for_stack 18372
# define ggt_for_stack oprtype *
# define ggl_for_stack 128
# define ggo_for_temps 18500
# define ggt_for_temps boolean_t
# define ggl_for_temps 128
# define ggo_last_fnquery_return_sub 18628
# define ggt_last_fnquery_return_sub mval
# define ggl_last_fnquery_return_sub 768
# define ggo_lcl_coll_xform_buff 19396
# define ggt_lcl_coll_xform_buff char *
# define ggo_parm_ary 19400
# define ggt_parm_ary char *
# define ggl_parm_ary 20
# define ggo_parm_ary_len 19420
# define ggt_parm_ary_len int
# define ggl_parm_ary_len 20
# define ggo_parm_str_len 19440
# define ggt_parm_str_len int
# define ggl_parm_str_len 20
# define ggo_prombuf 19460
# define ggt_prombuf char
# define ggl_prombuf 32
# define ggo_rt_name_tbl 19492
# define ggt_rt_name_tbl hash_table_mname
# define ggo_tp_restart_failhist_arry 19548
# define ggt_tp_restart_failhist_arry char
# define ggl_tp_restart_failhist_arry 32
# define ggo_callin_hashtab 19580
# define ggt_callin_hashtab hash_table_str *
# define ggo_ci_table 19584
# define ggt_ci_table callin_entry_list *
# define ggo_extcall_package_root 19588
# define ggt_extcall_package_root struct extcall_package_list *
# define ggo_gtmci_nested_level 19592
# define ggt_gtmci_nested_level unsigned int
# define size_gtm_threadgbl_struct 19596
#endif
#endif

1226
pro/obj/merrors_ansi.h Normal file

File diff suppressed because it is too large Load Diff

2447
pro/obj/merrors_ctl.c Normal file

File diff suppressed because it is too large Load Diff

488
pro/obj/omi_sx_play.c Normal file
View File

@ -0,0 +1,488 @@
/****************************************************************
* *
* Copyright 2001, 2010 Fidelity Information Services, Inc *
* *
* This source code contains the intellectual property *
* of its copyright holder(s), and is made available *
* under a license. If you do not know the terms of *
* the license, please stop and do not read further. *
* *
****************************************************************/
/*
* omi_srvc_xct.c ---
*
* Process a client's transaction.
*
*/
#include "mdef.h"
#include <errno.h>
#include "gtm_stdio.h"
#include "gtm_unistd.h"
#include "gtm_string.h"
#include "gtm_time.h" /* for time() */
#include "omi.h"
#include "gtcm.h"
#include "error.h"
#ifndef lint
static char rcsid[] = "$Header:$";
#endif
GBLREF int4 omi_errno;
GBLREF char *omi_pklog;
GBLREF char *omi_oprlist[];
GBLREF char *omi_errlist[];
GBLREF char *omi_pklog_addr;
GBLREF int history;
GBLREF boolean_t servtime_expired;
static omi_op omi_dispatch_table[OMI_OP_MAX] =
{
0,
omi_prc_conn,
omi_prc_stat,
omi_prc_disc,
0, 0, 0, 0, 0, 0,
omi_prc_set,
/* omi_prc_setp*/0,
/* omi_prc_sete*/0,
omi_prc_kill,
/* omi_prc_incr*/0,
0, 0, 0, 0, 0,
omi_prc_get,
omi_prc_def,
omi_prc_ordr,
omi_prc_next,
omi_prc_qry,
omi_prc_rord,
/* omi_prc_rqry*/0,
0, 0, 0,
omi_prc_lock,
omi_prc_unlk,
omi_prc_unlc,
omi_prc_unla
};
int omi_srvc_xact (omi_conn *cptr)
{
extern int4 omi_nxact, omi_nerrs, omi_brecv, omi_bsent, gtcm_stime;
extern int4 gtcm_ltime, omi_nxact2;
omi_vi mlen, xlen;
omi_li nxact;
omi_si hlen;
omi_req_hdr rh;
omi_err_hdr eh;
int4 rv, blen;
int bunches, xblk, i, fatal;
char buff[OMI_BUFSIZ], *bptr, *xend, *bend;
#ifdef BSD_TCP
int cc, save_errno;
/* If true, an error occurred */
cc =(int)(&cptr->buff[cptr->bsiz] - &cptr->bptr[cptr->blen]);
while (!servtime_expired && (cc = (int)(read(cptr->fd, &cptr->bptr[cptr->blen], cc))) < 0 && errno == EINTR)
;
save_errno = errno;
if (servtime_expired)
return -1;
if (cc < 0)
{
if (errno == ETIMEDOUT)
{
OMI_DBG((omi_debug, "%s: connection %d to %s timed out.\n",
SRVR_NAME, cptr->stats.id, gtcm_hname(&cptr->stats.sin)));
}
else if (errno == ECONNRESET)
{
OMI_DBG((omi_debug, "%s: connection %d to %s closed by remote client.\n",
SRVR_NAME, cptr->stats.id, gtcm_hname(&cptr->stats.sin)));
}
else
{
char msg[256];
SPRINTF(msg, "Attempted read from connection %d to %s failed",
cptr->stats.id, gtcm_hname(&cptr->stats.sin));
gtcm_rep_err(msg, save_errno);
}
return -1;
}
/* If true, the connection has closed */
else if (cc == 0)
{
return -1;
}
/* Buffer in use between &cptr->bptr[0] and &cptr->buff[cptr->bsiz] */
cptr->blen += cc;
cptr->stats.bytes_recv += cc;
omi_brecv += cc;
#else /* defined(BSD_TCP) */
#ifdef FILE_TCP
int cc;
cc = (int)(&cptr->buff[cptr->bsiz] - &cptr->bptr[cptr->blen]);
/* If true, an error occurred */
if ((cc = (int)read(cptr->fd, &cptr->bptr[cptr->blen], 4)) <= 0)
{
return -1;
}
cptr->blen += 4;
cptr->xptr = cptr->bptr;
OMI_VI_READ(&mlen, cptr->xptr);
if ((cc = (int)read(cptr->fd, &cptr->bptr[cptr->blen], mlen.value)) <= 0)
{
return -1;
}
cptr->blen += cc;
cptr->stats.bytes_recv += cc + 4;
omi_brecv += cc + 4;
#else /* defined(FILE_TCP) */
return -1;
#endif /* !defined(FILE_TCP) */
#endif /* !defined(BSD_TCP) */
/* If true, we don't have all of the transaction length yet */
if (cptr->blen < OMI_VI_SIZ)
{
/* If true, push the piece we have to the beginning of the buffer */
if (cptr->bptr != cptr->buff)
{
memmove(cptr->buff, cptr->bptr, cptr->blen);
cptr->bptr = cptr->buff;
}
return 0;
}
/* Place the transaction pointer so we can move through the data */
cptr->xptr = cptr->bptr;
OMI_VI_READ(&mlen, cptr->xptr);
if (mlen.value + 4 > OMI_BUFSIZ)
{
char msg[256];
SPRINTF(msg, "OMI packet length (%d) larger than max (%d)", mlen.value+4, OMI_BUFSIZ);
gtcm_cpktdmp((char *)cptr->bptr, cptr->blen, msg);
return -1;
}
/* If true, we don't have the full transaction yet */
if (cptr->blen < mlen.value + 4)
{
/* If true, push the piece we have to the beginning of the buffer */
if (cptr->bptr != cptr->buff)
{
memmove(cptr->buff, cptr->bptr, cptr->blen);
cptr->bptr = cptr->buff;
}
return 0;
}
/* We have the whole transaction in the buffer, decompose it. */
if (history)
{
init_omi_hist(cptr->stats.id);
save_omi_req(cptr->bptr, cptr->blen);
}
#ifdef DEBUG
/*
* if (omi_pklog && !INV_FD_P(cptr->pklog))
* if (!omi_pklog_addr || (!strcmp(omi_pklog_addr, strchr(cptr->stats.addr, '@')+1)))
* omi_dump_pkt(cptr);
*/
#endif /* defined(DEBUG) */
/* This is set to indicate a fatal error in a bunch */
fatal = 0;
/* This is set to indicate we processed an xblk */
xblk = 0;
/* If true, we need to worry about bunches */
if ((bunches = (cptr->exts & OMI_XTF_BUNCH)))
{
OMI_LI_READ(&nxact, cptr->xptr);
bptr = buff + OMI_VI_SIZ + OMI_LI_SIZ;
if (nxact.value * (OMI_RH_SIZ + 1) > mlen.value) /* || nxact.value < 0 */ /* is commented as it is always FALSE */
{
char msg[256];
SPRINTF(msg, "invalid OMI packet (invalid nxact)");
gtcm_cpktdmp((char *)cptr->bptr, cptr->blen, msg);
return -1;
}
}
else
{
nxact.value = 1;
bptr = buff;
xlen = mlen;
}
/* This is the end of the response buffer (for the *_prc_*() routines) */
bend = ARRAYTOP(buff);
/* Loop through the transaction(s) */
for (i = nxact.value; i > 0; i--)
{
if (bunches)
OMI_VI_READ(&xlen, cptr->xptr);
/* This pointer marks the end of this transaction */
xend = cptr->xptr + xlen.value;
/* Check the size of the operation-independent header */
OMI_SI_READ(&hlen, cptr->xptr);
/* Operation class and type */
OMI_LI_READ(&rh.op_class, cptr->xptr);
OMI_SI_READ(&rh.op_type, cptr->xptr);
/* User and Group */
OMI_LI_READ(&rh.user, cptr->xptr);
OMI_LI_READ(&rh.group, cptr->xptr);
/* Sequence number */
OMI_LI_READ(&rh.seq, cptr->xptr);
/* Reference ID */
OMI_LI_READ(&rh.ref, cptr->xptr);
/* Initialize in case of an error */
eh.type = 0;
/* Sanity check the transaction */
if (xlen.value > mlen.value || hlen.value != OMI_RH_SIZ)
{
eh.type = OMI_ER_PR_INVMSGFMT;
fatal = -1;
}
else if (cptr->state == OMI_ST_DISC && rh.op_type.value != OMI_CONNECT)
{
char msg[256];
SPRINTF(msg, "Request (%x) sent before session was established",
rh.op_type.value);
eh.type = OMI_ER_SE_NOSESS;
}
else if (cptr->state == OMI_ST_CONN && rh.op_type.value == OMI_CONNECT)
{
eh.type = OMI_ER_SE_CONNREQ;
fatal = 1;
}
else if (rh.op_class.value != 1)
{
if (!(cptr->exts & OMI_XTF_RC && rh.op_class.value == 2))
{
eh.type = OMI_ER_PR_INVMSGFMT;
fatal = -1;
}
}
else if (rh.op_type.value >= OMI_OP_MAX)
{
cptr->stats.xact[0]++;
eh.type = OMI_ER_PR_INVOPTYPE;
}
else if (!omi_dispatch_table[rh.op_type.value])
{
cptr->stats.xact[rh.op_type.value]++;
eh.type = OMI_ER_PR_INVOPTYPE;
}
/* Report any errors */
if (eh.type != OMI_ER_NO_ERROR || fatal)
{
if (eh.type == OMI_ER_NO_ERROR)
eh.type = OMI_ER_PR_INVMSGFMT;
eh.class = 1;
eh.modifier = 0;
omi_buff_rsp(&rh, &eh, 0, bptr, 0);
bptr += OMI_HDR_SIZ;
cptr->xptr = xend;
cptr->stats.errs[eh.type]++;
omi_nerrs++;
OMI_DBG((omi_debug, "gtcm_server: %6d: Error (PD): %s\n",
cptr->stats.id, omi_errlist[eh.type]));
if (fatal < 0)
break;
continue;
}
/* start counting server up time with the first transaction */
if (!omi_nxact)
gtcm_stime = (int4)time(0);
/* If true, this is an RC request; service it in the RC code */
if (cptr->exts & OMI_XTF_RC && rh.op_class.value == 2)
{
#ifdef GTCM_RC
omi_nxact++;
omi_nxact2++;
if ((rv = rc_srvc_xact(cptr, xend)) >= 0)
{
xblk = 1;
blen = rv + OMI_HDR_SIZ;
bptr = cptr->bptr;
bend = &cptr->buff[cptr->bsiz];
}
#else /* defined(RC) */
fatal = 1;
rv = -OMI_ER_PR_INVMSGFMT;
#endif /* !defined(GTCM_RC) */
}
/* Otherwise, deal with the OMI/EMI request */
else
{
/* Update the stats, do the operation */
cptr->stats.xact[rh.op_type.value]++;
omi_nxact++;
omi_nxact2++;
/* OMI_DBG((omi_debug, "gtcm_server: %6d: %s\n", cptr->stats.id,
* omi_oprlist[rh.op_type.value]));*/
omi_errno = OMI_ER_NO_ERROR;
/* Service the transaction(s) */
rv = (*omi_dispatch_table[rh.op_type.value])(cptr, xend, bptr + OMI_HDR_SIZ, bend);
/* If true (or true if) an exception is raised */
if (omi_errno != OMI_ER_NO_ERROR)
rv = -omi_errno;
}
/* If true, an error occurred servicing this transaction */
if (rv < 0)
{
eh.class = 1;
eh.type = -rv;
eh.modifier = 0;
omi_buff_rsp(&rh, &eh, 0, bptr, 0);
bptr += OMI_HDR_SIZ;
cptr->xptr = xend;
cptr->stats.errs[eh.type]++;
omi_nerrs++;
OMI_DBG((omi_debug, "gtcm_server: %6d: Error (AD): %s\n",
cptr->stats.id, omi_errlist[eh.type]));
omi_dump_pkt(cptr);
}
else
{
if (cptr->xptr != xend)
{
/* Only report this if we're not doing RC */
if (!(cptr->exts & OMI_XTF_RC && rh.op_class.value == 2))
NON_IA64_ONLY(OMI_DBG((omi_debug, "gtcm_server: xptr != xend (%d)\n", xend - cptr->xptr)));
IA64_ONLY(OMI_DBG((omi_debug, "gtcm_server: xptr != xend (%ld)\n", xend - cptr->xptr)));
cptr->xptr = xend;
}
omi_buff_rsp(&rh, (omi_err_hdr *)0, 0, bptr, rv);
bptr += OMI_HDR_SIZ + rv;
}
if (bptr >= bend)
{
gtcm_rep_err("Buffer overrun error", -1);
return -1;
}
}
/* If true, this was not an RC XBLK, so we need to calculate the
* size of the response */
if (!xblk)
{
blen = (int)(bptr - buff);
bptr = buff;
if (bunches)
{
OMI_VI_WRIT(blen - OMI_VI_SIZ, bptr);
OMI_LI_WRIT(nxact.value, bptr);
bptr = buff;
}
}
else
bptr = cptr->bptr;
/* Send the response(s) back to the client */
if (history)
save_omi_rsp(bptr, blen);
#ifdef BSD_TCP
/* Write out the response (in pieces if necessary) */
while (blen > 0)
{
while(!servtime_expired && (cc = (int)(write(cptr->fd, bptr, blen))) < 0)
;
save_errno = errno;
if (cc < 0)
{
if (errno == ETIMEDOUT)
{
OMI_DBG((omi_debug, "%s: connection %d to %s timed out.\n",
SRVR_NAME, cptr->stats.id, gtcm_hname(&cptr->stats.sin)));
}
else if (errno == ECONNRESET)
{
OMI_DBG((omi_debug, "%s: connection %d to %s closed by remote client.\n",
SRVR_NAME, cptr->stats.id, gtcm_hname(&cptr->stats.sin)));
}
else if (errno == EPIPE)
{
OMI_DBG((omi_debug, "%s: remote client no longer attached to connection %d, %s.\n",
SRVR_NAME, cptr->stats.id, gtcm_hname(&cptr->stats.sin)));
}
else if (errno == EINTR)
continue;
else
{
char msg[256];
SPRINTF(msg, "Write attempt to connection %d failed", cptr->stats.id);
gtcm_rep_err(msg, save_errno);
}
return -1;
}
bptr += cc;
blen -= cc;
cptr->stats.bytes_send += cc;
omi_bsent += cc;
}
#else /* defined(BSD_TCP) */
#ifdef FILE_TCP
bptr += blen;
cptr->stats.bytes_send += blen;
omi_bsent += blen;
blen -= blen;
#endif /* defined(FILE_TCP) */
#endif /* !defined(BSD_TCP) */
/* If true, a fatal error occurred with the last transaction */
/* also exitt if we received a disconnect request */
if (fatal || rh.op_type.value == OMI_DISCONNECT)
{
return -1;
}
/* Get ready for the next transaction */
cptr->bptr += mlen.value + 4;
cptr->blen -= mlen.value + 4;
if (cptr->xptr > cptr->bptr)
{
gtcm_rep_err("buffer size error", errno);
return -1;
}
/* If true, move the partial buffer to the beginning of the buffer */
if (cptr->blen > 0 && cptr->bptr != cptr->buff)
memmove(cptr->buff, cptr->bptr, cptr->blen);
/* Reset to the beginning of the buffer */
cptr->bptr = cptr->buff;
return 0;
}

664
pro/obj/ttt.c Normal file
View File

@ -0,0 +1,664 @@
/****************************************************************
* *
* Copyright 2001, 2012 Fidelity Information Services, Inc *
* *
* This source code contains the intellectual property *
* of its copyright holder(s), and is made available *
* under a license. If you do not know the terms of *
* the license, please stop and do not read further. *
* *
****************************************************************/
#include "mdef.h"
#include "vxi.h"
#include "vxt.h"
#include "xfer_enum.h"
LITDEF short ttt[4058] = {
/* 0 */ 0,0,0,0,307,3391,2834,531,
/* 8 */ 2203,2819,2849,1893,385,3341,2005,2965,
/* 16 */ 2082,2073,3574,3611,2046,2055,2121,2067,
/* 24 */ 2112,2091,2028,731,758,746,785,797,
/* 32 */ 809,827,869,887,905,920,949,985,
/* 40 */ 1000,1015,1030,1048,1060,2935,2950,1132,
/* 48 */ 1165,1198,1237,1300,1351,1627,1642,1657,
/* 56 */ 1687,1726,1738,1762,1789,1810,1825,3406,
/* 64 */ 3428,0,0,0,0,546,0,487,
/* 72 */ 0,1879,0,2921,0,0,0,0,
/* 80 */ 0,0,339,397,2181,2187,2611,2638,
/* 88 */ 2656,2759,2697,2688,2774,3480,3564,2870,
/* 96 */ 0,2900,3031,2994,2979,3009,3355,3207,
/* 104 */ 3273,3486,3498,3513,3537,3546,3531,3522,
/* 112 */ 3306,3607,3620,3642,3679,3691,3712,3736,
/* 120 */ 3802,0,0,2807,2163,3083,4007,619,
/* 128 */ 4010,673,2668,3049,501,507,4013,2279,
/* 136 */ 2361,2253,454,2302,2381,2037,2324,2391,
/* 144 */ 4016,2148,2139,4020,1369,1387,4021,335,
/* 152 */ 331,3297,409,4025,4028,4031,2886,4034,
/* 160 */ 4037,4040,4043,4046,4049,3377,0,2783,
/* 168 */ 2451,2428,1606,2419,2199,2019,2734,1914,
/* 176 */ 698,2724,0,0,2218,3555,3583,1582,
/* 184 */ 3507,2314,1907,516,3703,1774,2130,1285,
/* 192 */ 2435,322,3035,585,651,569,629,3667,
/* 200 */ 1180,1219,3635,2863,2157,2798,2877,601,
/* 208 */ 1072,2738,4052,2371,3754,3772,3787,478,
/* 216 */ 2753,3027,1852,3823,3814,1423,3369,560,
/* 224 */ 1672,1714,2336,4055,3440,2407,707,845,
/* 232 */ 3066,3595,3464,3450,3457,3446,683,934,
/* 240 */ 2266,2289,1114,2240,1102,2100,1087,1147,
/* 248 */ 2348,1552,1495,1480,1534,1450,1462,1507,
/* 256 */ 1435,1519,1567,0,3327,0,961,970,
/* 264 */ 3186,3252,1801,3165,3231,2227,3859,3829,
/* 272 */ 3835,3847,3869,1324,1336,1258,1270,1312,
/* 280 */ 3418,1702,1837,3883,3898,3934,3916,3093,
/* 288 */ 3105,3117,3129,2647,2662,1594,418,773,
/* 296 */ 1405,610,3141,3153,3946,3952,3961,3978,
/* 304 */ 3992,3998,3658,VXI_PUSHAB,VXT_VAL,0,VXI_PUSHAB,VXT_VAL,
/* 312 */ 2,VXI_PUSHAB,VXT_VAL,1,VXI_CALLS,VXT_LIT,3,VXT_XFER,
/* 320 */ SIZEOF(char *) * (short int)xf_add,VXT_END,
/* 322 */ VXT_IREPL,VXT_VAL,2,VXI_CALLS,VXT_VAL,1,VXT_XFER,SIZEOF(char *) * (short int)xf_bindparm,
/* 330 */ VXT_END,
/* 331 */ VXI_INCL,VXT_VAL,1,VXT_END,
/* 335 */ VXI_CLRL,VXT_VAL,0,VXT_END,
/* 339 */ VXI_JSB,VXT_XFER,SIZEOF(char *) * (short int)xf_break,VXT_END,
/* 343 */ VXI_JSB,VXT_XFER,SIZEOF(char *) * (short int)xf_callb,VXI_BRB,VXT_JMP,1,VXT_END,
/* 350 */ VXI_JSB,VXT_XFER,SIZEOF(char *) * (short int)xf_calll,VXI_JMP,VXT_JMP,1,VXT_END,
/* 357 */ VXI_JSB,VXT_XFER,SIZEOF(char *) * (short int)xf_callw,VXI_BRW,VXT_JMP,1,VXT_END,
/* 364 */ VXI_JSB,VXT_XFER,SIZEOF(char *) * (short int)xf_callspb,VXI_BRB,VXT_JMP,1,VXT_END,
/* 371 */ VXI_JSB,VXT_XFER,SIZEOF(char *) * (short int)xf_callspl,VXI_JMP,VXT_JMP,1,VXT_END,
/* 378 */ VXI_JSB,VXT_XFER,SIZEOF(char *) * (short int)xf_callspw,VXI_BRW,VXT_JMP,1,VXT_END,
/* 385 */ VXT_IREPAB,VXT_VAL,2,VXI_PUSHAB,VXT_VAL,0,VXI_CALLS,VXT_VAL,
/* 393 */ 1,VXT_XFER,SIZEOF(char *) * (short int)xf_cat,VXT_END,
/* 397 */ VXI_PUSHAB,VXT_VAL,2,VXI_PUSHAB,VXT_VAL,1,VXI_CALLS,VXT_LIT,
/* 405 */ 2,VXT_XFER,SIZEOF(char *) * (short int)xf_close,VXT_END,
/* 409 */ VXI_BICB2,VXT_LIT,1,VXT_REG,0x5A,VXI_JSB,VXT_XFER,SIZEOF(char *) * (short int)xf_dt_false,
/* 417 */ VXT_END,
/* 418 */ VXI_PUSHAB,VXT_VAL,1,VXI_CALLS,VXT_LIT,1,VXT_XFER,SIZEOF(char *) * (short int)xf_clralsvars,
/* 426 */ VXT_END,
/* 427 */ VXI_TSTL,VXT_VAL,1,VXT_END,
/* 431 */ VXI_MOVAB,VXT_VAL,1,VXT_REG,0x51,VXI_JSB,VXT_XFER,SIZEOF(char *) * (short int)xf_mval2bool,
/* 439 */ VXT_END,
/* 440 */ VXI_MOVAB,VXT_VAL,1,VXT_REG,0x51,VXI_JSB,VXT_XFER,SIZEOF(char *) * (short int)xf_mval2mint,
/* 448 */ VXI_MOVL,VXT_REG,0x50,VXT_VAL,0,VXT_END,
/* 454 */ VXI_PUSHL,VXT_VAL,2,VXI_PUSHAB,VXT_VAL,1,VXI_JSB,VXT_XFER,
/* 462 */ SIZEOF(char *) * (short int)xf_commarg,VXT_END,
/* 464 */ VXI_MOVAB,VXT_VAL,0,VXT_REG,0x50,VXI_MOVL,VXT_VAL,1,
/* 472 */ VXT_REG,0x51,VXI_JSB,VXT_XFER,SIZEOF(char *) * (short int)xf_mint2mval,VXT_END,
/* 478 */ VXI_MOVAB,VXT_VAL,1,VXT_REG,0x51,VXI_JSB,VXT_XFER,SIZEOF(char *) * (short int)xf_mval2num,
/* 486 */ VXT_END,
/* 487 */ VXI_MOVAB,VXT_VAL,1,VXT_REG,0x50,VXI_MOVAB,VXT_VAL,2,
/* 495 */ VXT_REG,0x51,VXI_JSB,VXT_XFER,SIZEOF(char *) * (short int)xf_contain,VXT_END,
/* 501 */ VXI_MOVL,VXT_REG,0x6C,VXT_ADDR,0,VXT_END,
/* 507 */ VXI_MOVAB,VXT_VAL,0,VXT_REG,0x51,VXI_JSB,VXT_XFER,SIZEOF(char *) * (short int)xf_currtn,
/* 515 */ VXT_END,
/* 516 */ VXI_PUSHAB,VXT_VAL,0,VXI_PUSHAB,VXT_VAL,2,VXI_PUSHL,VXT_VAL,
/* 524 */ 1,VXI_CALLS,VXT_LIT,3,VXT_XFER,SIZEOF(char *) * (short int)xf_cvtparm,VXT_END,
/* 531 */ VXI_PUSHAB,VXT_VAL,0,VXI_PUSHAB,VXT_VAL,2,VXI_PUSHAB,VXT_VAL,
/* 539 */ 1,VXI_CALLS,VXT_LIT,3,VXT_XFER,SIZEOF(char *) * (short int)xf_div,VXT_END,
/* 546 */ VXI_MOVAB,VXT_VAL,2,VXT_REG,0x51,VXI_MOVAB,VXT_VAL,1,
/* 554 */ VXT_REG,0x50,VXI_JSB,VXT_XFER,SIZEOF(char *) * (short int)xf_equ,VXT_END,
/* 560 */ VXI_MOVAB,VXT_VAL,1,VXT_REG,0x50,VXI_JSB,VXT_XFER,SIZEOF(char *) * (short int)xf_equnul,
/* 568 */ VXT_END,
/* 569 */ VXT_IREPAB,VXT_VAL,4,VXI_PUSHL,VXT_VAL,3,VXI_PUSHL,VXT_VAL,
/* 577 */ 2,VXI_PUSHL,VXT_LIT,0,VXI_JSB,VXT_XFER,SIZEOF(char *) * (short int)xf_exfun,VXT_END,
/* 585 */ VXT_IREPAB,VXT_VAL,4,VXI_PUSHL,VXT_VAL,3,VXI_PUSHL,VXT_VAL,
/* 593 */ 2,VXI_PUSHAB,VXT_VAL,0,VXI_JSB,VXT_XFER,SIZEOF(char *) * (short int)xf_exfun,VXT_END,
/* 601 */ VXI_PUSHAB,VXT_VAL,1,VXI_CALLS,VXT_LIT,1,VXT_XFER,SIZEOF(char *) * (short int)xf_exfunret,
/* 609 */ VXT_END,
/* 610 */ VXI_PUSHAB,VXT_VAL,1,VXI_CALLS,VXT_LIT,1,VXT_XFER,SIZEOF(char *) * (short int)xf_exfunretals,
/* 618 */ VXT_END,
/* 619 */ VXI_PUSHAB,VXT_VAL,2,VXI_PUSHAB,VXT_VAL,1,VXI_JSB,VXT_XFER,
/* 627 */ SIZEOF(char *) * (short int)xf_extcall,VXT_END,
/* 629 */ VXT_IREPAB,VXT_VAL,5,VXI_PUSHL,VXT_VAL,4,VXI_PUSHL,VXT_VAL,
/* 637 */ 3,VXI_PUSHL,VXT_LIT,0,VXI_PUSHAB,VXT_VAL,2,VXI_PUSHAB,
/* 645 */ VXT_VAL,1,VXI_JSB,VXT_XFER,SIZEOF(char *) * (short int)xf_extexfun,VXT_END,
/* 651 */ VXT_IREPAB,VXT_VAL,5,VXI_PUSHL,VXT_VAL,4,VXI_PUSHL,VXT_VAL,
/* 659 */ 3,VXI_PUSHAB,VXT_VAL,0,VXI_PUSHAB,VXT_VAL,2,VXI_PUSHAB,
/* 667 */ VXT_VAL,1,VXI_JSB,VXT_XFER,SIZEOF(char *) * (short int)xf_extexfun,VXT_END,
/* 673 */ VXI_PUSHAB,VXT_VAL,2,VXI_PUSHAB,VXT_VAL,1,VXI_JSB,VXT_XFER,
/* 681 */ SIZEOF(char *) * (short int)xf_extjmp,VXT_END,
/* 683 */ VXI_PUSHAB,VXT_VAL,0,VXI_PUSHAB,VXT_VAL,2,VXI_PUSHAB,VXT_VAL,
/* 691 */ 1,VXI_CALLS,VXT_LIT,3,VXT_XFER,SIZEOF(char *) * (short int)xf_exp,VXT_END,
/* 698 */ VXT_IREPL,VXT_VAL,2,VXI_CALLS,VXT_VAL,1,VXT_XFER,SIZEOF(char *) * (short int)xf_fetch,
/* 706 */ VXT_END,
/* 707 */ VXT_IREPAB,VXT_VAL,6,VXI_PUSHL,VXT_VAL,5,VXI_PUSHL,VXT_VAL,
/* 715 */ 4,VXI_PUSHAB,VXT_VAL,3,VXI_PUSHAB,VXT_VAL,2,VXI_PUSHL,
/* 723 */ VXT_LIT,0,VXI_CALLS,VXT_VAL,1,VXT_XFER,SIZEOF(char *) * (short int)xf_fnfgncal,VXT_END,
/* 731 */ VXI_PUSHAB,VXT_VAL,0,VXI_PUSHAB,VXT_VAL,1,VXI_PUSHL,VXT_VAL,
/* 739 */ 2,VXI_CALLS,VXT_LIT,3,VXT_XFER,SIZEOF(char *) * (short int)xf_fnascii,VXT_END,
/* 746 */ VXT_IREPL,VXT_VAL,2,VXI_PUSHAB,VXT_VAL,0,VXI_CALLS,VXT_VAL,
/* 754 */ 1,VXT_XFER,SIZEOF(char *) * (short int)xf_fnchar,VXT_END,
/* 758 */ VXI_PUSHAB,VXT_VAL,0,VXI_PUSHAB,VXT_VAL,1,VXI_PUSHL,VXT_VAL,
/* 766 */ 2,VXI_CALLS,VXT_LIT,3,VXT_XFER,SIZEOF(char *) * (short int)xf_fnzascii,VXT_END,
/* 773 */ VXI_PUSHAB,VXT_VAL,0,VXI_PUSHAB,VXT_VAL,1,VXI_CALLS,VXT_LIT,
/* 781 */ 2,VXT_XFER,SIZEOF(char *) * (short int)xf_fnzahandle,VXT_END,
/* 785 */ VXT_IREPL,VXT_VAL,2,VXI_PUSHAB,VXT_VAL,0,VXI_CALLS,VXT_VAL,
/* 793 */ 1,VXT_XFER,SIZEOF(char *) * (short int)xf_fnzchar,VXT_END,
/* 797 */ VXI_PUSHAB,VXT_VAL,0,VXI_PUSHAB,VXT_VAL,1,VXI_CALLS,VXT_LIT,
/* 805 */ 2,VXT_XFER,SIZEOF(char *) * (short int)xf_fndata,VXT_END,
/* 809 */ VXI_PUSHAB,VXT_VAL,0,VXI_PUSHAB,VXT_VAL,1,VXI_PUSHL,VXT_VAL,
/* 817 */ 2,VXI_PUSHL,VXT_VAL,3,VXI_CALLS,VXT_LIT,4,VXT_XFER,
/* 825 */ SIZEOF(char *) * (short int)xf_fnextract,VXT_END,
/* 827 */ VXI_PUSHAB,VXT_VAL,0,VXI_PUSHAB,VXT_VAL,1,VXI_PUSHL,VXT_VAL,
/* 835 */ 2,VXI_PUSHL,VXT_VAL,3,VXI_CALLS,VXT_LIT,4,VXT_XFER,
/* 843 */ SIZEOF(char *) * (short int)xf_fnzextract,VXT_END,
/* 845 */ VXT_IREPAB,VXT_VAL,6,VXI_PUSHL,VXT_VAL,5,VXI_PUSHL,VXT_VAL,
/* 853 */ 4,VXI_PUSHAB,VXT_VAL,3,VXI_PUSHAB,VXT_VAL,2,VXI_PUSHAB,
/* 861 */ VXT_VAL,0,VXI_CALLS,VXT_VAL,1,VXT_XFER,SIZEOF(char *) * (short int)xf_fnfgncal,VXT_END,
/* 869 */ VXI_PUSHAB,VXT_VAL,0,VXI_PUSHL,VXT_VAL,3,VXI_PUSHAB,VXT_VAL,
/* 877 */ 2,VXI_PUSHAB,VXT_VAL,1,VXI_CALLS,VXT_LIT,4,VXT_XFER,
/* 885 */ SIZEOF(char *) * (short int)xf_fnfind,VXT_END,
/* 887 */ VXI_PUSHAB,VXT_VAL,0,VXI_PUSHL,VXT_VAL,3,VXI_PUSHAB,VXT_VAL,
/* 895 */ 2,VXI_PUSHAB,VXT_VAL,1,VXI_CALLS,VXT_LIT,4,VXT_XFER,
/* 903 */ SIZEOF(char *) * (short int)xf_fnzfind,VXT_END,
/* 905 */ VXI_PUSHAB,VXT_VAL,0,VXI_PUSHAB,VXT_VAL,2,VXI_PUSHAB,VXT_VAL,
/* 913 */ 1,VXI_CALLS,VXT_LIT,3,VXT_XFER,SIZEOF(char *) * (short int)xf_fnfnumber,VXT_END,
/* 920 */ VXI_MOVAB,VXT_VAL,1,VXT_REG,0x51,VXI_MOVAB,VXT_VAL,0,
/* 928 */ VXT_REG,0x50,VXI_JSB,VXT_XFER,SIZEOF(char *) * (short int)xf_fnget,VXT_END,
/* 934 */ VXI_PUSHAB,VXT_VAL,2,VXI_PUSHAB,VXT_VAL,1,VXI_PUSHAB,VXT_VAL,
/* 942 */ 0,VXI_CALLS,VXT_LIT,3,VXT_XFER,SIZEOF(char *) * (short int)xf_fnget2,VXT_END,
/* 949 */ VXI_PUSHAB,VXT_VAL,1,VXI_PUSHAB,VXT_VAL,0,VXI_CALLS,VXT_LIT,
/* 957 */ 2,VXT_XFER,SIZEOF(char *) * (short int)xf_fngvget,VXT_END,
/* 961 */ VXI_PUSHAB,VXT_VAL,0,VXI_CALLS,VXT_LIT,1,VXT_XFER,SIZEOF(char *) * (short int)xf_fngvget1,
/* 969 */ VXT_END,
/* 970 */ VXI_PUSHAB,VXT_VAL,2,VXI_PUSHAB,VXT_VAL,1,VXI_PUSHAB,VXT_VAL,
/* 978 */ 0,VXI_CALLS,VXT_LIT,3,VXT_XFER,SIZEOF(char *) * (short int)xf_fngvget2,VXT_END,
/* 985 */ VXI_PUSHAB,VXT_VAL,0,VXI_PUSHAB,VXT_VAL,2,VXI_PUSHAB,VXT_VAL,
/* 993 */ 1,VXI_CALLS,VXT_LIT,3,VXT_XFER,SIZEOF(char *) * (short int)xf_fnincr,VXT_END,
/* 1000 */ VXI_PUSHAB,VXT_VAL,0,VXI_PUSHL,VXT_VAL,2,VXI_PUSHAB,VXT_VAL,
/* 1008 */ 1,VXI_CALLS,VXT_LIT,3,VXT_XFER,SIZEOF(char *) * (short int)xf_fnj2,VXT_END,
/* 1015 */ VXI_PUSHAB,VXT_VAL,0,VXI_PUSHL,VXT_VAL,2,VXI_PUSHAB,VXT_VAL,
/* 1023 */ 1,VXI_CALLS,VXT_LIT,3,VXT_XFER,SIZEOF(char *) * (short int)xf_fnzj2,VXT_END,
/* 1030 */ VXI_PUSHAB,VXT_VAL,0,VXI_PUSHL,VXT_VAL,3,VXI_PUSHL,VXT_VAL,
/* 1038 */ 2,VXI_PUSHAB,VXT_VAL,1,VXI_CALLS,VXT_LIT,4,VXT_XFER,
/* 1046 */ SIZEOF(char *) * (short int)xf_fnj3,VXT_END,
/* 1048 */ VXI_PUSHAB,VXT_VAL,0,VXI_PUSHAB,VXT_VAL,1,VXI_CALLS,VXT_LIT,
/* 1056 */ 2,VXT_XFER,SIZEOF(char *) * (short int)xf_fnlength,VXT_END,
/* 1060 */ VXI_PUSHAB,VXT_VAL,0,VXI_PUSHAB,VXT_VAL,1,VXI_CALLS,VXT_LIT,
/* 1068 */ 2,VXT_XFER,SIZEOF(char *) * (short int)xf_fnzlength,VXT_END,
/* 1072 */ VXI_PUSHAB,VXT_VAL,0,VXI_PUSHL,VXT_VAL,2,VXI_PUSHAB,VXT_VAL,
/* 1080 */ 1,VXI_CALLS,VXT_LIT,3,VXT_XFER,SIZEOF(char *) * (short int)xf_fnlvname,VXT_END,
/* 1087 */ VXI_PUSHAB,VXT_VAL,2,VXI_PUSHAB,VXT_VAL,0,VXI_PUSHAB,VXT_VAL,
/* 1095 */ 1,VXI_CALLS,VXT_LIT,3,VXT_XFER,SIZEOF(char *) * (short int)xf_fnlvnameo2,VXT_END,
/* 1102 */ VXI_PUSHAB,VXT_VAL,0,VXI_PUSHAB,VXT_VAL,1,VXI_CALLS,VXT_LIT,
/* 1110 */ 2,VXT_XFER,SIZEOF(char *) * (short int)xf_fnlvprvname,VXT_END,
/* 1114 */ VXT_IREPAB,VXT_VAL,4,VXI_PUSHAB,VXT_VAL,1,VXI_PUSHL,VXT_VAL,
/* 1122 */ 3,VXI_PUSHAB,VXT_VAL,0,VXI_CALLS,VXT_VAL,2,VXT_XFER,
/* 1130 */ SIZEOF(char *) * (short int)xf_fnname,VXT_END,
/* 1132 */ VXI_PUSHAB,VXT_VAL,0,VXI_PUSHAB,VXT_VAL,2,VXI_PUSHAB,VXT_VAL,
/* 1140 */ 1,VXI_CALLS,VXT_LIT,3,VXT_XFER,SIZEOF(char *) * (short int)xf_fnnext,VXT_END,
/* 1147 */ VXI_PUSHAB,VXT_VAL,3,VXI_PUSHAB,VXT_VAL,0,VXI_PUSHAB,VXT_VAL,
/* 1155 */ 2,VXI_PUSHAB,VXT_VAL,1,VXI_CALLS,VXT_LIT,4,VXT_XFER,
/* 1163 */ SIZEOF(char *) * (short int)xf_fno2,VXT_END,
/* 1165 */ VXI_PUSHAB,VXT_VAL,0,VXI_PUSHAB,VXT_VAL,2,VXI_PUSHAB,VXT_VAL,
/* 1173 */ 1,VXI_CALLS,VXT_LIT,3,VXT_XFER,SIZEOF(char *) * (short int)xf_fnorder,VXT_END,
/* 1180 */ VXI_PUSHAB,VXT_VAL,0,VXI_PUSHL,VXT_VAL,3,VXI_PUSHL,VXT_VAL,
/* 1188 */ 2,VXI_PUSHAB,VXT_VAL,1,VXI_CALLS,VXT_LIT,4,VXT_XFER,
/* 1196 */ SIZEOF(char *) * (short int)xf_fnp1,VXT_END,
/* 1198 */ VXI_PUSHAB,VXT_VAL,0,VXI_PUSHL,VXT_VAL,4,VXI_PUSHL,VXT_VAL,
/* 1206 */ 3,VXI_PUSHAB,VXT_VAL,2,VXI_PUSHAB,VXT_VAL,1,VXI_CALLS,
/* 1214 */ VXT_LIT,5,VXT_XFER,SIZEOF(char *) * (short int)xf_fnpiece,VXT_END,
/* 1219 */ VXI_PUSHAB,VXT_VAL,0,VXI_PUSHL,VXT_VAL,3,VXI_PUSHL,VXT_VAL,
/* 1227 */ 2,VXI_PUSHAB,VXT_VAL,1,VXI_CALLS,VXT_LIT,4,VXT_XFER,
/* 1235 */ SIZEOF(char *) * (short int)xf_fnzp1,VXT_END,
/* 1237 */ VXI_PUSHAB,VXT_VAL,0,VXI_PUSHL,VXT_VAL,4,VXI_PUSHL,VXT_VAL,
/* 1245 */ 3,VXI_PUSHAB,VXT_VAL,2,VXI_PUSHAB,VXT_VAL,1,VXI_CALLS,
/* 1253 */ VXT_LIT,5,VXT_XFER,SIZEOF(char *) * (short int)xf_fnzpiece,VXT_END,
/* 1258 */ VXI_PUSHAB,VXT_VAL,0,VXI_PUSHAB,VXT_VAL,1,VXI_CALLS,VXT_LIT,
/* 1266 */ 2,VXT_XFER,SIZEOF(char *) * (short int)xf_fnqlength,VXT_END,
/* 1270 */ VXI_PUSHAB,VXT_VAL,0,VXI_PUSHL,VXT_VAL,2,VXI_PUSHAB,VXT_VAL,
/* 1278 */ 1,VXI_CALLS,VXT_LIT,3,VXT_XFER,SIZEOF(char *) * (short int)xf_fnqsubscript,VXT_END,
/* 1285 */ VXT_IREPAB,VXT_VAL,3,VXI_PUSHAB,VXT_VAL,2,VXI_PUSHAB,VXT_VAL,
/* 1293 */ 0,VXI_CALLS,VXT_VAL,1,VXT_XFER,SIZEOF(char *) * (short int)xf_fnquery,VXT_END,
/* 1300 */ VXI_PUSHAB,VXT_VAL,0,VXI_PUSHL,VXT_VAL,1,VXI_CALLS,VXT_LIT,
/* 1308 */ 2,VXT_XFER,SIZEOF(char *) * (short int)xf_fnrandom,VXT_END,
/* 1312 */ VXI_PUSHAB,VXT_VAL,0,VXI_PUSHAB,VXT_VAL,1,VXI_CALLS,VXT_LIT,
/* 1320 */ 2,VXT_XFER,SIZEOF(char *) * (short int)xf_fnreverse,VXT_END,
/* 1324 */ VXI_PUSHAB,VXT_VAL,0,VXI_PUSHL,VXT_VAL,1,VXI_CALLS,VXT_LIT,
/* 1332 */ 2,VXT_XFER,SIZEOF(char *) * (short int)xf_fnstack1,VXT_END,
/* 1336 */ VXI_PUSHAB,VXT_VAL,0,VXI_PUSHAB,VXT_VAL,2,VXI_PUSHL,VXT_VAL,
/* 1344 */ 1,VXI_CALLS,VXT_LIT,3,VXT_XFER,SIZEOF(char *) * (short int)xf_fnstack2,VXT_END,
/* 1351 */ VXI_PUSHAB,VXT_VAL,0,VXI_PUSHAB,VXT_VAL,3,VXI_PUSHL,VXT_VAL,
/* 1359 */ 2,VXI_PUSHAB,VXT_VAL,1,VXI_CALLS,VXT_LIT,4,VXT_XFER,
/* 1367 */ SIZEOF(char *) * (short int)xf_fntext,VXT_END,
/* 1369 */ VXI_PUSHAB,VXT_VAL,0,VXI_PUSHAB,VXT_VAL,3,VXI_PUSHAB,VXT_VAL,
/* 1377 */ 2,VXI_PUSHAB,VXT_VAL,1,VXI_CALLS,VXT_LIT,4,VXT_XFER,
/* 1385 */ SIZEOF(char *) * (short int)xf_fntranslate,VXT_END,
/* 1387 */ VXI_PUSHAB,VXT_VAL,0,VXI_PUSHAB,VXT_VAL,3,VXI_PUSHAB,VXT_VAL,
/* 1395 */ 2,VXI_PUSHAB,VXT_VAL,1,VXI_CALLS,VXT_LIT,4,VXT_XFER,
/* 1403 */ SIZEOF(char *) * (short int)xf_fnztranslate,VXT_END,
/* 1405 */ VXI_PUSHAB,VXT_VAL,0,VXI_PUSHAB,VXT_VAL,3,VXI_PUSHAB,VXT_VAL,
/* 1413 */ 2,VXI_PUSHAB,VXT_VAL,1,VXI_CALLS,VXT_LIT,4,VXT_XFER,
/* 1421 */ SIZEOF(char *) * (short int)xf_fnztrigger,VXT_END,
/* 1423 */ VXT_IREPAB,VXT_VAL,2,VXI_PUSHAB,VXT_VAL,0,VXI_CALLS,VXT_VAL,
/* 1431 */ 1,VXT_XFER,SIZEOF(char *) * (short int)xf_fnview,VXT_END,
/* 1435 */ VXI_PUSHAB,VXT_VAL,2,VXI_PUSHAB,VXT_VAL,1,VXI_PUSHAB,VXT_VAL,
/* 1443 */ 0,VXI_CALLS,VXT_LIT,3,VXT_XFER,SIZEOF(char *) * (short int)xf_fnzbitand,VXT_END,
/* 1450 */ VXI_PUSHAB,VXT_VAL,1,VXI_PUSHAB,VXT_VAL,0,VXI_CALLS,VXT_LIT,
/* 1458 */ 2,VXT_XFER,SIZEOF(char *) * (short int)xf_fnzbitcoun,VXT_END,
/* 1462 */ VXI_PUSHL,VXT_VAL,3,VXI_PUSHL,VXT_VAL,2,VXI_PUSHAB,VXT_VAL,
/* 1470 */ 1,VXI_PUSHAB,VXT_VAL,0,VXI_CALLS,VXT_LIT,4,VXT_XFER,
/* 1478 */ SIZEOF(char *) * (short int)xf_fnzbitfind,VXT_END,
/* 1480 */ VXI_PUSHL,VXT_VAL,2,VXI_PUSHAB,VXT_VAL,1,VXI_PUSHAB,VXT_VAL,
/* 1488 */ 0,VXI_CALLS,VXT_LIT,3,VXT_XFER,SIZEOF(char *) * (short int)xf_fnzbitget,VXT_END,
/* 1495 */ VXI_PUSHAB,VXT_VAL,1,VXI_PUSHAB,VXT_VAL,0,VXI_CALLS,VXT_LIT,
/* 1503 */ 2,VXT_XFER,SIZEOF(char *) * (short int)xf_fnzbitlen,VXT_END,
/* 1507 */ VXI_PUSHAB,VXT_VAL,1,VXI_PUSHAB,VXT_VAL,0,VXI_CALLS,VXT_LIT,
/* 1515 */ 2,VXT_XFER,SIZEOF(char *) * (short int)xf_fnzbitnot,VXT_END,
/* 1519 */ VXI_PUSHAB,VXT_VAL,2,VXI_PUSHAB,VXT_VAL,1,VXI_PUSHAB,VXT_VAL,
/* 1527 */ 0,VXI_CALLS,VXT_LIT,3,VXT_XFER,SIZEOF(char *) * (short int)xf_fnzbitor,VXT_END,
/* 1534 */ VXI_PUSHL,VXT_VAL,3,VXI_PUSHL,VXT_VAL,2,VXI_PUSHAB,VXT_VAL,
/* 1542 */ 1,VXI_PUSHAB,VXT_VAL,0,VXI_CALLS,VXT_LIT,4,VXT_XFER,
/* 1550 */ SIZEOF(char *) * (short int)xf_fnzbitset,VXT_END,
/* 1552 */ VXI_PUSHL,VXT_VAL,2,VXI_PUSHL,VXT_VAL,1,VXI_PUSHAB,VXT_VAL,
/* 1560 */ 0,VXI_CALLS,VXT_LIT,3,VXT_XFER,SIZEOF(char *) * (short int)xf_fnzbitstr,VXT_END,
/* 1567 */ VXI_PUSHAB,VXT_VAL,2,VXI_PUSHAB,VXT_VAL,1,VXI_PUSHAB,VXT_VAL,
/* 1575 */ 0,VXI_CALLS,VXT_LIT,3,VXT_XFER,SIZEOF(char *) * (short int)xf_fnzbitxor,VXT_END,
/* 1582 */ VXT_IREPAB,VXT_VAL,2,VXI_PUSHAB,VXT_VAL,0,VXI_CALLS,VXT_VAL,
/* 1590 */ 1,VXT_XFER,SIZEOF(char *) * (short int)xf_fnzcall,VXT_END,
/* 1594 */ VXI_PUSHAB,VXT_VAL,0,VXI_PUSHAB,VXT_VAL,1,VXI_CALLS,VXT_LIT,
/* 1602 */ 2,VXT_XFER,SIZEOF(char *) * (short int)xf_fnzdata,VXT_END,
/* 1606 */ VXI_PUSHAB,VXT_VAL,0,VXI_PUSHAB,VXT_VAL,4,VXI_PUSHAB,VXT_VAL,
/* 1614 */ 3,VXI_PUSHAB,VXT_VAL,2,VXI_PUSHAB,VXT_VAL,1,VXI_CALLS,
/* 1622 */ VXT_LIT,5,VXT_XFER,SIZEOF(char *) * (short int)xf_fnzdate,VXT_END,
/* 1627 */ VXI_PUSHAB,VXT_VAL,0,VXI_PUSHAB,VXT_VAL,2,VXI_PUSHAB,VXT_VAL,
/* 1635 */ 1,VXI_CALLS,VXT_LIT,3,VXT_XFER,SIZEOF(char *) * (short int)xf_fnzfile,VXT_END,
/* 1642 */ VXI_PUSHAB,VXT_VAL,0,VXI_PUSHAB,VXT_VAL,2,VXI_PUSHAB,VXT_VAL,
/* 1650 */ 1,VXI_CALLS,VXT_LIT,3,VXT_XFER,SIZEOF(char *) * (short int)xf_fngetdvi,VXT_END,
/* 1657 */ VXI_PUSHAB,VXT_VAL,0,VXI_PUSHAB,VXT_VAL,2,VXI_PUSHL,VXT_VAL,
/* 1665 */ 1,VXI_CALLS,VXT_LIT,3,VXT_XFER,SIZEOF(char *) * (short int)xf_fngetjpi,VXT_END,
/* 1672 */ VXI_PUSHAB,VXT_VAL,0,VXI_PUSHAB,VXT_VAL,2,VXI_PUSHL,VXT_VAL,
/* 1680 */ 1,VXI_CALLS,VXT_LIT,3,VXT_XFER,SIZEOF(char *) * (short int)xf_fngetlki,VXT_END,
/* 1687 */ VXI_PUSHAB,VXT_VAL,0,VXI_PUSHAB,VXT_VAL,2,VXI_PUSHAB,VXT_VAL,
/* 1695 */ 1,VXI_CALLS,VXT_LIT,3,VXT_XFER,SIZEOF(char *) * (short int)xf_fngetsyi,VXT_END,
/* 1702 */ VXI_PUSHAB,VXT_VAL,0,VXI_PUSHAB,VXT_VAL,1,VXI_CALLS,VXT_LIT,
/* 1710 */ 2,VXT_XFER,SIZEOF(char *) * (short int)xf_fnzjobexam,VXT_END,
/* 1714 */ VXI_PUSHAB,VXT_VAL,0,VXI_PUSHL,VXT_VAL,1,VXI_CALLS,VXT_LIT,
/* 1722 */ 2,VXT_XFER,SIZEOF(char *) * (short int)xf_fnzlkid,VXT_END,
/* 1726 */ VXI_PUSHAB,VXT_VAL,0,VXI_PUSHL,VXT_VAL,1,VXI_CALLS,VXT_LIT,
/* 1734 */ 2,VXT_XFER,SIZEOF(char *) * (short int)xf_fnzm,VXT_END,
/* 1738 */ VXI_PUSHAB,VXT_VAL,0,VXI_PUSHAB,VXT_VAL,5,VXI_PUSHAB,VXT_VAL,
/* 1746 */ 4,VXI_PUSHAB,VXT_VAL,3,VXI_PUSHAB,VXT_VAL,2,VXI_PUSHAB,
/* 1754 */ VXT_VAL,1,VXI_CALLS,VXT_LIT,6,VXT_XFER,SIZEOF(char *) * (short int)xf_fnzparse,VXT_END,
/* 1762 */ VXI_PUSHAB,VXT_VAL,0,VXI_PUSHL,VXT_VAL,1,VXI_CALLS,VXT_LIT,
/* 1770 */ 2,VXT_XFER,SIZEOF(char *) * (short int)xf_fnzpid,VXT_END,
/* 1774 */ VXI_PUSHAB,VXT_VAL,0,VXI_PUSHAB,VXT_VAL,2,VXI_PUSHAB,VXT_VAL,
/* 1782 */ 1,VXI_CALLS,VXT_LIT,3,VXT_XFER,SIZEOF(char *) * (short int)xf_fnzprevious,VXT_END,
/* 1789 */ VXI_PUSHAB,VXT_VAL,0,VXI_PUSHAB,VXT_VAL,1,VXI_CALLS,VXT_LIT,
/* 1797 */ 2,VXT_XFER,SIZEOF(char *) * (short int)xf_fnzpriv,VXT_END,
/* 1801 */ VXI_PUSHAB,VXT_VAL,0,VXI_CALLS,VXT_LIT,1,VXT_XFER,SIZEOF(char *) * (short int)xf_fnzqgblmod,
/* 1809 */ VXT_END,
/* 1810 */ VXI_PUSHAB,VXT_VAL,0,VXI_PUSHL,VXT_VAL,2,VXI_PUSHAB,VXT_VAL,
/* 1818 */ 1,VXI_CALLS,VXT_LIT,3,VXT_XFER,SIZEOF(char *) * (short int)xf_fnzsearch,VXT_END,
/* 1825 */ VXI_PUSHAB,VXT_VAL,0,VXI_PUSHAB,VXT_VAL,1,VXI_CALLS,VXT_LIT,
/* 1833 */ 2,VXT_XFER,SIZEOF(char *) * (short int)xf_fnzsetprv,VXT_END,
/* 1837 */ VXI_PUSHAB,VXT_VAL,0,VXI_PUSHL,VXT_VAL,2,VXI_PUSHL,VXT_VAL,
/* 1845 */ 1,VXI_CALLS,VXT_LIT,3,VXT_XFER,SIZEOF(char *) * (short int)xf_fnzsigproc,VXT_END,
/* 1852 */ VXI_PUSHAB,VXT_VAL,0,VXI_PUSHAB,VXT_VAL,6,VXI_PUSHAB,VXT_VAL,
/* 1860 */ 5,VXI_PUSHAB,VXT_VAL,4,VXI_PUSHL,VXT_VAL,3,VXI_PUSHAB,
/* 1868 */ VXT_VAL,2,VXI_PUSHAB,VXT_VAL,1,VXI_CALLS,VXT_LIT,7,
/* 1876 */ VXT_XFER,SIZEOF(char *) * (short int)xf_fnztrnlnm,VXT_END,
/* 1879 */ VXI_MOVAB,VXT_VAL,1,VXT_REG,0x50,VXI_MOVAB,VXT_VAL,2,
/* 1887 */ VXT_REG,0x51,VXI_JSB,VXT_XFER,SIZEOF(char *) * (short int)xf_follow,VXT_END,
/* 1893 */ VXI_MOVAB,VXT_VAL,0,VXT_REG,0x50,VXI_MOVAB,VXT_VAL,1,
/* 1901 */ VXT_REG,0x51,VXI_JSB,VXT_XFER,SIZEOF(char *) * (short int)xf_forcenum,VXT_END,
/* 1907 */ VXI_JSB,VXT_XFER,SIZEOF(char *) * (short int)xf_restartpc,VXI_JSB,VXT_XFER,SIZEOF(char *) * (short int)xf_forchk1,VXT_END,
/* 1914 */ VXI_PUSHAB,VXT_VAL,3,VXI_PUSHAB,VXT_VAL,2,VXI_PUSHAB,VXT_VAL,
/* 1922 */ 1,VXI_JSB,VXT_XFER,SIZEOF(char *) * (short int)xf_forinit,VXT_END,
/* 1927 */ VXI_JSB,VXT_XFER,SIZEOF(char *) * (short int)xf_forlcldob,VXI_BRB,VXT_JMP,1,VXT_END,
/* 1934 */ VXI_JSB,VXT_XFER,SIZEOF(char *) * (short int)xf_forlcldol,VXI_JMP,VXT_JMP,1,VXT_END,
/* 1941 */ VXI_JSB,VXT_XFER,SIZEOF(char *) * (short int)xf_forlcldow,VXI_BRW,VXT_JMP,1,VXT_END,
/* 1948 */ VXI_JSB,VXT_XFER,SIZEOF(char *) * (short int)xf_restartpc,VXI_PUSHAB,VXT_JMP,1,VXI_PUSHAB,VXT_VAL,
/* 1956 */ 4,VXI_PUSHAB,VXT_VAL,3,VXI_PUSHAB,VXT_VAL,2,VXI_JSB,
/* 1964 */ VXT_XFER,SIZEOF(char *) * (short int)xf_forloop,VXT_END,
/* 1967 */ VXI_JSB,VXT_XFER,SIZEOF(char *) * (short int)xf_restartpc,VXI_PUSHAB,VXT_JMP,1,VXI_PUSHAB,VXT_VAL,
/* 1975 */ 4,VXI_PUSHAB,VXT_VAL,3,VXI_PUSHAB,VXT_VAL,2,VXI_JSB,
/* 1983 */ VXT_XFER,SIZEOF(char *) * (short int)xf_forloop,VXT_END,
/* 1986 */ VXI_JSB,VXT_XFER,SIZEOF(char *) * (short int)xf_restartpc,VXI_PUSHAB,VXT_JMP,1,VXI_PUSHAB,VXT_VAL,
/* 1994 */ 4,VXI_PUSHAB,VXT_VAL,3,VXI_PUSHAB,VXT_VAL,2,VXI_JSB,
/* 2002 */ VXT_XFER,SIZEOF(char *) * (short int)xf_forloop,VXT_END,
/* 2005 */ VXT_IREPAB,VXT_VAL,2,VXI_CALLS,VXT_VAL,1,VXT_XFER,SIZEOF(char *) * (short int)xf_getindx,
/* 2013 */ VXI_MOVL,VXT_REG,0x50,VXT_ADDR,0,VXT_END,
/* 2019 */ VXI_MOVAB,VXT_VAL,0,VXT_REG,0x51,VXI_JSB,VXT_XFER,SIZEOF(char *) * (short int)xf_gettruth,
/* 2027 */ VXT_END,
/* 2028 */ VXI_PUSHAB,VXT_VAL,0,VXI_CALLS,VXT_LIT,1,VXT_XFER,SIZEOF(char *) * (short int)xf_gvdata,
/* 2036 */ VXT_END,
/* 2037 */ VXT_IREPAB,VXT_VAL,2,VXI_CALLS,VXT_VAL,1,VXT_XFER,SIZEOF(char *) * (short int)xf_gvextnam,
/* 2045 */ VXT_END,
/* 2046 */ VXI_PUSHAB,VXT_VAL,0,VXI_CALLS,VXT_LIT,1,VXT_XFER,SIZEOF(char *) * (short int)xf_gvget,
/* 2054 */ VXT_END,
/* 2055 */ VXI_PUSHAB,VXT_VAL,0,VXI_PUSHAB,VXT_VAL,2,VXI_CALLS,VXT_LIT,
/* 2063 */ 2,VXT_XFER,SIZEOF(char *) * (short int)xf_gvincr,VXT_END,
/* 2067 */ VXI_CALLS,VXT_LIT,0,VXT_XFER,SIZEOF(char *) * (short int)xf_gvkill,VXT_END,
/* 2073 */ VXT_IREPAB,VXT_VAL,2,VXI_CALLS,VXT_VAL,1,VXT_XFER,SIZEOF(char *) * (short int)xf_gvnaked,
/* 2081 */ VXT_END,
/* 2082 */ VXT_IREPAB,VXT_VAL,2,VXI_CALLS,VXT_VAL,1,VXT_XFER,SIZEOF(char *) * (short int)xf_gvname,
/* 2090 */ VXT_END,
/* 2091 */ VXI_PUSHAB,VXT_VAL,0,VXI_CALLS,VXT_LIT,1,VXT_XFER,SIZEOF(char *) * (short int)xf_gvnext,
/* 2099 */ VXT_END,
/* 2100 */ VXI_PUSHAB,VXT_VAL,1,VXI_PUSHAB,VXT_VAL,0,VXI_CALLS,VXT_LIT,
/* 2108 */ 2,VXT_XFER,SIZEOF(char *) * (short int)xf_gvo2,VXT_END,
/* 2112 */ VXI_PUSHAB,VXT_VAL,0,VXI_CALLS,VXT_LIT,1,VXT_XFER,SIZEOF(char *) * (short int)xf_gvorder,
/* 2120 */ VXT_END,
/* 2121 */ VXI_PUSHAB,VXT_VAL,1,VXI_CALLS,VXT_LIT,1,VXT_XFER,SIZEOF(char *) * (short int)xf_gvput,
/* 2129 */ VXT_END,
/* 2130 */ VXI_PUSHAB,VXT_VAL,0,VXI_CALLS,VXT_LIT,1,VXT_XFER,SIZEOF(char *) * (short int)xf_gvquery,
/* 2138 */ VXT_END,
/* 2139 */ VXI_PUSHAB,VXT_VAL,1,VXI_CALLS,VXT_LIT,1,VXT_XFER,SIZEOF(char *) * (short int)xf_gvrectarg,
/* 2147 */ VXT_END,
/* 2148 */ VXI_PUSHAB,VXT_VAL,0,VXI_CALLS,VXT_LIT,1,VXT_XFER,SIZEOF(char *) * (short int)xf_gvsavtarg,
/* 2156 */ VXT_END,
/* 2157 */ VXI_CALLS,VXT_LIT,0,VXT_XFER,SIZEOF(char *) * (short int)xf_gvzwithdraw,VXT_END,
/* 2163 */ VXI_JSB,VXT_XFER,SIZEOF(char *) * (short int)xf_restartpc,VXT_IREPAB,VXT_VAL,4,VXI_PUSHL,VXT_VAL,
/* 2171 */ 3,VXI_PUSHL,VXT_VAL,2,VXI_CALLS,VXT_VAL,1,VXT_XFER,
/* 2179 */ SIZEOF(char *) * (short int)xf_gvzwrite,VXT_END,
/* 2181 */ VXI_CALLS,VXT_LIT,0,VXT_XFER,SIZEOF(char *) * (short int)xf_halt,VXT_END,
/* 2187 */ VXI_JSB,VXT_XFER,SIZEOF(char *) * (short int)xf_restartpc,VXI_PUSHAB,VXT_VAL,1,VXI_CALLS,VXT_LIT,
/* 2195 */ 1,VXT_XFER,SIZEOF(char *) * (short int)xf_hang,VXT_END,
/* 2199 */ VXI_JSB,VXT_XFER,SIZEOF(char *) * (short int)xf_hardret,VXT_END,
/* 2203 */ VXI_PUSHAB,VXT_VAL,0,VXI_PUSHAB,VXT_VAL,2,VXI_PUSHAB,VXT_VAL,
/* 2211 */ 1,VXI_CALLS,VXT_LIT,3,VXT_XFER,SIZEOF(char *) * (short int)xf_idiv,VXT_END,
/* 2218 */ VXI_PUSHAB,VXT_VAL,0,VXI_CALLS,VXT_LIT,1,VXT_XFER,SIZEOF(char *) * (short int)xf_igetsrc,
/* 2226 */ VXT_END,
/* 2227 */ VXI_PUSHAB,VXT_VAL,0,VXI_PUSHL,VXT_VAL,2,VXI_PUSHAB,VXT_VAL,
/* 2235 */ 1,VXI_JSB,VXT_XFER,SIZEOF(char *) * (short int)xf_inddevparms,VXT_END,
/* 2240 */ VXI_PUSHAB,VXT_VAL,2,VXI_PUSHAB,VXT_VAL,1,VXI_PUSHAB,VXT_VAL,
/* 2248 */ 0,VXI_JSB,VXT_XFER,SIZEOF(char *) * (short int)xf_indfnname,VXT_END,
/* 2253 */ VXI_PUSHAB,VXT_VAL,0,VXI_PUSHL,VXT_VAL,2,VXI_PUSHAB,VXT_VAL,
/* 2261 */ 1,VXI_JSB,VXT_XFER,SIZEOF(char *) * (short int)xf_indfun,VXT_END,
/* 2266 */ VXI_PUSHAB,VXT_VAL,2,VXI_PUSHAB,VXT_VAL,1,VXI_PUSHAB,VXT_VAL,
/* 2274 */ 0,VXI_JSB,VXT_XFER,SIZEOF(char *) * (short int)xf_indget,VXT_END,
/* 2279 */ VXI_PUSHAB,VXT_VAL,0,VXI_PUSHAB,VXT_VAL,1,VXI_JSB,VXT_XFER,
/* 2287 */ SIZEOF(char *) * (short int)xf_indglvn,VXT_END,
/* 2289 */ VXI_PUSHAB,VXT_VAL,1,VXI_PUSHAB,VXT_VAL,2,VXI_PUSHAB,VXT_VAL,
/* 2297 */ 0,VXI_JSB,VXT_XFER,SIZEOF(char *) * (short int)xf_indincr,VXT_END,
/* 2302 */ VXI_PUSHAB,VXT_VAL,1,VXI_JSB,VXT_XFER,SIZEOF(char *) * (short int)xf_indlvadr,VXI_MOVL,VXT_REG,
/* 2310 */ 0x50,VXT_ADDR,0,VXT_END,
/* 2314 */ VXI_PUSHAB,VXT_VAL,0,VXI_PUSHAB,VXT_VAL,1,VXI_JSB,VXT_XFER,
/* 2322 */ SIZEOF(char *) * (short int)xf_indlvarg,VXT_END,
/* 2324 */ VXT_IREPAB,VXT_VAL,2,VXI_PUSHAB,VXT_VAL,0,VXI_CALLS,VXT_VAL,
/* 2332 */ 1,VXT_XFER,SIZEOF(char *) * (short int)xf_indname,VXT_END,
/* 2336 */ VXI_PUSHAB,VXT_VAL,1,VXI_JSB,VXT_XFER,SIZEOF(char *) * (short int)xf_indlvnamadr,VXI_MOVL,VXT_REG,
/* 2344 */ 0x50,VXT_ADDR,0,VXT_END,
/* 2348 */ VXI_PUSHAB,VXT_VAL,2,VXI_PUSHAB,VXT_VAL,1,VXI_PUSHAB,VXT_VAL,
/* 2356 */ 0,VXI_JSB,VXT_XFER,SIZEOF(char *) * (short int)xf_indo2,VXT_END,
/* 2361 */ VXI_PUSHAB,VXT_VAL,0,VXI_PUSHAB,VXT_VAL,1,VXI_JSB,VXT_XFER,
/* 2369 */ SIZEOF(char *) * (short int)xf_indpat,VXT_END,
/* 2371 */ VXI_PUSHAB,VXT_VAL,2,VXI_PUSHAB,VXT_VAL,1,VXI_JSB,VXT_XFER,
/* 2379 */ SIZEOF(char *) * (short int)xf_indrzshow,VXT_END,
/* 2381 */ VXI_PUSHAB,VXT_VAL,2,VXI_PUSHAB,VXT_VAL,1,VXI_JSB,VXT_XFER,
/* 2389 */ SIZEOF(char *) * (short int)xf_indset,VXT_END,
/* 2391 */ VXI_PUSHAB,VXT_VAL,0,VXI_PUSHAB,VXT_VAL,3,VXI_PUSHL,VXT_VAL,
/* 2399 */ 2,VXI_PUSHAB,VXT_VAL,1,VXI_JSB,VXT_XFER,SIZEOF(char *) * (short int)xf_indtext,VXT_END,
/* 2407 */ VXI_JSB,VXT_XFER,SIZEOF(char *) * (short int)xf_restartpc,VXT_IREPAB,VXT_VAL,2,VXI_CALLS,VXT_VAL,
/* 2415 */ 1,VXT_XFER,SIZEOF(char *) * (short int)xf_iocontrol,VXT_END,
/* 2419 */ VXI_MOVAB,VXT_VAL,1,VXT_REG,0x51,VXI_JSB,VXT_XFER,SIZEOF(char *) * (short int)xf_iretmvad,
/* 2427 */ VXT_END,
/* 2428 */ VXI_PUSHAB,VXT_VAL,1,VXI_JSB,VXT_XFER,SIZEOF(char *) * (short int)xf_iretmval,VXT_END,
/* 2435 */ VXI_JSB,VXT_XFER,SIZEOF(char *) * (short int)xf_isformal,VXT_END,
/* 2439 */ VXI_BRB,VXT_JMP,1,VXT_END,
/* 2443 */ VXI_JMP,VXT_JMP,1,VXT_END,
/* 2447 */ VXI_BRW,VXT_JMP,1,VXT_END,
/* 2451 */ VXI_JMP,VXT_VAL,1,VXT_END,
/* 2455 */ VXI_BEQL,VXT_JMP,1,VXT_END,
/* 2459 */ VXI_BNEQ,VXT_LIT,6,VXI_JMP,VXT_JMP,1,VXT_END,
/* 2466 */ VXI_BNEQ,VXT_LIT,3,VXI_BRW,VXT_JMP,1,VXT_END,
/* 2473 */ VXI_BGEQ,VXT_JMP,1,VXT_END,
/* 2477 */ VXI_BLSS,VXT_LIT,6,VXI_JMP,VXT_JMP,1,VXT_END,
/* 2484 */ VXI_BLSS,VXT_LIT,3,VXI_BRW,VXT_JMP,1,VXT_END,
/* 2491 */ VXI_BGTR,VXT_JMP,1,VXT_END,
/* 2495 */ VXI_BLEQ,VXT_LIT,6,VXI_JMP,VXT_JMP,1,VXT_END,
/* 2502 */ VXI_BLEQ,VXT_LIT,3,VXI_BRW,VXT_JMP,1,VXT_END,
/* 2509 */ VXI_BLEQ,VXT_JMP,1,VXT_END,
/* 2513 */ VXI_BGTR,VXT_LIT,6,VXI_JMP,VXT_JMP,1,VXT_END,
/* 2520 */ VXI_BGTR,VXT_LIT,3,VXI_BRW,VXT_JMP,1,VXT_END,
/* 2527 */ VXI_BLSS,VXT_JMP,1,VXT_END,
/* 2531 */ VXI_BGEQ,VXT_LIT,6,VXI_JMP,VXT_JMP,1,VXT_END,
/* 2538 */ VXI_BGEQ,VXT_LIT,3,VXI_BRW,VXT_JMP,1,VXT_END,
/* 2545 */ VXI_BNEQ,VXT_JMP,1,VXT_END,
/* 2549 */ VXI_BNEQ,VXT_LIT,6,VXI_JMP,VXT_JMP,1,VXT_END,
/* 2556 */ VXI_BEQL,VXT_LIT,3,VXI_BRW,VXT_JMP,1,VXT_END,
/* 2563 */ VXI_BLBC,VXT_REG,0x5A,VXT_JMP,1,VXT_END,
/* 2569 */ VXI_BLBS,VXT_REG,0x5A,VXT_LIT,6,VXI_JMP,VXT_JMP,1,
/* 2577 */ VXT_END,
/* 2578 */ VXI_BLBS,VXT_REG,0x5A,VXT_LIT,3,VXI_BRW,VXT_JMP,1,
/* 2586 */ VXT_END,
/* 2587 */ VXI_BLBS,VXT_REG,0x5A,VXT_JMP,1,VXT_END,
/* 2593 */ VXI_BLBC,VXT_REG,0x5A,VXT_LIT,6,VXI_JMP,VXT_JMP,1,
/* 2601 */ VXT_END,
/* 2602 */ VXI_BLBC,VXT_REG,0x5A,VXT_LIT,3,VXI_BRW,VXT_JMP,1,
/* 2610 */ VXT_END,
/* 2611 */ VXI_JSB,VXT_XFER,SIZEOF(char *) * (short int)xf_restartpc,VXT_IREPAB,VXT_VAL,7,VXI_PUSHL,VXT_VAL,
/* 2619 */ 6,VXI_PUSHAB,VXT_VAL,5,VXI_PUSHAB,VXT_VAL,4,VXI_PUSHL,
/* 2627 */ VXT_VAL,3,VXI_PUSHAB,VXT_VAL,2,VXI_CALLS,VXT_VAL,1,
/* 2635 */ VXT_XFER,SIZEOF(char *) * (short int)xf_job,VXT_END,
/* 2638 */ VXI_PUSHAB,VXT_VAL,1,VXI_CALLS,VXT_LIT,1,VXT_XFER,SIZEOF(char *) * (short int)xf_kill,
/* 2646 */ VXT_END,
/* 2647 */ VXI_PUSHL,VXT_VAL,1,VXI_CALLS,VXT_LIT,1,VXT_XFER,SIZEOF(char *) * (short int)xf_killalias,
/* 2655 */ VXT_END,
/* 2656 */ VXI_CALLS,VXT_LIT,0,VXT_XFER,SIZEOF(char *) * (short int)xf_killall,VXT_END,
/* 2662 */ VXI_CALLS,VXT_LIT,0,VXT_XFER,SIZEOF(char *) * (short int)xf_killaliasall,VXT_END,
/* 2668 */ VXI_PUSHL,VXT_VAL,2,VXI_PUSHAB,VXT_VAL,1,VXI_PUSHAB,VXT_VAL,
/* 2676 */ 3,VXI_CALLS,VXT_LIT,3,VXT_XFER,SIZEOF(char *) * (short int)xf_labaddr,VXI_MOVL,VXT_REG,
/* 2684 */ 0x50,VXT_ADDR,0,VXT_END,
/* 2688 */ VXI_PUSHL,VXT_VAL,1,VXI_CALLS,VXT_LIT,1,VXT_XFER,SIZEOF(char *) * (short int)xf_lckdecr,
/* 2696 */ VXT_END,
/* 2697 */ VXI_PUSHL,VXT_VAL,1,VXI_CALLS,VXT_LIT,1,VXT_XFER,SIZEOF(char *) * (short int)xf_lckincr,
/* 2705 */ VXT_END,
/* 2706 */ VXI_MOVAB,VXT_JMP,1,VXT_ADDR,0,VXT_END,
/* 2712 */ VXI_MOVAB,VXT_JMP,1,VXT_ADDR,0,VXT_END,
/* 2718 */ VXI_MOVAB,VXT_JMP,1,VXT_ADDR,0,VXT_END,
/* 2724 */ VXT_IREPL,VXT_VAL,2,VXI_PUSHL,VXT_VAL,1,VXI_JSB,VXT_XFER,
/* 2732 */ SIZEOF(char *) * (short int)xf_linefetch,VXT_END,
/* 2734 */ VXI_JSB,VXT_XFER,SIZEOF(char *) * (short int)xf_linestart,VXT_END,
/* 2738 */ VXT_IREPAB,VXT_VAL,4,VXI_PUSHAB,VXT_VAL,3,VXI_PUSHAB,VXT_VAL,
/* 2746 */ 2,VXI_CALLS,VXT_VAL,1,VXT_XFER,SIZEOF(char *) * (short int)xf_lkname,VXT_END,
/* 2753 */ VXI_CALLS,VXT_LIT,0,VXT_XFER,SIZEOF(char *) * (short int)xf_lkinit,VXT_END,
/* 2759 */ VXT_IREPAB,VXT_VAL,4,VXI_PUSHAB,VXT_VAL,3,VXI_PUSHL,VXT_VAL,
/* 2767 */ 2,VXI_CALLS,VXT_VAL,1,VXT_XFER,SIZEOF(char *) * (short int)xf_lkname,VXT_END,
/* 2774 */ VXI_PUSHL,VXT_VAL,1,VXI_CALLS,VXT_LIT,1,VXT_XFER,SIZEOF(char *) * (short int)xf_lock,
/* 2782 */ VXT_END,
/* 2783 */ VXI_JSB,VXT_XFER,SIZEOF(char *) * (short int)xf_restartpc,VXT_IREPAB,VXT_VAL,3,VXI_PUSHL,VXT_VAL,
/* 2791 */ 2,VXI_CALLS,VXT_VAL,1,VXT_XFER,SIZEOF(char *) * (short int)xf_lvpatwrite,VXT_END,
/* 2798 */ VXI_PUSHAB,VXT_VAL,1,VXI_CALLS,VXT_LIT,1,VXT_XFER,SIZEOF(char *) * (short int)xf_lvzwithdraw,
/* 2806 */ VXT_END,
/* 2807 */ VXI_JSB,VXT_XFER,SIZEOF(char *) * (short int)xf_restartpc,VXT_IREPAB,VXT_VAL,2,VXI_CALLS,VXT_VAL,
/* 2815 */ 1,VXT_XFER,SIZEOF(char *) * (short int)xf_lvzwrite,VXT_END,
/* 2819 */ VXI_PUSHAB,VXT_VAL,0,VXI_PUSHAB,VXT_VAL,2,VXI_PUSHAB,VXT_VAL,
/* 2827 */ 1,VXI_CALLS,VXT_LIT,3,VXT_XFER,SIZEOF(char *) * (short int)xf_flt_mod,VXT_END,
/* 2834 */ VXI_PUSHAB,VXT_VAL,0,VXI_PUSHAB,VXT_VAL,2,VXI_PUSHAB,VXT_VAL,
/* 2842 */ 1,VXI_CALLS,VXT_LIT,3,VXT_XFER,SIZEOF(char *) * (short int)xf_mul,VXT_END,
/* 2849 */ VXI_MOVAB,VXT_VAL,0,VXT_REG,0x50,VXI_MOVAB,VXT_VAL,1,
/* 2857 */ VXT_REG,0x51,VXI_JSB,VXT_XFER,SIZEOF(char *) * (short int)xf_neg,VXT_END,
/* 2863 */ VXI_PUSHL,VXT_VAL,1,VXI_JSB,VXT_XFER,SIZEOF(char *) * (short int)xf_newintrinsic,VXT_END,
/* 2870 */ VXI_PUSHL,VXT_VAL,1,VXI_JSB,VXT_XFER,SIZEOF(char *) * (short int)xf_newvar,VXT_END,
/* 2877 */ VXI_PUSHAB,VXT_VAL,0,VXI_CALLS,VXT_LIT,1,VXT_XFER,SIZEOF(char *) * (short int)xf_nullexp,
/* 2885 */ VXT_END,
/* 2886 */ VXI_MOVAB,VXT_VAL,1,VXT_REG,0x50,VXI_MOVAB,VXT_VAL,2,
/* 2894 */ VXT_REG,0x51,VXI_JSB,VXT_XFER,SIZEOF(char *) * (short int)xf_numcmp,VXT_END,
/* 2900 */ VXI_JSB,VXT_XFER,SIZEOF(char *) * (short int)xf_restartpc,VXI_PUSHAB,VXT_VAL,4,VXI_PUSHL,VXT_VAL,
/* 2908 */ 3,VXI_PUSHAB,VXT_VAL,2,VXI_PUSHAB,VXT_VAL,1,VXI_CALLS,
/* 2916 */ VXT_LIT,4,VXT_XFER,SIZEOF(char *) * (short int)xf_open,VXT_END,
/* 2921 */ VXI_MOVAB,VXT_VAL,1,VXT_REG,0x50,VXI_MOVAB,VXT_VAL,2,
/* 2929 */ VXT_REG,0x51,VXI_JSB,VXT_XFER,SIZEOF(char *) * (short int)xf_pattern,VXT_END,
/* 2935 */ VXI_PUSHAB,VXT_VAL,0,VXI_PUSHAB,VXT_VAL,2,VXI_PUSHAB,VXT_VAL,
/* 2943 */ 1,VXI_CALLS,VXT_LIT,3,VXT_XFER,SIZEOF(char *) * (short int)xf_fnpopulation,VXT_END,
/* 2950 */ VXI_PUSHAB,VXT_VAL,0,VXI_PUSHAB,VXT_VAL,2,VXI_PUSHAB,VXT_VAL,
/* 2958 */ 1,VXI_CALLS,VXT_LIT,3,VXT_XFER,SIZEOF(char *) * (short int)xf_fnzpopulation,VXT_END,
/* 2965 */ VXT_IREPAB,VXT_VAL,2,VXI_CALLS,VXT_VAL,1,VXT_XFER,SIZEOF(char *) * (short int)xf_putindx,
/* 2973 */ VXI_MOVL,VXT_REG,0x50,VXT_ADDR,0,VXT_END,
/* 2979 */ VXI_JSB,VXT_XFER,SIZEOF(char *) * (short int)xf_restartpc,VXI_PUSHL,VXT_VAL,1,VXI_PUSHAB,VXT_VAL,
/* 2987 */ 0,VXI_CALLS,VXT_LIT,2,VXT_XFER,SIZEOF(char *) * (short int)xf_rdone,VXT_END,
/* 2994 */ VXI_JSB,VXT_XFER,SIZEOF(char *) * (short int)xf_restartpc,VXI_PUSHL,VXT_VAL,1,VXI_PUSHAB,VXT_VAL,
/* 3002 */ 0,VXI_CALLS,VXT_LIT,2,VXT_XFER,SIZEOF(char *) * (short int)xf_read,VXT_END,
/* 3009 */ VXI_JSB,VXT_XFER,SIZEOF(char *) * (short int)xf_restartpc,VXI_PUSHL,VXT_VAL,2,VXI_PUSHL,VXT_VAL,
/* 3017 */ 1,VXI_PUSHAB,VXT_VAL,0,VXI_CALLS,VXT_LIT,3,VXT_XFER,
/* 3025 */ SIZEOF(char *) * (short int)xf_readfl,VXT_END,
/* 3027 */ VXI_JSB,VXT_XFER,SIZEOF(char *) * (short int)xf_restartpc,VXT_END,
/* 3031 */ VXI_JSB,VXT_XFER,SIZEOF(char *) * (short int)xf_ret,VXT_END,
/* 3035 */ VXI_MOVAB,VXT_VAL,1,VXT_REG,0x50,VXI_MOVL,VXT_VAL,2,
/* 3043 */ VXT_REG,0x51,VXI_JSB,VXT_XFER,SIZEOF(char *) * (short int)xf_retarg,VXT_END,
/* 3049 */ VXI_PUSHAB,VXT_VAL,2,VXI_PUSHAB,VXT_VAL,1,VXI_CALLS,VXT_LIT,
/* 3057 */ 2,VXT_XFER,SIZEOF(char *) * (short int)xf_rhdaddr,VXI_MOVL,VXT_REG,0x50,VXT_ADDR,0,
/* 3065 */ VXT_END,
/* 3066 */ VXI_PUSHL,VXT_LIT,0,VXI_PUSHAB,VXT_VAL,1,VXI_CALLS,VXT_LIT,
/* 3074 */ 2,VXT_XFER,SIZEOF(char *) * (short int)xf_rhdaddr,VXI_MOVL,VXT_REG,0x50,VXT_ADDR,0,
/* 3082 */ VXT_END,
/* 3083 */ VXI_PUSHL,VXT_VAL,2,VXI_PUSHL,VXT_VAL,1,VXI_JSB,VXT_XFER,
/* 3091 */ SIZEOF(char *) * (short int)xf_rterror,VXT_END,
/* 3093 */ VXI_PUSHL,VXT_VAL,1,VXI_PUSHAB,VXT_VAL,2,VXI_CALLS,VXT_LIT,
/* 3101 */ 2,VXT_XFER,SIZEOF(char *) * (short int)xf_setals2als,VXT_END,
/* 3105 */ VXI_PUSHAB,VXT_VAL,1,VXI_PUSHAB,VXT_VAL,2,VXI_CALLS,VXT_LIT,
/* 3113 */ 2,VXT_XFER,SIZEOF(char *) * (short int)xf_setalsin2alsct,VXT_END,
/* 3117 */ VXI_PUSHL,VXT_VAL,1,VXI_PUSHAB,VXT_VAL,2,VXI_CALLS,VXT_LIT,
/* 3125 */ 2,VXT_XFER,SIZEOF(char *) * (short int)xf_setalsctin2als,VXT_END,
/* 3129 */ VXI_PUSHAB,VXT_VAL,1,VXI_PUSHAB,VXT_VAL,2,VXI_CALLS,VXT_LIT,
/* 3137 */ 2,VXT_XFER,SIZEOF(char *) * (short int)xf_setalsct2alsct,VXT_END,
/* 3141 */ VXI_PUSHL,VXT_VAL,1,VXI_PUSHAB,VXT_VAL,2,VXI_CALLS,VXT_LIT,
/* 3149 */ 2,VXT_XFER,SIZEOF(char *) * (short int)xf_setfnretin2als,VXT_END,
/* 3153 */ VXI_PUSHAB,VXT_VAL,1,VXI_PUSHAB,VXT_VAL,2,VXI_CALLS,VXT_LIT,
/* 3161 */ 2,VXT_XFER,SIZEOF(char *) * (short int)xf_setfnretin2alsct,VXT_END,
/* 3165 */ VXI_PUSHAB,VXT_VAL,0,VXI_PUSHL,VXT_VAL,3,VXI_PUSHL,VXT_VAL,
/* 3173 */ 2,VXI_PUSHAB,VXT_VAL,4,VXI_PUSHAB,VXT_VAL,1,VXI_CALLS,
/* 3181 */ VXT_LIT,5,VXT_XFER,SIZEOF(char *) * (short int)xf_setextract,VXT_END,
/* 3186 */ VXI_PUSHAB,VXT_VAL,0,VXI_PUSHL,VXT_VAL,3,VXI_PUSHAB,VXT_VAL,
/* 3194 */ 4,VXI_PUSHL,VXT_VAL,2,VXI_PUSHAB,VXT_VAL,1,VXI_CALLS,
/* 3202 */ VXT_LIT,5,VXT_XFER,SIZEOF(char *) * (short int)xf_setp1,VXT_END,
/* 3207 */ VXI_PUSHAB,VXT_VAL,0,VXI_PUSHL,VXT_VAL,4,VXI_PUSHL,VXT_VAL,
/* 3215 */ 3,VXI_PUSHAB,VXT_VAL,5,VXI_PUSHAB,VXT_VAL,2,VXI_PUSHAB,
/* 3223 */ VXT_VAL,1,VXI_CALLS,VXT_LIT,6,VXT_XFER,SIZEOF(char *) * (short int)xf_setpiece,VXT_END,
/* 3231 */ VXI_PUSHAB,VXT_VAL,0,VXI_PUSHL,VXT_VAL,3,VXI_PUSHL,VXT_VAL,
/* 3239 */ 2,VXI_PUSHAB,VXT_VAL,4,VXI_PUSHAB,VXT_VAL,1,VXI_CALLS,
/* 3247 */ VXT_LIT,5,VXT_XFER,SIZEOF(char *) * (short int)xf_setzextract,VXT_END,
/* 3252 */ VXI_PUSHAB,VXT_VAL,0,VXI_PUSHL,VXT_VAL,3,VXI_PUSHAB,VXT_VAL,
/* 3260 */ 4,VXI_PUSHL,VXT_VAL,2,VXI_PUSHAB,VXT_VAL,1,VXI_CALLS,
/* 3268 */ VXT_LIT,5,VXT_XFER,SIZEOF(char *) * (short int)xf_setzp1,VXT_END,
/* 3273 */ VXI_PUSHAB,VXT_VAL,0,VXI_PUSHL,VXT_VAL,4,VXI_PUSHL,VXT_VAL,
/* 3281 */ 3,VXI_PUSHAB,VXT_VAL,5,VXI_PUSHAB,VXT_VAL,2,VXI_PUSHAB,
/* 3289 */ VXT_VAL,1,VXI_CALLS,VXT_LIT,6,VXT_XFER,SIZEOF(char *) * (short int)xf_setzpiece,VXT_END,
/* 3297 */ VXI_BISB2,VXT_LIT,1,VXT_REG,0x5A,VXI_JSB,VXT_XFER,SIZEOF(char *) * (short int)xf_dt_true,
/* 3305 */ VXT_END,
/* 3306 */ VXI_PUSHL,VXT_VAL,5,VXI_PUSHAB,VXT_VAL,4,VXI_PUSHL,VXT_VAL,
/* 3314 */ 2,VXI_PUSHAB,VXT_VAL,1,VXI_PUSHAB,VXT_VAL,3,VXI_CALLS,
/* 3322 */ VXT_LIT,5,VXT_XFER,SIZEOF(char *) * (short int)xf_setzbrk,VXT_END,
/* 3327 */ VXI_MOVAB,VXT_VAL,1,VXT_REG,0x50,VXI_MOVAB,VXT_VAL,2,
/* 3335 */ VXT_REG,0x51,VXI_JSB,VXT_XFER,SIZEOF(char *) * (short int)xf_sorts_after,VXT_END,
/* 3341 */ VXT_IREPAB,VXT_VAL,2,VXI_CALLS,VXT_VAL,1,VXT_XFER,SIZEOF(char *) * (short int)xf_srchindx,
/* 3349 */ VXI_MOVL,VXT_REG,0x50,VXT_ADDR,0,VXT_END,
/* 3355 */ VXI_MOVAB,VXT_VAL,2,VXT_REG,0x51,VXI_MOVAB,VXT_VAL,1,
/* 3363 */ VXT_REG,0x50,VXI_JSB,VXT_XFER,SIZEOF(char *) * (short int)xf_sto,VXT_END,
/* 3369 */ VXI_MOVC3,VXT_LIT,16,VXT_VAL,2,VXT_VAL,1,VXT_END,
/* 3377 */ VXI_MOVAB,VXT_VAL,1,VXT_REG,0x51,VXI_MOVAB,VXT_VAL,0,
/* 3385 */ VXT_REG,0x50,VXI_JSB,VXT_XFER,SIZEOF(char *) * (short int)xf_sto,VXT_END,
/* 3391 */ VXI_PUSHAB,VXT_VAL,0,VXI_PUSHAB,VXT_VAL,2,VXI_PUSHAB,VXT_VAL,
/* 3399 */ 1,VXI_CALLS,VXT_LIT,3,VXT_XFER,SIZEOF(char *) * (short int)xf_sub,VXT_END,
/* 3406 */ VXI_PUSHAB,VXT_VAL,0,VXI_PUSHL,VXT_VAL,1,VXI_CALLS,VXT_LIT,
/* 3414 */ 2,VXT_XFER,SIZEOF(char *) * (short int)xf_svget,VXT_END,
/* 3418 */ VXI_PUSHAB,VXT_VAL,2,VXI_PUSHL,VXT_VAL,1,VXI_JSB,VXT_XFER,
/* 3426 */ SIZEOF(char *) * (short int)xf_psvput,VXT_END,
/* 3428 */ VXI_PUSHAB,VXT_VAL,2,VXI_PUSHL,VXT_VAL,1,VXI_CALLS,VXT_LIT,
/* 3436 */ 2,VXT_XFER,SIZEOF(char *) * (short int)xf_svput,VXT_END,
/* 3440 */ VXI_MOVL,VXT_REG,0x50,VXT_REG,0x5A,VXT_END,
/* 3446 */ VXI_JSB,VXT_XFER,SIZEOF(char *) * (short int)xf_tcommit,VXT_END,
/* 3450 */ VXI_PUSHL,VXT_VAL,1,VXI_JSB,VXT_XFER,SIZEOF(char *) * (short int)xf_trollback,VXT_END,
/* 3457 */ VXI_PUSHL,VXT_VAL,1,VXI_JSB,VXT_XFER,SIZEOF(char *) * (short int)xf_trestart,VXT_END,
/* 3464 */ VXT_IREPAB,VXT_VAL,4,VXI_PUSHL,VXT_VAL,3,VXI_PUSHAB,VXT_VAL,
/* 3472 */ 2,VXI_PUSHL,VXT_VAL,1,VXI_JSB,VXT_XFER,SIZEOF(char *) * (short int)xf_tstart,VXT_END,
/* 3480 */ VXI_CALLS,VXT_LIT,0,VXT_XFER,SIZEOF(char *) * (short int)xf_unlock,VXT_END,
/* 3486 */ VXI_PUSHAB,VXT_VAL,2,VXI_PUSHAB,VXT_VAL,1,VXI_CALLS,VXT_LIT,
/* 3494 */ 2,VXT_XFER,SIZEOF(char *) * (short int)xf_use,VXT_END,
/* 3498 */ VXT_IREPAB,VXT_VAL,2,VXI_CALLS,VXT_VAL,1,VXT_XFER,SIZEOF(char *) * (short int)xf_view,
/* 3506 */ VXT_END,
/* 3507 */ VXI_CMPL,VXT_VAL,1,VXT_VAL,2,VXT_END,
/* 3513 */ VXI_PUSHAB,VXT_VAL,1,VXI_CALLS,VXT_LIT,1,VXT_XFER,SIZEOF(char *) * (short int)xf_write,
/* 3521 */ VXT_END,
/* 3522 */ VXI_PUSHL,VXT_VAL,1,VXI_CALLS,VXT_LIT,1,VXT_XFER,SIZEOF(char *) * (short int)xf_wteol,
/* 3530 */ VXT_END,
/* 3531 */ VXI_CALLS,VXT_LIT,0,VXT_XFER,SIZEOF(char *) * (short int)xf_wtff,VXT_END,
/* 3537 */ VXI_PUSHL,VXT_VAL,1,VXI_CALLS,VXT_LIT,1,VXT_XFER,SIZEOF(char *) * (short int)xf_wtone,
/* 3545 */ VXT_END,
/* 3546 */ VXI_PUSHL,VXT_VAL,1,VXI_CALLS,VXT_LIT,1,VXT_XFER,SIZEOF(char *) * (short int)xf_wttab,
/* 3554 */ VXT_END,
/* 3555 */ VXT_IREPAB,VXT_VAL,2,VXI_CALLS,VXT_VAL,1,VXT_XFER,SIZEOF(char *) * (short int)xf_xkill,
/* 3563 */ VXT_END,
/* 3564 */ VXT_IREPAB,VXT_VAL,2,VXI_PUSHL,VXT_VAL,1,VXI_JSB,VXT_XFER,
/* 3572 */ SIZEOF(char *) * (short int)xf_xnew,VXT_END,
/* 3574 */ VXI_PUSHL,VXT_VAL,1,VXI_CALLS,VXT_LIT,1,VXT_XFER,SIZEOF(char *) * (short int)xf_zallocate,
/* 3582 */ VXT_END,
/* 3583 */ VXI_JSB,VXT_XFER,SIZEOF(char *) * (short int)xf_restartpc,VXI_PUSHAB,VXT_VAL,1,VXI_CALLS,VXT_LIT,
/* 3591 */ 1,VXT_XFER,SIZEOF(char *) * (short int)xf_zattach,VXT_END,
/* 3595 */ VXI_PUSHL,VXT_VAL,2,VXI_PUSHAB,VXT_VAL,1,VXI_CALLS,VXT_LIT,
/* 3603 */ 2,VXT_XFER,SIZEOF(char *) * (short int)xf_zcompile,VXT_END,
/* 3607 */ VXI_JSB,VXT_XFER,SIZEOF(char *) * (short int)xf_zcont,VXT_END,
/* 3611 */ VXI_PUSHL,VXT_VAL,1,VXI_CALLS,VXT_LIT,1,VXT_XFER,SIZEOF(char *) * (short int)xf_zdeallocate,
/* 3619 */ VXT_END,
/* 3620 */ VXI_JSB,VXT_XFER,SIZEOF(char *) * (short int)xf_restartpc,VXI_PUSHAB,VXT_VAL,2,VXI_PUSHAB,VXT_VAL,
/* 3628 */ 1,VXI_CALLS,VXT_LIT,2,VXT_XFER,SIZEOF(char *) * (short int)xf_zedit,VXT_END,
/* 3635 */ VXI_PUSHL,VXT_VAL,1,VXI_JSB,VXT_XFER,SIZEOF(char *) * (short int)xf_zg1,VXT_END,
/* 3642 */ VXI_PUSHL,VXT_VAL,1,VXI_PUSHL,VXT_VAL,4,VXI_PUSHAB,VXT_VAL,
/* 3650 */ 3,VXI_PUSHAB,VXT_VAL,2,VXI_JSB,VXT_XFER,SIZEOF(char *) * (short int)xf_zgoto,VXT_END,
/* 3658 */ VXI_PUSHAB,VXT_VAL,1,VXI_CALLS,VXT_LIT,1,VXT_XFER,SIZEOF(char *) * (short int)xf_zhalt,
/* 3666 */ VXT_END,
/* 3667 */ VXI_PUSHAB,VXT_VAL,2,VXI_PUSHAB,VXT_VAL,1,VXI_CALLS,VXT_LIT,
/* 3675 */ 2,VXT_XFER,SIZEOF(char *) * (short int)xf_zhelp,VXT_END,
/* 3679 */ VXI_PUSHAB,VXT_VAL,2,VXI_PUSHAB,VXT_VAL,1,VXI_CALLS,VXT_LIT,
/* 3687 */ 2,VXT_XFER,SIZEOF(char *) * (short int)xf_zlink,VXT_END,
/* 3691 */ VXT_IREPAB,VXT_VAL,3,VXI_PUSHL,VXT_VAL,2,VXI_CALLS,VXT_VAL,
/* 3699 */ 1,VXT_XFER,SIZEOF(char *) * (short int)xf_zmess,VXT_END,
/* 3703 */ VXI_PUSHAB,VXT_VAL,0,VXI_CALLS,VXT_LIT,1,VXT_XFER,SIZEOF(char *) * (short int)xf_zprevious,
/* 3711 */ VXT_END,
/* 3712 */ VXI_JSB,VXT_XFER,SIZEOF(char *) * (short int)xf_restartpc,VXI_PUSHL,VXT_VAL,5,VXI_PUSHAB,VXT_VAL,
/* 3720 */ 4,VXI_PUSHL,VXT_VAL,3,VXI_PUSHAB,VXT_VAL,2,VXI_PUSHAB,
/* 3728 */ VXT_VAL,1,VXI_CALLS,VXT_LIT,5,VXT_XFER,SIZEOF(char *) * (short int)xf_zprint,VXT_END,
/* 3736 */ VXI_JSB,VXT_XFER,SIZEOF(char *) * (short int)xf_restartpc,VXI_PUSHL,VXT_LIT,0,VXI_PUSHL,VXT_VAL,
/* 3744 */ 2,VXI_PUSHAB,VXT_VAL,1,VXI_CALLS,VXT_LIT,3,VXT_XFER,
/* 3752 */ SIZEOF(char *) * (short int)xf_zshow,VXT_END,
/* 3754 */ VXI_JSB,VXT_XFER,SIZEOF(char *) * (short int)xf_restartpc,VXI_PUSHAB,VXT_VAL,3,VXI_PUSHL,VXT_VAL,
/* 3762 */ 2,VXI_PUSHAB,VXT_VAL,1,VXI_CALLS,VXT_LIT,3,VXT_XFER,
/* 3770 */ SIZEOF(char *) * (short int)xf_zshow,VXT_END,
/* 3772 */ VXI_PUSHL,VXT_LIT,0,VXI_PUSHL,VXT_VAL,1,VXI_CALLS,VXT_LIT,
/* 3780 */ 2,VXT_XFER,SIZEOF(char *) * (short int)xf_zstep,VXI_JSB,VXT_XFER,SIZEOF(char *) * (short int)xf_zcont,VXT_END,
/* 3787 */ VXI_PUSHAB,VXT_VAL,2,VXI_PUSHL,VXT_VAL,1,VXI_CALLS,VXT_LIT,
/* 3795 */ 2,VXT_XFER,SIZEOF(char *) * (short int)xf_zstep,VXI_JSB,VXT_XFER,SIZEOF(char *) * (short int)xf_zcont,VXT_END,
/* 3802 */ VXI_JSB,VXT_XFER,SIZEOF(char *) * (short int)xf_restartpc,VXI_PUSHAB,VXT_VAL,1,VXI_CALLS,VXT_LIT,
/* 3810 */ 1,VXT_XFER,SIZEOF(char *) * (short int)xf_zsystem,VXT_END,
/* 3814 */ VXI_PUSHL,VXT_VAL,1,VXI_CALLS,VXT_LIT,1,VXT_XFER,SIZEOF(char *) * (short int)xf_ztcommit,
/* 3822 */ VXT_END,
/* 3823 */ VXI_CALLS,VXT_LIT,0,VXT_XFER,SIZEOF(char *) * (short int)xf_ztstart,VXT_END,
/* 3829 */ VXI_CALLS,VXT_LIT,0,VXT_XFER,SIZEOF(char *) * (short int)xf_merge,VXT_END,
/* 3835 */ VXI_PUSHL,VXT_LIT,0,VXI_PUSHL,VXT_VAL,1,VXI_CALLS,VXT_LIT,
/* 3843 */ 2,VXT_XFER,SIZEOF(char *) * (short int)xf_merge_arg,VXT_END,
/* 3847 */ VXI_PUSHAB,VXT_VAL,2,VXI_PUSHL,VXT_VAL,1,VXI_CALLS,VXT_LIT,
/* 3855 */ 2,VXT_XFER,SIZEOF(char *) * (short int)xf_merge_arg,VXT_END,
/* 3859 */ VXI_PUSHAB,VXT_VAL,1,VXI_PUSHAB,VXT_VAL,2,VXI_JSB,VXT_XFER,
/* 3867 */ SIZEOF(char *) * (short int)xf_indmerge,VXT_END,
/* 3869 */ VXT_IREPAB,VXT_VAL,2,VXI_CALLS,VXT_VAL,1,VXT_XFER,SIZEOF(char *) * (short int)xf_m_srchindx,
/* 3877 */ VXI_MOVL,VXT_REG,0x50,VXT_ADDR,0,VXT_END,
/* 3883 */ VXI_PUSHAB,VXT_VAL,0,VXI_PUSHAB,VXT_VAL,2,VXI_PUSHAB,VXT_VAL,
/* 3891 */ 1,VXI_CALLS,VXT_LIT,3,VXT_XFER,SIZEOF(char *) * (short int)xf_fnzconvert2,VXT_END,
/* 3898 */ VXI_PUSHAB,VXT_VAL,0,VXI_PUSHAB,VXT_VAL,3,VXI_PUSHAB,VXT_VAL,
/* 3906 */ 2,VXI_PUSHAB,VXT_VAL,1,VXI_CALLS,VXT_LIT,4,VXT_XFER,
/* 3914 */ SIZEOF(char *) * (short int)xf_fnzconvert3,VXT_END,
/* 3916 */ VXI_PUSHAB,VXT_VAL,0,VXI_PUSHL,VXT_VAL,3,VXI_PUSHL,VXT_VAL,
/* 3924 */ 2,VXI_PUSHAB,VXT_VAL,1,VXI_CALLS,VXT_LIT,4,VXT_XFER,
/* 3932 */ SIZEOF(char *) * (short int)xf_fnzsubstr,VXT_END,
/* 3934 */ VXI_PUSHAB,VXT_VAL,0,VXI_PUSHAB,VXT_VAL,1,VXI_CALLS,VXT_LIT,
/* 3942 */ 2,VXT_XFER,SIZEOF(char *) * (short int)xf_fnzwidth,VXT_END,
/* 3946 */ VXI_CALLS,VXT_LIT,0,VXT_XFER,SIZEOF(char *) * (short int)xf_ztrigger,VXT_END,
/* 3952 */ VXI_PUSHL,VXT_VAL,1,VXI_CALLS,VXT_LIT,1,VXT_XFER,SIZEOF(char *) * (short int)xf_zwritesvn,
/* 3960 */ VXT_END,
/* 3961 */ VXI_PUSHL,VXT_VAL,2,VXI_PUSHL,VXT_VAL,1,VXI_CALLS,VXT_LIT,
/* 3969 */ 2,VXT_XFER,SIZEOF(char *) * (short int)xf_rfrshindx,VXI_MOVL,VXT_REG,0x50,VXT_ADDR,0,
/* 3977 */ VXT_END,
/* 3978 */ VXT_IREPAB,VXT_VAL,2,VXI_CALLS,VXT_VAL,1,VXT_XFER,SIZEOF(char *) * (short int)xf_savputindx,
/* 3986 */ VXI_MOVL,VXT_REG,0x50,VXT_ADDR,0,VXT_END,
/* 3992 */ VXI_CALLS,VXT_LIT,0,VXT_XFER,SIZEOF(char *) * (short int)xf_forfreeindx,VXT_END,
/* 3998 */ VXI_PUSHL,VXT_VAL,1,VXI_CALLS,VXT_LIT,1,VXT_XFER,SIZEOF(char *) * (short int)xf_fornestlvl,
/* 4006 */ VXT_END,
/* 4007 */ 343,357,350,2439,2447,2443,2706,2718,
/* 4015 */ 2712,0,0,0,464,440,431,0,
/* 4023 */ 0,427,1948,1986,1967,2587,2602,2593,
/* 4031 */ 2563,2578,2569,2455,2466,2459,2545,2556,
/* 4039 */ 2549,2491,2502,2495,2509,2520,2513,2527,
/* 4047 */ 2538,2531,2473,2484,2477,1927,1941,1934,
/* 4055 */ 364,378,371};

View File

@ -0,0 +1,419 @@
/****************************************************************
* *
* Copyright 2009 Fidelity Information Services, Inc *
* *
* This source code contains the intellectual property *
* of its copyright holder(s), and is made available *
* under a license. If you do not know the terms of *
* the license, please stop and do not read further. *
* *
****************************************************************/
#define _FILE_OFFSET_BITS 64 /* Needed to compile gpgme client progs also with large file support */
#include <stdio.h>
#include <string.h>
#include <unistd.h>
#include <stdlib.h>
#include <assert.h>
#include <sys/stat.h>
#include <errno.h>
#include <gpgme.h> /* gpgme functions */
#include <gpg-error.h> /* gcry*_err_t */
#include "gtmxc_types.h" /* xc_string, xc_status_t and other callin interfaces xc_fileid */
#include "gtmcrypt_interface.h" /* Function prototypes for gtmcrypt*.* functions */
#include "gtmcrypt_ref.h"
#include "gtmcrypt_dbk_ref.h"
#include "gtmcrypt_pk_ref.h"
#include "gtmcrypt_sym_ref.h"
int num_entries;
db_key_map *db_map_root;
db_key_map **fast_lookup_entry;
extern char err_string[ERR_STRLEN];
extern int can_prompt_passwd;
/* Cleanup the db key entries and also remove the plain text passwd stored there */
void gc_dbk_scrub_entries()
{
db_key_map *temp, *temp1;
temp = GC_DBK_GET_FIRST_ENTRY();
/* Walk through the linked list and free each member of the structure.*/
while (NULL != temp)
{
# ifdef USE_GCRYPT
if (temp->encr_key_handle)
gcry_cipher_close(temp->encr_key_handle);
if (temp->decr_key_handle)
gcry_cipher_close(temp->decr_key_handle);
# endif
temp1 = GC_DBK_GET_NEXT_ENTRY(temp);
GC_FREE_DB_KEY_MAP(temp); /* Note, this will memset the key_string to 0 before free'ing */
temp = temp1;
}
if (NULL != fast_lookup_entry)
GC_FREE(fast_lookup_entry);
}
/* Find out whether the db key file is modified since last time */
xc_status_t gc_dbk_is_db_key_file_modified()
{
struct stat stat_info;
char *gtm_dbkeys;
int status;
static time_t last_modified = 0;
GC_GETENV(gtm_dbkeys, GTM_DBKEYS, status);
if (GC_FAILURE == status)
{
GC_ENV_UNSET_ERROR(GTM_DBKEYS);
return GC_FAILURE;
}
if (0 != stat(gtm_dbkeys, &stat_info) || (last_modified != stat_info.st_mtime))
{
last_modified = stat_info.st_mtime;
return TRUE;
}
return FALSE;
}
/* Given a xc_fileid, containing a unique description of the dat file, the function searches for it's
* entry in the linked list. On unsuccessful search, returns NULL.
*/
db_key_map* gc_dbk_get_entry_by_fileid(xc_fileid_ptr_t fileid)
{
db_key_map *cur = db_map_root;
while (NULL != cur)
{
if (!cur->fileid_dirty && (!cur->sym_key_dirty) && (gtm_is_file_identical_fptr(fileid, (cur->fileid))))
break;
cur = (db_key_map *)cur->next;
}
return cur;
}
/* Given a hash of the symmetric key, the function searches for the entry in the linked list that matches with the
* given hash
*/
db_key_map* gc_dbk_get_entry_by_hash(xc_string_t *hash)
{
db_key_map *cur = db_map_root;
assert(hash);
assert(hash->length);
while (NULL != cur)
{
if (hash->length == cur->hash.length && (0 == memcmp(hash->address, cur->hash.address, hash->length)))
break;
cur = (db_key_map *)cur->next;
}
return cur;
}
dbkeyfile_line_type gc_dbk_get_line_info (char *buf, char *data)
{
dbkeyfile_line_type line_type = ERROR_LINE_INFO;
if (!memcmp(buf, DAT_LINE_INDICATOR, DAT_LINE_INDICATOR_SIZE))
{
strcpy(data, &buf[DAT_LINE_INDICATOR_SIZE]); /* The rest of the line is a file name */
if ('\n' == data[strlen(data) - 1]) data[strlen(data) - 1] = '\0';
line_type = DAT_LINE_INFO;
} else if (!memcmp(buf, KEY_LINE_INDICATOR, KEY_LINE_INDICATOR_SIZE))
{
strcpy(data, &buf[KEY_LINE_INDICATOR_SIZE]); /* The rest of the line is a file name */
if ('\n' == data[strlen(data) - 1]) data[strlen(data) - 1] = '\0';
line_type = KEY_LINE_INFO;
}
return line_type;
}
xc_status_t gc_dbk_load_gtm_dbkeys(FILE **gtm_dbkeys)
{
char *ptr, dbkeys_filename[GTM_PATH_MAX];
int status;
FILE *dbkeys_fp;
struct stat stat_buf;
GC_GETENV(ptr, GTM_DBKEYS, status);
if (GC_SUCCESS == status)
{
if (0 == strlen(ptr))
{
snprintf(err_string, ERR_STRLEN, "%s", "Environment variable gtm_dbkeys set to empty string");
return GC_FAILURE;
}
if (0 == stat(ptr, &stat_buf)) /* See if the environment variable points to a proper path */
{
if (S_ISDIR(stat_buf.st_mode)) /* if directory */
snprintf(dbkeys_filename, GTM_PATH_MAX, "%s/%s", ptr, DOT_GTM_DBKEYS);
else if (S_ISREG(stat_buf.st_mode)) /* if file */
snprintf(dbkeys_filename, GTM_PATH_MAX, "%s", ptr);
else
{
snprintf(err_string, ERR_STRLEN, "Unknown file type : %s", ptr);
return GC_FAILURE;
}
} else /* error if env variable present but couldn't stat */
{
snprintf(err_string, ERR_STRLEN, "Cannot find DB keys file - %s", ptr);
return GC_FAILURE;
}
} else /* if env variable is undefined, then look for $HOME/.gtm_dbkeys */
{
GC_GETENV(ptr, "HOME", status);
snprintf(dbkeys_filename, GTM_PATH_MAX, "%s/%s", ptr, DOT_GTM_DBKEYS);
if (0 != stat(dbkeys_filename, &stat_buf))
{
snprintf(err_string,
ERR_STRLEN,
"Environment variable gtm_dbkeys undefined. Cannot find %s/.gtm_dbkeys",
ptr);
return GC_FAILURE;
}
}
/* At this point we would have at least one form of the gtm_dbkeys in dbkeys_filename */
status = GC_SUCCESS;
if (NULL != (dbkeys_fp = fopen(dbkeys_filename, "r")))
*gtm_dbkeys = dbkeys_fp;
else
{
snprintf(err_string, ERR_STRLEN, "Cannot open DB keys file - %s", dbkeys_filename);
status = GC_FAILURE;
}
return status;
}
/* Initialize the linked list with minimal things. For each pair of entries in the db key file, load the
* file names into the linked list and validate the format of the entries. Returns error if the format is
* not the one that's expected. This is a fatal error and program will not continue on encountering this
* error. Another fatal error is the 'gtm_dbkeys' env variable not set
*/
xc_status_t gc_dbk_load_entries_from_file()
{
FILE *dbkeys_fp = NULL;
db_key_map *node = NULL;
int current_state;
int start = TRUE, count = 0, status, all_done = FALSE;
int looking_for_dat_entry = 1, looking_for_key_entry = 2;
int line_no = 0;
char *prefix = "Error parsing database key file";
char buf[GTM_PATH_MAX], data[GTM_PATH_MAX];
dbkeyfile_line_type line_type;
/* Check for $gtm_dbkeys */
if (0 != gc_dbk_load_gtm_dbkeys(&dbkeys_fp))
return GC_FAILURE;
/* Read the file and parse the contents and fill a mapping table */
/* Note the format of this dbkeys will be like this -
dat <db file1 path>
key <key file1 name>
dat <db file2 path>
key <key file2 name>
*/
/* To start with we are looking for a dat entry */
current_state = looking_for_dat_entry;
GC_DBK_SET_FIRST_ENTRY(NULL);
while (!feof(dbkeys_fp))
{
memset(buf, 0, GTM_PATH_MAX);
memset(data, 0, GTM_PATH_MAX);
/* Skip past empty lines */
while (1)
{
if (!fgets(buf, GTM_PATH_MAX, dbkeys_fp))
{
/* If EOF is reached but the line_no din't move beyond 0, it means we have no entries
* in the db key file. */
if (0 == line_no)
{
fclose(dbkeys_fp);
snprintf(err_string,
ERR_STRLEN,
"%s. %s",
prefix,
"No entries found in DB keys file.");
return GC_FAILURE;
}
/* At the end if we are looking for a key entry, then the last dat entry is unmatched*/
if (current_state == looking_for_key_entry)
{
fclose(dbkeys_fp);
snprintf(err_string,
ERR_STRLEN,
"%s. No matching KEY entry found for DAT entry at line: %d",
prefix,
line_no);
return GC_FAILURE;
}
all_done = TRUE;
break;
}
if (buf[0] != '\0' && (buf[0] != '\n')) /* Non-Empty line */
{
buf[strlen(buf) - 1] = '\0';
break;
}
else
line_no++;
}
if (all_done) break;
/* Figure out what kind of line are we going to deal with. */
line_type = gc_dbk_get_line_info(buf, data);
switch(line_type)
{
case DAT_LINE_INFO:
line_no++;
/* We should have seen a key before seeing the next dat file */
if (current_state == looking_for_key_entry && (FALSE == start))
{
fclose(dbkeys_fp);
snprintf(err_string,
ERR_STRLEN,
"%s. At line %d: No matching KEY entry found for %s",
prefix,
line_no,
buf);
return GC_FAILURE;
}
/* Now that we have seen a dat file, we will now be looking for a key entry */
current_state = looking_for_key_entry;
start = FALSE;
GC_NEW_DB_KEYMAP(node);
GC_COPY_TO_XC_STRING(&node->db_name, data, strlen(data));
node->next = (struct db_key_map*) db_map_root;
GC_DBK_SET_FIRST_ENTRY(node);
break;
case KEY_LINE_INFO:
line_no++;
/* We should have seen a dat file before seeing a key file */
if (!node && (current_state == looking_for_dat_entry))
{
fclose(dbkeys_fp);
snprintf(err_string,
ERR_STRLEN,
"%s. At line %d: No matching DAT entry found for %s",
prefix,
line_no,
buf);
return GC_FAILURE;
}
/* Now that we have seen a key file, we will now be looking for a dat entry */
current_state = looking_for_dat_entry;
num_entries++;
GC_COPY_TO_XC_STRING(&node->key_filename, data, strlen(data));
break;
default:
line_no++;
fclose(dbkeys_fp);
snprintf(err_string,
ERR_STRLEN,
"%s. At line %d: %s does not start with 'dat '/'key '",
prefix,
line_no,
buf);
return GC_FAILURE;
}
}
GC_MALLOC(fast_lookup_entry, (SIZEOF(fast_lookup_entry) * num_entries), db_key_map*);
node = GC_DBK_GET_FIRST_ENTRY();
while (NULL != node)
{
node->index = count;
fast_lookup_entry[count] = node;
count++;
node = GC_DBK_GET_NEXT_ENTRY(node);
}
assert(count == num_entries);
fclose(dbkeys_fp);
return GC_SUCCESS;
}
xc_status_t gc_dbk_fill_sym_key_and_hash(xc_fileid_ptr_t req_fileid, char *req_hash)
{
db_key_map *cur;
int status, concerns_current_file;
xc_fileid_ptr_t db_fileid;
cur = GC_DBK_GET_FIRST_ENTRY();
while (NULL != cur)
{
db_fileid = NULL;
if (TRUE == cur->fileid_dirty)
{
if (TRUE == gtm_filename_to_id_fptr(&(cur->db_name), &db_fileid))
{
cur->fileid_dirty = FALSE;
cur->fileid = db_fileid;
}
}
if (TRUE == cur->sym_key_dirty) /* Need to fill sym key value */
{
/* Before decrypting the key, let's see if the gtm_passwd in the environment has changed since
* the last time we read from the environment. This way if the user had originally entered a wrong
* password and if he is in MUMPS and changes the password through a external call then we should
* be using the new password rather than the old one which might still be hanging in the environment. */
gc_pk_crypt_prompt_passwd_if_needed(can_prompt_passwd);
GC_PK_GET_DECRYPTED_KEY(cur->key_string, status);
/* If we failed because of a gtm_passwd being wrong we wouldn't want to continue any further although it
* might not concern for the current file. */
if (GPG_ERR_BAD_PASSPHRASE == status)
return GC_FAILURE;
concerns_current_file = (NULL != req_fileid && (gtm_is_file_identical_fptr(cur->fileid, req_fileid)));
/* Eventhough we may have an encountered error in the above decryption, we report only when it is concerned
* with the current dat file being used. For other files, we silently ignore the error, with a hope that by
* the time the database file is accessed, db key file would have been updated appropriately by the user.
*/
if (0 != status && concerns_current_file)
return GC_FAILURE;
/* It could be possible that the decryption din't return any error but plain_text_length happens to
* be zero. So, we verify it and return error in case the length is zero. Again we make sure that we return
* the error only when it concerned with the current dat file.
*/
if (0 == cur->key_string.length && concerns_current_file)
{
snprintf(err_string, ERR_STRLEN, "Symmetric key %s found to be empty", cur->key_filename.address);
return GC_FAILURE;
}
/* If we fall through here, it means that we have encountered an error for a database which is not of
* concern at this moment. So, we continue with the next database. */
if (0 != status)
{
cur = GC_DBK_GET_NEXT_ENTRY(cur);
continue;
}
/* If everything is fine, compute the hash for the key */
GC_PK_COMPUTE_HASH(cur->hash, cur->key_string);
GC_SYM_CREATE_HANDLES(cur);
cur->sym_key_dirty = FALSE;
/* If we have found a matching entry for the hash/fileid that we requested for, return immediately with
* GC_SUCCESS */
if (concerns_current_file
|| (NULL != req_hash && (0 == memcmp(cur->hash.address, req_hash, GTMCRYPT_HASH_LEN))))
return GC_SUCCESS;
}
cur = GC_DBK_GET_NEXT_ENTRY(cur);
}
return GC_SUCCESS;
}
void gc_dbk_get_hash(db_key_map *entry, xc_string_t *hash)
{
/*Make sure the reference block that is being passed is already allocated */
assert(hash->address);
assert(NULL != entry);
memcpy(hash->address, entry->hash.address, GTMCRYPT_HASH_LEN);
hash->length = GTMCRYPT_HASH_LEN;
}

View File

@ -0,0 +1,117 @@
/****************************************************************
* *
* Copyright 2009, 2010 Fidelity Information Services, Inc *
* *
* This source code contains the intellectual property *
* of its copyright holder(s), and is made available *
* under a license. If you do not know the terms of *
* the license, please stop and do not read further. *
* *
****************************************************************/
#ifndef GTMCRYPT_DBK_REF_H
#define GTMCRYPT_DBK_REF_H
typedef struct
{
xc_string_t db_name, key_filename; /* name of the database and corresponding key found in the db key file */
xc_string_t key_string, hash; /* plain text key and it's hash */
xc_fileid_ptr_t fileid; /* if valid, unique file id representation of the database path */
int fileid_dirty, sym_key_dirty; /* indicates if the db and the key file are valid accessible path */
int index; /* A positive integer (initialized to -1) indicating the ith entry in the db key
* file. This value is returned to the caller and subsequently passed to the
* plugin to get the key for the corresponding database. */
struct db_key_map *next; /* Pointer to the next entry in the linked list */
crypt_key_t encr_key_handle, decr_key_handle; /* Pointer to the actual key handles typedef'ed to the underlying
* encryption library. */
}db_key_map;
void gc_dbk_scrub_entries(void);
xc_status_t gc_dbk_is_db_key_file_modified(void);
db_key_map* gc_dbk_get_entry_by_fileid(xc_fileid_ptr_t fileid);
db_key_map* gc_dbk_get_entry_by_hash(xc_string_t *hash);
dbkeyfile_line_type gc_dbk_get_line_info (char *buf, char *data);
xc_status_t gc_dbk_load_gtm_dbkeys(FILE **gtm_dbkeys);
xc_status_t gc_dbk_load_entries_from_file(void);
xc_status_t gc_dbk_fill_sym_key_and_hash(xc_fileid_ptr_t req_fileid, char *req_hash);
void gc_dbk_get_hash(db_key_map *entry, xc_string_t *hash);
#define GC_FREE_DB_KEY_MAP(X) \
{ \
GC_FREE((X)->db_name.address); \
GC_FREE((X)->key_filename.address); \
memset((X)->key_string.address, 0, GTM_KEY_MAX);\
GC_FREE((X)->key_string.address); \
GC_FREE((X)->hash.address); \
gtm_xcfileid_free_fptr((X)->fileid); \
GC_FREE(X); \
}
#define GC_NEW_DB_KEYMAP(X) \
{ \
GC_MALLOC(X, SIZEOF(db_key_map), db_key_map); \
memset(X, 0, SIZEOF(db_key_map)); \
GC_MALLOC(X->db_name.address, GTM_PATH_MAX, char); \
memset((X)->db_name.address, 0, GTM_PATH_MAX); \
GC_MALLOC(X->key_filename.address, GTM_PATH_MAX, char); \
memset((X)->key_filename.address, 0, GTM_PATH_MAX); \
GC_MALLOC(X->key_string.address, GTM_PATH_MAX, char); \
memset((X)->key_string.address, 0, GTM_KEY_MAX); \
GC_MALLOC(X->hash.address, GTMCRYPT_HASH_LEN, char); \
memset((X)->hash.address, 0, GTMCRYPT_HASH_LEN); \
(X)->fileid_dirty = TRUE; \
(X)->sym_key_dirty = TRUE; \
(X)->fileid = NULL; \
(X)->index = 0; \
}
#define GC_DBK_LOAD_KEY_FILE \
{ \
if (0 != gc_dbk_load_entries_from_file()) \
return GC_FAILURE; \
}
/* After the preliminary search, if we haven't found our entry in the in-memory linked list for the
* given hash/fileid, we try reloading the db key file(if it has been changed since last time) and then
* we re-organize our in-memory linked list and try to search again.
*/
#define GC_DBK_RELOAD_IF_NEEDED(entry, RC, fileid, req_hash) \
{ \
if (NULL == entry) \
{ \
if (TRUE == gc_dbk_is_db_key_file_modified()) \
GC_DBK_LOAD_KEY_FILE; \
RC = gc_dbk_fill_sym_key_and_hash(fileid, req_hash); \
} \
}
#define GC_DBK_GET_ENTRY_FROM_HANDLE(handle, entry, ret) \
{ \
int idx; \
\
idx = (int)handle; \
if (idx < 0 || (idx > num_entries)) \
{ \
snprintf(err_string, ERR_STRLEN, "%s", "Encryption handle corrupted."); \
entry = NULL; \
return ret; \
} else \
entry = (db_key_map *)fast_lookup_entry[idx]; \
}
#define GC_DBK_FILENAME_TO_ID(filename, fileid) \
{ \
if (TRUE != gtm_filename_to_id_fptr(filename, &fileid)) \
{ \
snprintf(err_string, ERR_STRLEN, "database file %s not found", filename->address); \
return GC_FAILURE; \
} \
}
#define GC_DBK_SET_FIRST_ENTRY(cur) db_map_root = (db_key_map *)cur
#define GC_DBK_GET_FIRST_ENTRY() db_map_root
#define GC_DBK_GET_NEXT_ENTRY(cur) (db_key_map *) cur->next
#endif /* GTMCRYPT_DBK_REF_H */

View File

@ -0,0 +1,24 @@
/****************************************************************
* *
* Copyright 2009 Fidelity Information Services, Inc *
* *
* This source code contains the intellectual property *
* of its copyright holder(s), and is made available *
* under a license If you do not know the terms of *
* the license, please stop and do not read further *
* *
y***************************************************************/
#ifndef GTMCRYPT_INTERFACE_H
#define GTMCRYPT_INTERFACE_H
xc_status_t gtmcrypt_init(int);
xc_status_t gtmcrypt_close(void);
xc_status_t gtmcrypt_hash_gen(gtmcrypt_key_t, xc_string_t *);
xc_status_t gtmcrypt_encode(gtmcrypt_key_t, xc_string_t *, xc_string_t *);
xc_status_t gtmcrypt_decode(gtmcrypt_key_t, xc_string_t *, xc_string_t *);
xc_status_t gtmcrypt_getkey_by_hash(xc_string_t *, gtmcrypt_key_t *);
xc_status_t gtmcrypt_getkey_by_name(xc_string_t *, gtmcrypt_key_t *);
char *gtmcrypt_strerror(void);
#endif /* GTMCRYPT_INTERFACE_H */

View File

@ -0,0 +1,382 @@
/****************************************************************
* *
* Copyright 2009, 2010 Fidelity Information Services, Inc *
* *
* This source code contains the intellectual property *
* of its copyright holder(s), and is made available *
* under a license. If you do not know the terms of *
* the license, please stop and do not read further. *
* *
****************************************************************/
#define _FILE_OFFSET_BITS 64 /* Needed to compile gpgme client progs also with large file support */
#include <stdio.h>
#include <string.h>
#include <unistd.h>
#include <stdlib.h>
#include <assert.h>
#include <sys/stat.h>
#include <sys/types.h>
#include <fcntl.h>
#include <errno.h>
#include <gpgme.h> /* gpgme functions */
#include <gpg-error.h> /* gcry*_err_t */
#include <dlfcn.h>
#include "gtmxc_types.h" /* xc_string, xc_status_t and other callin interfaces xc_fileid */
#include "gtmcrypt_interface.h" /* Function prototypes for gtmcrypt*.* functions */
#include "gtmcrypt_ref.h"
#include "gtmcrypt_pk_ref.h"
static char *gtm_passwd;
static char *gtm_passwd_env;
int can_prompt_passwd;
gpgme_ctx_t pk_crypt_ctx;
extern char err_string[ERR_STRLEN];
/* Take a masked/unmasked passwd and convert it to the other form by doing an XOR operation.
* MASKING:
* The original gtm_passwd value is XOR'ed with the inode number of mumps executable and the
* the value of the env variable $USER (which contains the username of the current user logged in).
* This information is then converted to the hex form for easy viewing and set into the environment
* UNMASKING:
* The gtm_passwd set in the environment is un hexed (after masking, the passwd is set in the hex
* form). This gtm_passwd value is then XOR'ed with the inode number of the executable and the
* env variable $USER (which contains the username of the current user). This information is then
* stored in the gtm_passwd variable for future access. Note the environment variable ($gtm_passwd) still
* contains only the masked password and hence safety of the passwd is still guarenteed.
Note that always, if the username and(or) the inode number is lesser than the length of the un hexed gtm_passwd,
the position of their values are left and right justified with respect to the gtm_passwd value. A typical example
is shown below.
* G T M P A S S W D */
/* ^ ^ ^ ^ ^ ^ ^ ^ ^ */
/* U S E R 0 0 0 0 0 */
/* ^ ^ ^ ^ ^ ^ ^ ^ ^ */
/* 0 0 0 0 I N O D E */
/* ----------------- */
int gc_pk_mask_unmask_passwd(char *in, char *out, int len)
{
char *ptr;
char tmp[GTM_PASSPHRASE_MAX], inode[GTM_PASSPHRASE_MAX], user[GTM_PASSPHRASE_MAX], mumps_ex[GTM_PATH_MAX];
int passwd_len, ilen, status, i;
struct stat stat_info;
passwd_len = len < GTM_PASSPHRASE_MAX ? len : GTM_PASSPHRASE_MAX;
memset(inode, 0, passwd_len);
memset(user, 0, passwd_len);
memset(mumps_ex, 0, GTM_PATH_MAX);
GC_GETENV(ptr, "USER", status);
if (GC_SUCCESS == status)
{
strncpy(user, ptr, passwd_len);
GC_GETENV(ptr, "gtm_dist", status);
if (GC_SUCCESS == status)
{
sprintf(mumps_ex, "%s/%s", ptr, "mumps");
if (0 == stat(mumps_ex, &stat_info))
{
sprintf(tmp, "%ld", (long) stat_info.st_ino);
ilen = (int)strlen(tmp);
if (ilen < passwd_len)
strncpy(inode + (passwd_len - ilen), tmp, ilen);
else
strncpy(inode, tmp, passwd_len);
} else
{
sprintf(err_string, "Cannot find MUMPS executable in %s", ptr);
return GC_FAILURE;
}
for (i = 0; i < passwd_len; i++)
out[i] = in[i] ^ inode[i] ^ user[i];
return GC_SUCCESS;
} else
GC_ENV_UNSET_ERROR("gtm_dist");
}
GC_ENV_UNSET_ERROR("USER");
return GC_FAILURE;
}
int gc_pk_mask_unmask_passwd_interlude(int nparm, gtm_string_t *in, gtm_string_t *out, int len)
{
out->length=len;
return gc_pk_mask_unmask_passwd(in->address, out->address, len);
}
void gc_pk_scrub_passwd()
{
/* Nullify the key strings, so that any generated cores will not contain the unencrypted keys */
memset(gtm_passwd, 0, strlen(gtm_passwd));
/* Free gtm_passwd and gtm_passwd_env variables */
if (NULL != gtm_passwd)
GC_FREE(gtm_passwd);
if (NULL != gtm_passwd_env)
GC_FREE(gtm_passwd_env);
/* Finally release the gpgme context */
if (NULL != pk_crypt_ctx)
gpgme_release(pk_crypt_ctx);
}
/* Loads the GTMCI variable with the path of the gtmcrypt.tab which will be placed in gtm_dist folder at build time.
* Here we assume that the tab file be in $gtm_dist/plugin/gtmcrypt
*/
void gc_pk_crypt_load_gtmci_env()
{
const char *gtm_dist_value;
const char *gtmcrypt_tab_file = "gtmcrypt.tab"; /* Name of the tab file */
static char gtmcrypt_tab_path[TAB_NAME_MAX]; /* Needs to be in scope always */
gtm_dist_value = getenv("gtm_dist");
assert(NULL != gtm_dist_value);
assert(0 != strlen(gtm_dist_value));
sprintf(gtmcrypt_tab_path, "%s/%s/%s", gtm_dist_value, "plugin/gtmcrypt", gtmcrypt_tab_file);
setenv(GTMCI, gtmcrypt_tab_path, TRUE);
}
/* The following function checks if gtm_passwd is already set. If gtm_passwd is not set in the env, it's a serious
* error condition. We return back immediately. If it's set to empty string, we prompt for passwd immediately. The
* current implementation of password prompting is done via a mumps call-in to %GETPASS.
*/
xc_status_t gc_pk_crypt_prompt_passwd_if_needed(int prompt_passwd)
{
/* Name of the mumps password routine that will be called. */
const char *password_routine = "getpass";
/* Points to the value that was held in GTMCI prior to modification. */
char *save_gtmci, tgtm_passwd[GTM_PASSPHRASE_MAX];
char *lgtm_passwd;
int status, len;
gtm_int_t pass_len = GTM_PASSPHRASE_MAX;
can_prompt_passwd = prompt_passwd;
GC_GETENV(lgtm_passwd, GTM_PASSWD, status);
/* This is an error condition. We have hit a encrypted database but the env doesn't have gtm_passwd set. */
if (0 != status)
{
GC_ENV_UNSET_ERROR(GTM_PASSWD);
return GC_FAILURE;
}
/* If the masked password in the environment is same as we have in memory then it means that the password
* has not been changed and so the actual value in the gtm_passwd is still good to use. */
if (NULL != gtm_passwd_env && (0 == strcmp(gtm_passwd_env, lgtm_passwd)))
return GC_SUCCESS;
/* If the password is set to an appropriate value, then we know for sure it's in it's masked form. So, we unmask it
* and set it in the global variable and return to the caller. */
if (0 < (len = (int)strlen(lgtm_passwd)))
{
if (gtm_passwd)
GC_FREE(gtm_passwd);
GC_MALLOC(gtm_passwd, len / 2 + 1, char);
memset(gtm_passwd, 0, len / 2 + 1);
GC_UNHEX(lgtm_passwd, gtm_passwd, len);
status = gc_pk_mask_unmask_passwd(gtm_passwd, gtm_passwd, len / 2);
if (GC_SUCCESS == status)
{
/* Now that we have unmasked the gtm_passwd in the environment
* store the masked version in gtm_passwd_env so that future
* calls to this function can make use of this and return early
* if we find no change between the one in the environment and
* the one in the memory */
if (NULL != gtm_passwd_env)
GC_FREE(gtm_passwd_env);
GC_MALLOC(gtm_passwd_env, strlen(lgtm_passwd) + 1, char);
strcpy(gtm_passwd_env, lgtm_passwd);
}
return status;
} else if (!prompt_passwd)
{
/* If we are here, it means that the caller of the plugin library was not MUMPS (may be MUPIP, DSE and LKE).
* For the utility programs, we expect the password to be set in the environment to an appropriate masked
* form. If not, it's an error and we return the appropriate error message. */
strcpy(err_string, PASSWD_EMPTY);
return GC_FAILURE;
}
/* Only if the gtm_passwd is set to empty string, we prompt the user for password */
GC_MALLOC(gtm_passwd, GTM_PASSPHRASE_MAX, char);
memset(gtm_passwd, 0, GTM_PASSPHRASE_MAX);
save_gtmci = getenv(GTMCI);
gc_pk_crypt_load_gtmci_env();
status = gtm_ci_fptr(password_routine, gtm_passwd, pass_len);
if (0 != status)
{
gtm_zstatus_fptr(err_string, ERR_STRLEN);
return GC_FAILURE;
}
/* Restore the GTMCI variable */
if (NULL != save_gtmci) /* To make sure we don't set an environment variable as NULL */
setenv(GTMCI, save_gtmci, 1);
/* After applying a minimal encryption, we set it to the environment variable */
GC_MALLOC(lgtm_passwd, strlen(gtm_passwd) * 2 + 1, char);
gc_pk_mask_unmask_passwd(gtm_passwd, tgtm_passwd, (int)strlen(gtm_passwd));
GC_HEX(tgtm_passwd, lgtm_passwd, strlen(gtm_passwd) * 2);
setenv("gtm_passwd", lgtm_passwd, TRUE); /* Note that we currently do not free 'gtm_passwd', even if it was
* allocated above, as it needs to be in the env buffer
*/
return GC_SUCCESS;
}
/* This function is called whenever gpg needs the passphrase with which the secret key is encrypted. In this case, the passphrase
* is obtained from the ENVIRONMENT VARIABLE - $gtm_passwd or by invoking the mumps engine during the "gtmcrypt_init()".
* In either ways, it's guaranteed that when this function is called, the passphrase is already set in the global variable.
* In either ways, it's guaranteed that when this function is called, the passphrase is already set in the global variable.
*/
int gc_pk_crypt_passphrase_callback(void *opaque, const char *uid_hint,
const char *passphrase_info, int last_was_bad,
int fd)
{
assert(0 != fd);
assert(NULL != gtm_passwd);
/* This is just being cautious. We would have thrown the appropriate error message
* if gtm_passwd have been zero length'ed one.
*/
assert(0 != strlen(gtm_passwd));
write(fd, gtm_passwd, strlen(gtm_passwd));
write(fd, "\n", 1);
return 0;
}
/* Given the structure that holds the plain data, this function reads through the structure and retrieves the plain text. We
* also return the number of bytes actually read from the structure.
*/
int gc_pk_crypt_retrieve_plain_text(gpgme_data_t plain_data, char *plain_text)
{
int ret;
assert(NULL != plain_text);
/* Clear the temporary buffer */
memset(plain_text, 0, GTM_KEY_MAX);
gpgme_data_seek(plain_data, 0, SEEK_SET);
ret = (int)gpgme_data_read(plain_data, plain_text, GTM_KEY_MAX);
return ret;
}
/* This is currently necessary to work around what seems to be a gpgme issue in not clearing the plaintext keys
* from the C stack (shows up in a core dump otherwise). When gpgme is fixed, this code can be removed.
* The size of lclarray (8K) is determined purely from experimentation on all platforms.
*/
int gc_pk_scrub_plaintext_keys_from_c_stack()
{
char lclarray[8192];
memset(lclarray, 0, SIZEOF(lclarray));
return 0;
}
/* This function tries to decrypt the cipher file (the file containing the symmetric key with which the database is encrypted).
* It's assumed that the context is initialized and is set with the appropriate passphrase callback. The cipher_file
* should contain the fully qualified path of the encrypted database key file. Also, plain text is supposed to be allocated with
* sufficient space to hold the decrypted text.
*/
gpgme_error_t gc_pk_get_decrypted_key(const char *cipher_file, char *plain_text, int *plain_text_length)
{
gpgme_error_t err;
gpgme_data_t cipher_data = NULL, plain_data = NULL;
xc_status_t ret_status;
gpg_err_code_t ecode;
char null_buffer[GTM_KEY_MAX];
assert(NULL != cipher_file);
assert(NULL != plain_text);
assert(NULL != pk_crypt_ctx);
assert(0 != strlen(cipher_file));
/* Convert the cipher content in the cipher file into
* in-memory content. This in-memory content is stored
* in gpgme_data_t structure. */
err = gpgme_data_new_from_file(&cipher_data, cipher_file, 1);
if (!err)
{
err = gpgme_data_new(&plain_data);
if (!err)
{ /* Try decrypting the cipher content with the context.
* The decrypted content will also be stored in gpgme_data_t structure.
*/
err = gpgme_op_decrypt(pk_crypt_ctx, cipher_data, plain_data);
if (!err) /* Once decrypted, the plain text has to be obtained from the plain_data structure. */
*plain_text_length = gc_pk_crypt_retrieve_plain_text(plain_data, plain_text);
gc_pk_scrub_plaintext_keys_from_c_stack();
}
}
ecode = gpgme_err_code(err);
if (0 != ecode)
{
switch(ecode)
{
case GPG_ERR_BAD_PASSPHRASE:
snprintf(err_string, ERR_STRLEN, "%s", "Incorrect password");
break;
case GPG_ERR_ENOENT:
snprintf(err_string, ERR_STRLEN, "encryption key file %s not found", cipher_file);
break;
default:
snprintf(err_string, ERR_STRLEN, "%s", gpgme_strerror(err));
break;
}
}
if (NULL != plain_data)
{ /* scrub plaintext data before releasing it */
assert(GTM_KEY_MAX == SIZEOF(null_buffer));
memset(null_buffer, 0, GTM_KEY_MAX);
gpgme_data_write(plain_data, null_buffer, GTM_KEY_MAX);
gpgme_data_release(plain_data);
}
if (NULL != cipher_data)
gpgme_data_release(cipher_data);
return ecode;
}
int gc_pk_gpghome_has_permissions()
{
char filename[GTM_PATH_MAX], *tmp_ptr = NULL;
int gnupghome_set, status, fd;
/* See if GNUPGHOME is set in the environment */
GC_GETENV(tmp_ptr, GNUPGHOME, status);
if (GC_SUCCESS != status)
{
gnupghome_set = FALSE;
GC_GETENV(tmp_ptr, "HOME", status);
if (GC_SUCCESS != status)
{
GC_ENV_UNSET_ERROR("HOME");
return GC_FAILURE;
}
/* If GNUPGHOME is not set, we choose the filename as $HOME/.gnupg */
snprintf(filename, GTM_PATH_MAX, "%s/%s", tmp_ptr, DOT_GNUPG);
} else
{
gnupghome_set = TRUE;
/* If GNUPGHOME is set, then we choose the path pointed by GNUPGHOME as the
* directory containing the public keys and private keys whose permissions we are
* interested in. */
strcpy(filename, tmp_ptr);
}
/* At this point, we are sure that the filename is pointing to the appropriate directory containing the public/private
* keys. If not, then we had encountered an error and would have returned back to the caller. */
if (-1 != (fd = open(filename, O_RDONLY)))
{
close(fd);
return GC_SUCCESS;
}
/* If we don't have appropriate read permissions then we report the error accordingly. */
if (EACCES == errno)
{
if (gnupghome_set)
snprintf(err_string, ERR_STRLEN, "%s", "No read permissions on $GNUPGHOME");
else
snprintf(err_string, ERR_STRLEN, "%s", "No read permissions on $HOME/.gnupg");
}
close(fd);
return GC_FAILURE;
}

View File

@ -0,0 +1,115 @@
/****************************************************************
* *
* Copyright 2009, 2010 Fidelity Information Services, Inc *
* *
* This source code contains the intellectual property *
* of its copyright holder(s), and is made available *
* under a license. If you do not know the terms of *
* the license, please stop and do not read further. *
* *
****************************************************************/
#ifndef GTMCRYPT_PK_REF_H
#define GTMCRYPT_PK_REF_H
int gc_pk_mask_unmask_passwd(char *in, char *out, int len);
int gc_pk_mask_unmask_passwd_interlude(int nparm, gtm_string_t *in, gtm_string_t *out, int len);
void gc_pk_scrub_passwd();
void gc_pk_crypt_load_gtmci_env();
xc_status_t gc_pk_crypt_prompt_passwd_if_needed(int prompt_passwd);
int gc_pk_crypt_passphrase_callback(void *opaque,
const char *uid_hint,
const char *passphrase_info,
int last_was_bad,
int fd);
int gc_pk_crypt_retrieve_plain_text(gpgme_data_t plain_data, char *plain_text);
gpgme_error_t gc_pk_get_decrypted_key(const char *cipher_file, char *plain_text, int *plain_text_length);
int gc_pk_mask_unmask_passwd(char *in, char *out, int len);
void gc_pk_scrub_passwd(void);
void gc_pk_crypt_load_gtmci_env(void);
int gc_pk_scrub_plaintext_keys_from_c_stack(void);
int gc_pk_gpghome_has_permissions(void);
/* Public key cryptography related macros */
#define GC_PK_INIT \
{ \
gpgme_error_t err; \
\
gpgme_check_version(NULL); /* This initializes the gpgme engine. */ \
err = gpgme_new(&pk_crypt_ctx); \
if (!err) \
{ \
err = gpgme_set_protocol(pk_crypt_ctx, GPGME_PROTOCOL_OpenPGP); \
if (!err) \
{ \
gpgme_set_passphrase_cb(pk_crypt_ctx, \
(gpgme_passphrase_cb_t) gc_pk_crypt_passphrase_callback, \
NULL); \
memset(err_string, 0, ERR_STRLEN); \
} \
} \
if (err) \
{ \
pk_crypt_ctx = NULL; \
snprintf(err_string, \
ERR_STRLEN, \
"Error initializing GpgME: %s/%s", \
gpgme_strsource(err), \
gpgme_strerror(err)); \
return GC_FAILURE; \
} \
}
#define GC_PK_PROMPT_PASSWD(prompt_passwd) \
{ \
if (0 != gc_pk_crypt_prompt_passwd_if_needed(prompt_passwd)) \
return GC_FAILURE; \
}
#define GC_PK_GET_DECRYPTED_KEY(key_string, status) \
{ \
int plain_text_length; \
char decrypted_key[GTM_KEY_MAX]; \
\
memset(decrypted_key, 0, GTM_KEY_MAX); \
status = gc_pk_get_decrypted_key(cur->key_filename.address, decrypted_key, &plain_text_length); \
\
if (0 == status) \
{ \
memcpy(key_string.address, decrypted_key, plain_text_length); \
key_string.length = plain_text_length; \
memset(decrypted_key, 0, GTM_KEY_MAX); \
} \
}
#define GC_PK_APPEND_UNIQ_STRING(in_buff, key_string) \
{ \
memcpy(in_buff, (key_string).address, (key_string).length); \
memcpy(in_buff + (key_string).length, UNIQ_ENC_PARAM_STRING, UNIQ_ENC_PARAM_LEN); \
}
#ifdef USE_OPENSSL
#define GC_PK_COMPUTE_HASH(hash, key_string) \
{ \
char in_buff[HASH_INPUT_BUFF_LEN]; \
\
GC_PK_APPEND_UNIQ_STRING(in_buff, key_string); \
EVP_Digest(in_buff, HASH_INPUT_BUFF_LEN, (unsigned char *)((hash).address), NULL, \
EVP_sha512(), NULL); \
(hash).length = GTMCRYPT_HASH_LEN; \
memset(in_buff, 0, HASH_INPUT_BUFF_LEN); \
}
#else
#define GC_PK_COMPUTE_HASH(hash, key_string) \
{ \
char in_buff[HASH_INPUT_BUFF_LEN]; \
\
GC_PK_APPEND_UNIQ_STRING(in_buff, key_string); \
GC_SYM_INIT; \
gcry_md_hash_buffer(GCRY_MD_SHA512, (hash).address, in_buff, HASH_INPUT_BUFF_LEN); \
(hash).length = GTMCRYPT_HASH_LEN; \
memset(in_buff, 0, HASH_INPUT_BUFF_LEN); \
}
#endif
#endif /* GTMCRYPT_PK_REF_H */

View File

@ -0,0 +1,251 @@
/****************************************************************
* *
* Copyright 2009 Fidelity Information Services, Inc *
* *
* This source code contains the intellectual property *
* of its copyright holder(s), and is made available *
* under a license. If you do not know the terms of *
* the license, please stop and do not read further. *
* *
****************************************************************/
#define _FILE_OFFSET_BITS 64 /* Needed to compile gpgme client progs also with large file support */
#include <stdio.h>
#include <string.h>
#include <unistd.h>
#include <stdlib.h>
#include <dlfcn.h>
#include <assert.h>
#include <sys/stat.h>
#include <errno.h>
#include <gpgme.h> /* gpgme functions */
#include <gpg-error.h> /* gcry*_err_t */
#include "gtmxc_types.h" /* xc_string, xc_status_t and other callin interfaces xc_fileid */
#include "gtmcrypt_interface.h" /* Function prototypes for gtmcrypt*.* functions */
#include "gtmcrypt_ref.h"
#include "gtmcrypt_dbk_ref.h"
#include "gtmcrypt_pk_ref.h"
#include "gtmcrypt_sym_ref.h"
#ifdef __MVS__
#define GTM_DIST "gtm_dist"
#define GTMSHR_IMAGENAME "libgtmshr.dll"
#endif
char err_string[ERR_STRLEN];
int gtmcrypt_inited = FALSE, num_entries;
db_key_map *db_map_root;
db_key_map **fast_lookup_entry = NULL;
extern gpgme_ctx_t pk_crypt_ctx;
/* ==================================================================================== */
/* Plugin API implementations */
/* ==================================================================================== */
char* gtmcrypt_strerror()
{
return err_string;
}
/* Initialize the encryption environment. Note: If any of the following macros fail, the error return happens within the macro. */
xc_status_t gc_init_interface(int prompt_passwd)
{
/*
* zOS is special when it comes to dynamic linking.
* (1). Building DLL with UNRESOLVED symbols
* =========================================
* Unlike other Unix platforms, on zOS DLL cannot be built having unresolved symbols and expecting them to get resolved
* by the loader.
* In this particular scenario we have symbols gtm_malloc, gtm_is_file_identical, gtm_free, gtm_filename_to_id and
* gtm_xcfileid_free that are part of mupip executable.
* As an workaround we are using function pointers to call into the interface functions so that we don't have an link-time
* errors.
* At runtime we do an dlopen with NULL which returns handle to global space and dlsym sets the function pointers to point to
* the correct functions at runtime.
*
* (2). DLSYM on symbols that are already resolved from another DLL
* ================================================================
* When mumps calls into libgtmcrypt it has above mentioned symbols already resolved from libgtmshr.dll.
* On zOS, when we try to DLSYM using the handle returned by DLOPEN(NULL,..), DLSYM crashes while trying to find symbols
* that are already loaded from another DLL(libgtmshr.dll).
* As an work around we dlopen libgtmshr.dll when called from MUMPS.
*/
#ifdef __MVS__
void *handle = NULL;
const char *gtm_dist;
char gtmshr_file[GTM_PATH_MAX];
gtm_dist = getenv(GTM_DIST);
snprintf(gtmshr_file, GTM_PATH_MAX, "%s/%s", gtm_dist, GTMSHR_IMAGENAME);
/*
* prompt_passwd = TRUE implies plugin is invoked from MUMPS. We need to dlopen libgtmshr when invoked from MUMPS.
* Please refer comment 2) above.
*/
if (prompt_passwd)
handle = dlopen(gtmshr_file, GC_FLAGS);
else
handle = dlopen(NULL, GC_FLAGS);
if (NULL == handle)
{
snprintf(err_string, ERR_STRLEN, "%s", "Unable to resolve GT.M interface functions");
return GC_FAILURE;
}
DLSYM_ERR_AND_EXIT(gtm_is_file_identical_fptr_t, gtm_is_file_identical_fptr, GTM_IS_FILE_IDENTICAL_FUNC);
DLSYM_ERR_AND_EXIT(gtm_malloc_fptr_t, gtm_malloc_fptr, GTM_MALLOC_FUNC);
DLSYM_ERR_AND_EXIT(gtm_free_fptr_t, gtm_free_fptr, GTM_FREE_FUNC);
DLSYM_ERR_AND_EXIT(gtm_filename_to_id_fptr_t, gtm_filename_to_id_fptr, GTM_FILENAME_TO_ID_FUNC);
DLSYM_ERR_AND_EXIT(gtm_ci_fptr_t, gtm_ci_fptr, GTM_CI_FUNC);
DLSYM_ERR_AND_EXIT(gtm_zstatus_fptr_t, gtm_zstatus_fptr, GTM_ZSTATUS_FUNC);
DLSYM_ERR_AND_EXIT(gtm_xcfileid_free_fptr_t, gtm_xcfileid_free_fptr, GTM_XCFILEID_FREE_FUNC);
#else
gtm_is_file_identical_fptr = &gtm_is_file_identical;
gtm_malloc_fptr = &gtm_malloc;
gtm_free_fptr = &gtm_free;
gtm_filename_to_id_fptr = &gtm_filename_to_id;
gtm_ci_fptr = &gtm_ci;
gtm_zstatus_fptr = &gtm_zstatus;
gtm_xcfileid_free_fptr = &gtm_xcfileid_free;
#endif
return GC_SUCCESS;
}
xc_status_t gtmcrypt_init(int prompt_passwd)
{
if (GC_SUCCESS != gc_init_interface(prompt_passwd))
return GC_FAILURE;
GC_IF_INITED_RETURN;
GC_PK_INIT;
GC_PK_PROMPT_PASSWD(prompt_passwd)
GC_SET_INITED;
return GC_SUCCESS;
}
/* Note: If any of the following macros fail, the error return happens within the macro. */
xc_status_t gtmcrypt_getkey_by_name(xc_string_t *filename, gtmcrypt_key_t *handle)
{
xc_fileid_ptr_t fileid = NULL;
db_key_map *entry;
xc_status_t status = GC_SUCCESS;
GC_VERIFY_INITED;
*handle = INVALID_HANDLE;
GC_DBK_FILENAME_TO_ID(filename, fileid);
entry = gc_dbk_get_entry_by_fileid(fileid);
/* If the load below failed, don't continue */
GC_DBK_RELOAD_IF_NEEDED(entry, status, fileid, NULL);
if (0 == status)
{
entry = gc_dbk_get_entry_by_fileid(fileid);
if (NULL == entry)
{
snprintf(err_string,
ERR_STRLEN,
"database file %s missing in DB keys file or does not exist",
filename->address);
return GC_FAILURE;
}
*handle = entry->index;
}
return status;
}
/* Note: If any of the following macros fail, the error return happens within the macro. */
xc_status_t gtmcrypt_getkey_by_hash(xc_string_t *hash, gtmcrypt_key_t *handle)
{
db_key_map *entry;
xc_status_t status = GC_SUCCESS;
int i, err_caused_by_gpg;
char save_err[ERR_STRLEN], hex_buff[GTMCRYPT_HASH_HEX_LEN + 1];
char *gpg_msg = "Verify encrypted key file and your GNUPGHOME settings";
char *correct_key_msg = "Verify encryption key in DB keys file";
char *alert_msg;
*handle = INVALID_HANDLE;
GC_VERIFY_INITED;
entry = gc_dbk_get_entry_by_hash(hash);
/* If the load below failed, don't continue */
GC_DBK_RELOAD_IF_NEEDED(entry, status, NULL, hash->address);
if (0 == status)
{
entry = gc_dbk_get_entry_by_hash(hash);
if (NULL == entry)
{
/* If the lookup still failed, then verify if we have right permissions on
* GNUPGHOME or $HOME/.gnupg (if GNUPGHOME is unset). If not, then the below
* function will store the appropriate error message in err_string and
* so we can return GC_FAILURE.*/
if (GC_SUCCESS != gc_pk_gpghome_has_permissions())
return GC_FAILURE;
err_caused_by_gpg = ('\0' != err_string[0]);
alert_msg = (err_caused_by_gpg ? gpg_msg : correct_key_msg);
/* Save the previous error message if any */
strcpy(save_err, err_string);
for (i = 0; i < GTMCRYPT_HASH_HEX_LEN; i+=2)
sprintf(hex_buff + i, "%02X", (unsigned char)(hash->address[i/2]));
if (err_caused_by_gpg)
snprintf(err_string, ERR_STRLEN, "Expected hash - %s - %s. %s", hex_buff, save_err, alert_msg);
else
snprintf(err_string, ERR_STRLEN, "Expected hash - %s. %s", hex_buff, alert_msg);
return GC_FAILURE;
}
*handle = entry->index;
}
return status;
}
/* Note: If any of the following macros fail, the error return happens within the macro. */
xc_status_t gtmcrypt_hash_gen(gtmcrypt_key_t handle, xc_string_t *hash)
{
db_key_map *entry;
GC_VERIFY_INITED;
assert(INVALID_HANDLE != handle);
GC_DBK_GET_ENTRY_FROM_HANDLE(handle, entry, GC_FAILURE);
gc_dbk_get_hash(entry, hash);
return GC_SUCCESS;
}
/* Note: If any of the following macros fail, the error return happens within the macro. */
xc_status_t gtmcrypt_encode(gtmcrypt_key_t handle, xc_string_t *unencrypted_block, xc_string_t *encrypted_block)
{
crypt_key_t key_handle;
db_key_map *entry;
GC_VERIFY_INITED;
assert(INVALID_HANDLE != handle);
GC_DBK_GET_ENTRY_FROM_HANDLE(handle, entry, GC_FAILURE);
key_handle = entry->encr_key_handle;
GC_SYM_ENCODE(key_handle, unencrypted_block, encrypted_block);
return GC_SUCCESS;
}
/* Note: If any of the following macros fail, the error return happens within the macro. */
xc_status_t gtmcrypt_decode(gtmcrypt_key_t handle, xc_string_t *encrypted_block, xc_string_t *unencrypted_block)
{
crypt_key_t key_handle;
db_key_map *entry;
GC_VERIFY_INITED;
assert(INVALID_HANDLE != handle);
GC_DBK_GET_ENTRY_FROM_HANDLE(handle, entry, GC_FAILURE);
key_handle = entry->decr_key_handle;
GC_SYM_DECODE(key_handle, encrypted_block, unencrypted_block);
return GC_SUCCESS;
}
/* Note: If any of the following macros fail, the error return happens within the macro. */
xc_status_t gtmcrypt_close()
{
GC_VERIFY_INITED;
gc_pk_scrub_passwd();
gc_dbk_scrub_entries();
GC_CLEAR_INITED;
return GC_SUCCESS;
}

View File

@ -0,0 +1,245 @@
/****************************************************************
* *
* Copyright 2009, 2011 Fidelity Information Services, Inc *
* *
* This source code contains the intellectual property *
* of its copyright holder(s), and is made available *
* under a license. If you do not know the terms of *
* the license, please stop and do not read further. *
* *
****************************************************************/
#ifndef GTMCRYPT_REF_H
#define GTMCRYPT_REF_H
#ifdef USE_OPENSSL
# include <openssl/blowfish.h>
# include <openssl/sha.h>
# include <openssl/evp.h>
#elif defined USE_GCRYPT
# include <gcrypt.h>
#else
# error "Unsupported encryption library. Reference implementation currently supports openssl and gcrypt"
#endif
#ifndef DEBUG
#undef assert
#define assert(x)
#endif
/* Any change done to the below macro should be reflected in mdef.h and vice versa */
/* Note: sizeof returns a "unsigned long" type by default. In expressions involving 32-bit quantities,
* using sizeof causes a compiler warning for every 64->32 bit auto cast (zOS compiler for now).
* Hence typecasting the return to "int" on zOS (to avoid warning) in most common sizeof usages.
* Whenever SIZEOF needs to be used in expressions involving 64-bit pointer quantities, use ((INTPTR_T)SIZEOF(...)).
* Whenever SIZEOF needs to be used in expressions involving 64-bit integer quantities, use ((long)SIZEOF(...)).
*/
#if defined(__MVS__)
# define SIZEOF(X) ((int)(sizeof(X)))
#else
# define SIZEOF(X) ((long)sizeof(X))
#endif
typedef enum
{
ERROR_LINE_INFO = -1,
DAT_LINE_INFO,
KEY_LINE_INFO
} dbkeyfile_line_type;
typedef enum
{
LOOKING_FOR_DAT_ENTRY = 1,
LOOKING_FOR_KEY_ENTRY,
NUM_STATES
} dbkeyfile_states;
#ifdef USE_OPENSSL
typedef EVP_CIPHER_CTX crypt_key_t;
#else
typedef gcry_cipher_hd_t crypt_key_t;
#endif
#define TAB_NAME_MAX 512
#define GTM_PASSPHRASE_MAX 512
#define GC_ENCRYPT 1
#define GC_DECRYPT 0
#define GC_FAILURE 1
#define GC_SUCCESS 0
#define TRUE 1
#define FALSE 0
#define GNUPGHOME "GNUPGHOME"
#define DOT_GNUPG ".gnupg"
#define GTM_PASSWD "gtm_passwd"
#define GTM_DBKEYS "gtm_dbkeys"
#define DOT_GTM_DBKEYS "."GTM_DBKEYS
#define PASSWD_EMPTY "Environment variable gtm_passwd set to empty string. Password prompting not allowed for utilites"
#define GTM_PATH_MAX 1024
#define GTM_KEY_MAX 32
#define GTMCRYPT_HASH_LEN 64
#define GTMCRYPT_HASH_HEX_LEN GTMCRYPT_HASH_LEN * 2
#define DAT_LINE_INDICATOR "dat "
#define KEY_LINE_INDICATOR "key "
#define DAT_LINE_INDICATOR_SIZE (SIZEOF(DAT_LINE_INDICATOR) - 1)
#define KEY_LINE_INDICATOR_SIZE (SIZEOF(KEY_LINE_INDICATOR) - 1)
#define INVALID_HANDLE -1
#define GTMCI "GTMCI"
#define ERR_STRLEN 2048
#ifdef USE_GCRYPT
#define IV_LEN 16
#define ALGO GCRY_CIPHER_AES256
#define MODE GCRY_CIPHER_MODE_CFB
/* This string uniquely identifies the encryption algorithm and its parameters.
* It will be appended to the encryption key and the combination will be hashed (with SHA512).
* This hash will be used verify that the same algorithm (including parameters) and key are used to
* open the database file as were used to create the database file. */
#define UNIQ_ENC_PARAM_STRING "AES256CFB"
#define FLAGS 0
static char iv[IV_LEN];
static int gcry_already_inited = FALSE;
#else
#define ALGO EVP_bf_cfb64()
#define UNIQ_ENC_PARAM_STRING "BLOWFISHCFB"
#endif
#define UNIQ_ENC_PARAM_LEN SIZEOF(UNIQ_ENC_PARAM_STRING) - 1
#define HASH_INPUT_BUFF_LEN UNIQ_ENC_PARAM_LEN + GTM_KEY_MAX
/* ==================================================================================== */
/* Legend to namespaces used -
* gc_XXXXX - All functions start with the gc_ namespace
* gc_dbk_XXX - All functions related to db key mapping and internal book keeping
* gc_sym_XXX - All functions related to usages of symmetric enc/dec activities, primarily using libgcrypt or libcrypto
* gc_pk_XXX - All functions related to usages of public/private key enc/dec activities, primarily using libgpgme
*/
/* ==================================================================================== */
/* ==================================================================================== */
/* Generic macros and functions related to this plugin */
/* ==================================================================================== */
#define GC_MIN_STATIC_BLOCK_SIZE 4096 /* Have a good size block, so that we dont keep reallocating */
#define GC_ROUNDUP(x, y) ((x / y) * y) + ((x % y) ? y : 0)
#define GC_FLAGS (RTLD_NOW | RTLD_GLOBAL)
#define GTM_MALLOC_FUNC "gtm_malloc"
#define GTM_FREE_FUNC "gtm_free"
#define GTM_FILENAME_TO_ID_FUNC "gtm_filename_to_id"
#define GTM_CI_FUNC "gtm_ci"
#define GTM_ZSTATUS_FUNC "gtm_zstatus"
#define GTM_IS_FILE_IDENTICAL_FUNC "gtm_is_file_identical"
#define GTM_XCFILEID_FREE_FUNC "gtm_xcfileid_free"
xc_status_t gc_init_interface(int prompt_passwd);
typedef void * (*gtm_malloc_fptr_t)(size_t);
typedef void (*gtm_free_fptr_t)(void *);
typedef xc_status_t (*gtm_filename_to_id_fptr_t)(xc_string_t *, xc_fileid_ptr_t *);
typedef xc_status_t (*gtm_ci_fptr_t)(const char *c_rtn_name, ...);
typedef void (*gtm_zstatus_fptr_t)(char *msg, int len);
typedef xc_status_t (*gtm_is_file_identical_fptr_t)(xc_fileid_ptr_t, xc_fileid_ptr_t);
typedef void (*gtm_xcfileid_free_fptr_t)(xc_fileid_ptr_t);
gtm_malloc_fptr_t gtm_malloc_fptr;
gtm_free_fptr_t gtm_free_fptr;
gtm_filename_to_id_fptr_t gtm_filename_to_id_fptr;
gtm_ci_fptr_t gtm_ci_fptr;
gtm_zstatus_fptr_t gtm_zstatus_fptr;
gtm_is_file_identical_fptr_t gtm_is_file_identical_fptr;
gtm_xcfileid_free_fptr_t gtm_xcfileid_free_fptr;
#define DLSYM_ERR_AND_EXIT(fptr_type, fptr, func_name) \
{ \
fptr = (fptr_type)dlsym(handle, func_name); \
if (NULL == fptr) \
{ \
snprintf(err_string, ERR_STRLEN, "Enable to resolve %s ", func_name); \
return GC_FAILURE; \
} \
}
#define GC_MALLOC(blk, len, type) \
{ \
blk = (type *)gtm_malloc_fptr(len); \
assert (blk); \
}
#define GC_FREE(blk) gtm_free_fptr(blk)
#define GC_COPY_TO_XC_STRING(X, STR, N) \
{ \
memcpy((X)->address, STR, N); \
(X)->length = N; \
}
/* Following makes sure that at no point we are in the encryption library without gtmcrypt_init getting called
* prior to the current call
*/
#define GC_VERIFY_INITED \
{ \
if (!gtmcrypt_inited) \
{ \
snprintf(err_string, ERR_STRLEN, "%s", "Encryption library has not been initialized"); \
return GC_FAILURE; \
} \
}
#define GC_IF_INITED_RETURN \
{ \
/* Check if init has happened already */ \
if (gtmcrypt_inited) \
return GC_SUCCESS; \
}
#define GC_SET_INITED gtmcrypt_inited = TRUE;
#define GC_CLEAR_INITED gtmcrypt_inited = FALSE;
#define GC_INT(H) ((H >= 'A' && H <= 'F') ? ((H - 'A') + 10) : (H - '0'))
#define GC_UNHEX(a, b, len) \
{ \
int i; \
for (i = 0; i < len; i+=2) \
b[i/2] = (unsigned char)(GC_INT(a[i]) * 16 + GC_INT(a[i + 1])); \
}
#define GC_HEX(a, b, len) \
{ \
int i; \
for (i = 0; i < len; i+=2) \
sprintf(b + i, "%02X", (unsigned char)a[i/2]); \
}
#define GC_GETENV(ptr, key, RC) \
{ \
RC = GC_SUCCESS; \
if (NULL == (ptr = (char *)getenv(key))) \
RC = GC_FAILURE; \
}
#define GC_ENV_UNSET_ERROR(key) \
{ \
snprintf(err_string, ERR_STRLEN, "Environment variable %s not set", key); \
}
/* Allocate a single block, and try reusing the same everytime this macro is called */
#ifdef USE_OPENSSL
#define GC_GET_STATIC_BLOCK(out, block_len) \
{ \
static char *blk = (char *)NULL; \
static int allocated_len = GC_MIN_STATIC_BLOCK_SIZE; \
if (blk == NULL || (block_len > allocated_len)) \
{ \
if (blk) \
GC_FREE(blk); \
allocated_len = (block_len > allocated_len) ? \
GC_ROUNDUP(block_len, GC_MIN_STATIC_BLOCK_SIZE) : \
allocated_len; \
GC_MALLOC(blk, allocated_len, char); \
} \
out = blk; \
}
#endif
#endif /* GTMCRYPT_REF_H */

View File

@ -0,0 +1,174 @@
/****************************************************************
* *
* Copyright 2009, 2010 Fidelity Information Services, Inc *
* *
* This source code contains the intellectual property *
* of its copyright holder(s), and is made available *
* under a license. If you do not know the terms of *
* the license, please stop and do not read further. *
* *
****************************************************************/
#ifndef GTMCRYPT_SYM_REF_H
#define GTMCRYPT_SYM_REF_H
/* ==================================================================================== */
/* Macros and functions for symmetric encryption tasks */
/* ==================================================================================== */
#ifdef USE_OPENSSL
#define GC_SYM_CREATE_HANDLES(cur_entry) \
{ \
int ecode; \
unsigned char *key = (unsigned char *)(cur_entry->key_string.address); \
\
EVP_CIPHER_CTX_init(&(cur_entry->encr_key_handle)); \
ecode = EVP_CipherInit(&(cur_entry->encr_key_handle), ALGO, key, NULL, GC_ENCRYPT); \
GC_SYM_ERROR(ecode, GC_FAILURE); \
\
EVP_CIPHER_CTX_init(&(cur_entry->decr_key_handle)); \
ecode = EVP_CipherInit(&(cur_entry->decr_key_handle), ALGO, key, NULL, GC_DECRYPT); \
GC_SYM_ERROR(ecode, GC_FAILURE); \
}
#define GC_SYM_ERROR(err, return_value) \
{ \
if (!err) \
{ \
ERR_error_string_n(err, err_string, ERR_STRLEN); \
return return_value; \
} \
}
#else
#define GC_SYM_CREATE_HANDLES(cur_entry) \
{ \
gcry_error_t err; \
char *key = cur_entry->key_string.address; \
size_t keylen = cur_entry->key_string.length; \
\
GC_SYM_INIT; \
err = gcry_cipher_open(&(cur_entry->encr_key_handle), ALGO, MODE, FLAGS); \
if (!err) \
err = gcry_cipher_setkey(cur_entry->encr_key_handle, key, keylen); \
GC_SYM_ERROR(err, GC_FAILURE); \
err = gcry_cipher_open(&(cur_entry->decr_key_handle), ALGO, MODE, FLAGS); \
if (!err) \
err = gcry_cipher_setkey(cur_entry->decr_key_handle, key, keylen); \
GC_SYM_ERROR(err, GC_FAILURE); \
}
#define GC_SYM_ERROR(err, return_value) \
{ \
if (GPG_ERR_NO_ERROR != err) \
{ \
snprintf(err_string, ERR_STRLEN, "%s", gcry_strerror(err)); \
return return_value; \
} \
}
#endif
#ifdef USE_GCRYPT
/* Initialization and error handling functions defined only for libgcrypt.
* OpenSSL doesn't neeed them. */
#define GC_SYM_INIT \
{ \
gcry_error_t err; \
char *ver; \
\
if (!gcry_already_inited) \
{ \
memset(iv, 0, IV_LEN); \
if (!gcry_check_version(GCRYPT_VERSION)) \
{ \
snprintf(err_string, \
ERR_STRLEN, \
"libgcrypt version mismatch. %s or higher is required", \
GCRYPT_VERSION); \
return GC_FAILURE; \
} \
if (!(err = gcry_control(GCRYCTL_DISABLE_SECMEM, 0))) \
if (!(err = gcry_control(GCRYCTL_INITIALIZATION_FINISHED, 0))) \
gcry_already_inited = TRUE; \
GC_SYM_ERROR(err, GC_FAILURE); \
} \
}
#endif
#ifdef USE_OPENSSL
#define GC_SYM_COMMON(key_handle, in_block, out_block, flag) \
{ \
int block_len, is_inplace, ecode, tmp_len; \
int out_len; \
char *static_out_blk; \
unsigned char *in = NULL, *out = NULL; \
\
assert(in_block->address); \
assert(0 != in_block->length); \
in = (unsigned char *)in_block->address; \
block_len = in_block->length; \
out = (unsigned char *)out_block->address; \
if (NULL == out_block->address) \
{ \
GC_GET_STATIC_BLOCK(static_out_blk, block_len); \
out = (unsigned char *)static_out_blk; \
is_inplace = TRUE; \
} else \
is_inplace = FALSE; \
ecode = EVP_CipherUpdate(&key_handle, out, &out_len, in, block_len); \
if (ecode) \
ecode = EVP_CipherFinal(&key_handle, out + out_len, &tmp_len); \
GC_SYM_ERROR(ecode, GC_FAILURE); \
if (is_inplace) \
memcpy(in, out, block_len); \
}
#else /* USE_GCRYPT */
#define GC_SYM_COMMON(key_handle, in_block, out_block, flag) \
{ \
int is_inplace = 0; \
size_t blen; \
gcry_error_t err; \
\
assert(in_block->address); \
assert(0 != in_block->length); \
blen = in_block->length; \
if (NULL == out_block->address) \
is_inplace = TRUE; \
\
GC_SYM_INIT; \
gcry_cipher_setiv(key_handle, iv, IV_LEN); \
if (is_inplace) \
{ \
if (flag == GC_ENCRYPT) \
{ \
err = gcry_cipher_encrypt(key_handle, in_block->address, blen, NULL, 0);\
GC_SYM_ERROR(err, GC_FAILURE); \
} else \
{ \
err = gcry_cipher_decrypt(key_handle, in_block->address, blen, NULL, 0);\
GC_SYM_ERROR(err, GC_FAILURE); \
} \
} else \
{ \
if (flag == GC_ENCRYPT) \
{ \
err = gcry_cipher_encrypt(key_handle, \
out_block->address, \
blen, \
in_block->address, \
blen); \
GC_SYM_ERROR(err, GC_FAILURE); \
} else \
{ \
err = gcry_cipher_decrypt(key_handle, \
out_block->address, \
blen, \
in_block->address, \
blen); \
GC_SYM_ERROR(err, GC_FAILURE); \
} \
} \
}
#endif
#define GC_SYM_DECODE(key_handle, encrypted_block, unencrypted_block) \
GC_SYM_COMMON(key_handle, encrypted_block, unencrypted_block, GC_DECRYPT)
#define GC_SYM_ENCODE(key_handle, unencrypted_block, encrypted_block) \
GC_SYM_COMMON(key_handle, unencrypted_block, encrypted_block, GC_ENCRYPT)
#endif /* GTMCRYPT_SYM_REF_H */

View File

@ -0,0 +1,87 @@
/****************************************************************
* *
* Copyright 2001, 2011 Fidelity Information Services, Inc *
* *
* This source code contains the intellectual property *
* of its copyright holder(s), and is made available *
* under a license. If you do not know the terms of *
* the license, please stop and do not read further. *
* *
****************************************************************/
/* gtmxc_types.h - GT.M, Unix Edition External Call type definitions. */
#ifndef GTMXC_TYPES_H
#define GTMXC_TYPES_H
#ifdef __osf__
/* Ensure 32-bit pointers for compatibility with GT.M internal representations. */
#pragma pointer_size (save)
#pragma pointer_size (short)
#endif
typedef int xc_status_t;
typedef int xc_int_t;
typedef unsigned int xc_uint_t;
#if defined(__osf__)
typedef int xc_long_t;
typedef unsigned int xc_ulong_t;
#else
typedef long xc_long_t;
typedef unsigned long xc_ulong_t;
#endif
typedef float xc_float_t;
typedef double xc_double_t;
typedef char xc_char_t;
typedef int (*xc_pointertofunc_t)();
typedef struct
{
xc_long_t length;
xc_char_t *address;
} xc_string_t;
#ifdef __osf__
#pragma pointer_size (restore)
#endif
/* new types for external/call-in user - xc_* types still valid for backward compatibility */
typedef xc_status_t gtm_status_t;
typedef xc_int_t gtm_int_t;
typedef xc_uint_t gtm_uint_t;
typedef xc_long_t gtm_long_t;
typedef xc_ulong_t gtm_ulong_t;
typedef xc_float_t gtm_float_t;
typedef xc_double_t gtm_double_t;
typedef xc_char_t gtm_char_t;
typedef xc_string_t gtm_string_t;
typedef xc_pointertofunc_t gtm_pointertofunc_t;
typedef struct
{
gtm_string_t rtn_name;
void* handle;
} ci_name_descriptor;
/* call-in interface */
xc_status_t gtm_ci(const char *c_rtn_name, ...);
xc_status_t gtm_cip(ci_name_descriptor *ci_info, ...);
xc_status_t gtm_init(void);
xc_status_t gtm_exit(void);
void gtm_zstatus(char* msg, int len);
typedef int gtmcrypt_key_t;
typedef void *xc_fileid_ptr_t;
xc_status_t gtm_filename_to_id(xc_string_t *filename, xc_fileid_ptr_t *fileid);
xc_status_t gtm_is_file_identical(xc_fileid_ptr_t fileid1, xc_fileid_ptr_t fileid2);
void gtm_xcfileid_free(xc_fileid_ptr_t fileid);
void *gtm_malloc(size_t);
void gtm_free(void *);
#endif /* GTMXC_TYPES_H */

View File

@ -0,0 +1,21 @@
/****************************************************************
* *
* Copyright 2009 Fidelity Information Services, Inc *
* *
* This source code contains the intellectual property *
* of its copyright holder(s), and is made available *
* under a license. If you do not know the terms of *
* the license, please stop and do not read further. *
* *
****************************************************************/
#ifndef MAIN_PRAGMA_included
#define MAIN_PRAGMA_included
#ifdef __MVS__
#pragma runopts(ENVAR(_BPXK_AUTOCVT=ON))
#pragma runopts(FILETAG(AUTOCVT,AUTOTAG))
#endif
#endif /* MAIN_PRAGMA_included */

View File

@ -0,0 +1,123 @@
/****************************************************************
* *
* Copyright 2009, 2011 Fidelity Information Services, Inc *
* *
* This source code contains the intellectual property *
* of its copyright holder(s), and is made available *
* under a license. If you do not know the terms of *
* the license, please stop and do not read further. *
* *
****************************************************************/
#include "main_pragma.h"
#include <stdio.h>
#include <string.h>
#include <sys/stat.h>
#include <stdlib.h>
#include <termios.h>
#define MAX_LEN 512
#define FSTR_LEN 7 /* %2048s */
#define GTM_PATH_MAX 1024
#define GTM_DIST "gtm_dist"
struct termios old_tty, no_echo_tty;
#define MIN(a, b) ((a) < (b) ? (a) : (b))
#define HEX(a, b, len) \
{ \
int i; \
for (i = 0; i < len; i+=2) \
sprintf(b + i, "%02X", (unsigned char)a[i/2]); \
}
static void maskpass(char passwd[], char inode[], char user[], size_t max)
{
size_t i;
for (i = 0; i < max; i++)
passwd[i] = passwd[i] ^ inode[i] ^ user[i];
}
static int echo_off()
{
int fd, status;
fd = fileno(stdin);
/* Save current TTY settings */
status = tcgetattr(fd, &old_tty);
if (0 != status)
return 1;
no_echo_tty = old_tty;
no_echo_tty.c_lflag &= ~ECHO; /* Turn off echo */
status = tcsetattr(fd, TCSAFLUSH, &no_echo_tty);
return status;
}
static int echo_on()
{
int fd, status;
fd = fileno(stdin);
status = tcsetattr(fd, TCSAFLUSH, &old_tty);
return status;
}
static void prompt_passwd(char passwd[])
{
char fstr[FSTR_LEN];
int echo_off_status;
sprintf(fstr, "%%%ds", MAX_LEN); /* Create the format string "%2048s" */
printf("Enter Password: ");
echo_off_status = echo_off();
scanf(fstr, passwd);
/* Since echo_on depends on whether echo_off succeeded or not, do echo_on only if echo_off went fine */
if (0 == echo_off_status)
echo_on();
}
int main()
{
char tmp[MAX_LEN], passwd[MAX_LEN], inode[MAX_LEN], user[MAX_LEN], out[MAX_LEN * 2];
char mumps_ex[GTM_PATH_MAX], save_user_env[MAX_LEN], *user_ptr, *dist_ptr;
int i;
size_t passwd_len, ilen;
struct stat stat_info;
memset(passwd, 0, MAX_LEN);
memset(inode, 0, MAX_LEN);
memset(user, 0, MAX_LEN);
memset(out, 0, MAX_LEN * 2);
memset(mumps_ex, 0, GTM_PATH_MAX);
/* We need $USER and $gtm_dist to be defined to do the proper masking */
if (NULL == (user_ptr = (char *)getenv("USER")))
{
printf("Environment variable USER not defined.\n");
exit(1);
}
strcpy(save_user_env, user_ptr);
if (NULL == (dist_ptr = (char *)getenv(GTM_DIST)))
{
printf("Enivronment variable gtm_dist not defined.\n");
exit(1);
}
snprintf(mumps_ex, GTM_PATH_MAX, "%s/%s", dist_ptr, "mumps");
if (0 != stat(mumps_ex, &stat_info))
{
printf("Cannot stat %s\n", mumps_ex);
exit(1);
}
prompt_passwd(passwd);
passwd_len = strlen(passwd);
strncpy(user, save_user_env, MIN(passwd_len, MAX_LEN));
snprintf(tmp, MAX_LEN, "%ld", stat_info.st_ino);
ilen = strlen(tmp);
if (ilen < passwd_len)
strncpy(inode + (passwd_len - ilen), tmp, ilen);
else
strncpy(inode, tmp, passwd_len);
maskpass(passwd, inode, user, passwd_len);
HEX(passwd, out, passwd_len * 2);
printf("%s\n", out);
return 0;
}

1
pro/utf8/gtm_limits.h Symbolic link
View File

@ -0,0 +1 @@
../gtm_limits.h

1
pro/utf8/gtm_stdio.h Symbolic link
View File

@ -0,0 +1 @@
../gtm_stdio.h

1
pro/utf8/gtm_stdlib.h Symbolic link
View File

@ -0,0 +1 @@
../gtm_stdlib.h

1
pro/utf8/gtm_string.h Symbolic link
View File

@ -0,0 +1 @@
../gtm_string.h

1
pro/utf8/gtm_strings.h Symbolic link
View File

@ -0,0 +1 @@
../gtm_strings.h

1
pro/utf8/gtmxc_types.h Symbolic link
View File

@ -0,0 +1 @@
../gtmxc_types.h

1
pro/utf8/main_pragma.h Symbolic link
View File

@ -0,0 +1 @@
../main_pragma.h

47
setupenv.sh Executable file
View File

@ -0,0 +1,47 @@
#!/usr/bin/tcsh
#
# Required Packages
#
# apt-get install tcsh
# apt-get install libicu-dev
# apt-get install gnupg-doc
# apt-get install zlib1g-dev
# apt-get install libncurses-dev
# apt-get install libgcrypt11-dev
#
#
# Path (only directory) to the gtm executables
# setenv gtm_curpro /usr/lib/fis-gtm/V5.4-002B_x86
setenv gtm_curpro $PWD/fake-binary-surrogates
setenv gtm_exe $gtm_curpro
setenv HOSTOS `uname -s`
setenv gtm_tools $PWD/sr_linux
setenv gtm_inc $PWD/sr_linux
# Tried setting distro to "debian" but got
# error listed in the README file, so used
# distro ubuntu anyways.
setenv distro ubuntu
# NOT set this 32 bits option and let it do a 64 bits build.
# setenv OBJECT_MODE 32
# icu-config --version
# and use only the first two digits
setenv gtm_icu_version 4.4
setenv gtm_version_change 1
source sr_unix/gtm_env.csh
echo "----- Start the build -----"
make -f sr_unix/comlist.mk -I./sr_unix -I./sr_linux buildtypes=pro gtm_ver=$PWD
echo "------ End of build -------"

View File

@ -0,0 +1,442 @@
/****************************************************************
* *
* Copyright 2010, 2012 Fidelity Information Services, Inc *
* *
* This source code contains the intellectual property *
* of its copyright holder(s), and is made available *
* under a license. If you do not know the terms of *
* the license, please stop and do not read further. *
* *
****************************************************************/
/* Generated by /home/ibanez/src/fis-gtm/sr_linux/gen_gtm_threadgbl_deftypes.csh */
#ifndef GTM_THREADGBL_DEFTYPES_INCLUDED
#define GTM_THREADGBL_DEFTYPES_INCLUDED
/* Output selection criteria for PRO build */
#if !defined(DEBUG) || defined(PRO_BUILD)
# define ggo_grabbing_crit 0
# define ggt_grabbing_crit gd_region *
# define ggo_code_generated 4
# define ggt_code_generated boolean_t
# define ggo_compile_time 8
# define ggt_compile_time boolean_t
# define ggo_dollar_zcstatus 12
# define ggt_dollar_zcstatus int4
# define ggo_expr_depth 16
# define ggt_expr_depth unsigned int
# define ggo_expr_start 20
# define ggt_expr_start triple *
# define ggo_expr_start_orig 24
# define ggt_expr_start_orig triple *
# define ggo_for_nest_level 28
# define ggt_for_nest_level uint4
# define ggo_for_stack_ptr 32
# define ggt_for_stack_ptr oprtype **
# define ggo_gtm_fullbool 36
# define ggt_gtm_fullbool unsigned int
# define ggo_last_source_column 40
# define ggt_last_source_column short int
# define ggo_pos_in_chain 44
# define ggt_pos_in_chain triple
# define ggo_s2n_intlit 116
# define ggt_s2n_intlit boolean_t
# define ggo_shift_side_effects 120
# define ggt_shift_side_effects int
# define ggo_source_error_found 124
# define ggt_source_error_found int4
# define ggo_temp_subs 128
# define ggt_temp_subs boolean_t
# define ggo_trigger_compile 132
# define ggt_trigger_compile boolean_t
# define ggo_donot_commit 136
# define ggt_donot_commit boolean_t
# define ggo_gd_targ_addr 140
# define ggt_gd_targ_addr gd_addr *
# define ggo_gtm_gvundef_fatal 144
# define ggt_gtm_gvundef_fatal boolean_t
# define ggo_gv_extname_size 148
# define ggt_gv_extname_size int4
# define ggo_gv_last_subsc_null 152
# define ggt_gv_last_subsc_null boolean_t
# define ggo_gv_mergekey2 156
# define ggt_gv_mergekey2 gv_key *
# define ggo_gv_reorgkey 160
# define ggt_gv_reorgkey gv_key *
# define ggo_gv_some_subsc_null 164
# define ggt_gv_some_subsc_null boolean_t
# define ggo_gv_sparekey 168
# define ggt_gv_sparekey gv_key *
# define ggo_gv_sparekey_mval 172
# define ggt_gv_sparekey_mval mval
# define ggo_gv_sparekey_size 196
# define ggt_gv_sparekey_size int4
# define ggo_gv_tporigkey_ptr 200
# define ggt_gv_tporigkey_ptr gv_orig_key_array *
# define ggo_in_op_gvget 204
# define ggt_in_op_gvget boolean_t
# define ggo_last_fnquery_return_subcnt 208
# define ggt_last_fnquery_return_subcnt int
# define ggo_last_fnquery_return_varname 212
# define ggt_last_fnquery_return_varname mval
# define ggo_ok_to_call_wcs_recover 236
# define ggt_ok_to_call_wcs_recover boolean_t
# define ggo_prev_gv_target 240
# define ggt_prev_gv_target gv_namehead *
# define ggo_ready2signal_gvundef 244
# define ggt_ready2signal_gvundef boolean_t
# define ggo_semop2long 248
# define ggt_semop2long volatile boolean_t
# define ggo_semwait2long 252
# define ggt_semwait2long volatile boolean_t
# define ggo_tp_restart_count 256
# define ggt_tp_restart_count uint4
# define ggo_tp_restart_dont_counts 260
# define ggt_tp_restart_dont_counts uint4
# define ggo_tp_restart_entryref 264
# define ggt_tp_restart_entryref mval
# define ggo_tp_restart_failhist_indx 288
# define ggt_tp_restart_failhist_indx int4
# define ggo_tp_restart_needlock_tn 292
# define ggt_tp_restart_needlock_tn trans_num
# define ggo_tp_restart_needlock_cnt 300
# define ggt_tp_restart_needlock_cnt uint4
# define ggo_transform 304
# define ggt_transform boolean_t
# define ggo_in_op_fnnext 308
# define ggt_in_op_fnnext boolean_t
# define ggo_local_collseq 312
# define ggt_local_collseq collseq *
# define ggo_local_collseq_stdnull 316
# define ggt_local_collseq_stdnull boolean_t
# define ggo_lv_null_subs 320
# define ggt_lv_null_subs int
# define ggo_max_lcl_coll_xform_bufsiz 324
# define ggt_max_lcl_coll_xform_bufsiz int
# define ggo_replgbl 328
# define ggt_replgbl replgbl_t
# define ggo_collseq_list 360
# define ggt_collseq_list collseq *
# define ggo_create_fatal_error_zshow_dmp_fptr 364
# define ggt_create_fatal_error_zshow_dmp_fptr void
# define gga_create_fatal_error_zshow_dmp_fptr ()
typedef void (*ggf_create_fatal_error_zshow_dmp_fptr)();
# define ggo_disable_sigcont 368
# define ggt_disable_sigcont boolean_t
# define ggo_dollar_zcompile 372
# define ggt_dollar_zcompile mstr
# define ggo_dollar_zmode 384
# define ggt_dollar_zmode mval
# define ggo_dollar_zroutines 408
# define ggt_dollar_zroutines mstr
# define ggo_error_on_jnl_file_lost 420
# define ggt_error_on_jnl_file_lost unsigned int
# define ggo_fnzsearch_lv_vars 424
# define ggt_fnzsearch_lv_vars lv_val *
# define ggo_fnzsearch_sub_mval 428
# define ggt_fnzsearch_sub_mval mval
# define ggo_fnzsearch_nullsubs_sav 452
# define ggt_fnzsearch_nullsubs_sav int
# define ggo_gtm_env_init_done 456
# define ggt_gtm_env_init_done boolean_t
# define ggo_gtm_env_xlate_entry 460
# define ggt_gtm_env_xlate_entry int
# define gga_gtm_env_xlate_entry ()
typedef int (*ggf_gtm_env_xlate_entry)();
# define ggo_gtm_environment_init 464
# define ggt_gtm_environment_init boolean_t
# define ggo_gtm_sigusr1_handler 468
# define ggt_gtm_sigusr1_handler void
# define gga_gtm_sigusr1_handler ()
typedef void (*ggf_gtm_sigusr1_handler)();
# define ggo_gtm_waitstuck_script 472
# define ggt_gtm_waitstuck_script mstr
# define ggo_gtmprompt 484
# define ggt_gtmprompt mstr
# define ggo_in_zwrite 496
# define ggt_in_zwrite boolean_t
# define ggo_mprof_chunk_avail_size 500
# define ggt_mprof_chunk_avail_size int
# define ggo_mprof_ptr 504
# define ggt_mprof_ptr mprof_wrapper *
# define ggo_mprof_stack_curr_frame 508
# define ggt_mprof_stack_curr_frame mprof_stack_frame *
# define ggo_mprof_stack_next_frame 512
# define ggt_mprof_stack_next_frame mprof_stack_frame *
# define ggo_open_shlib_root 516
# define ggt_open_shlib_root open_shlib *
# define ggo_parms_cnt 520
# define ggt_parms_cnt unsigned int
# define ggo_pipefifo_interrupt 524
# define ggt_pipefifo_interrupt int
# define ggo_prof_fp 528
# define ggt_prof_fp mprof_stack_frame *
# define ggo_trans_code_pop 532
# define ggt_trans_code_pop mval *
# define ggo_view_ydirt_str 536
# define ggt_view_ydirt_str char *
# define ggo_view_ydirt_str_len 540
# define ggt_view_ydirt_str_len int4
# define ggo_zdate_form 544
# define ggt_zdate_form int4
# define ggo_zro_root 548
# define ggt_zro_root zro_ent *
# define ggo_zsearch_var 552
# define ggt_zsearch_var lv_val *
# define ggo_zsearch_dir1 556
# define ggt_zsearch_dir1 lv_val *
# define ggo_zsearch_dir2 560
# define ggt_zsearch_dir2 lv_val *
# define ggo_fnpca 564
# define ggt_fnpca fnpc_area
# define ggo_for_stack 18372
# define ggt_for_stack oprtype *
# define ggl_for_stack 128
# define ggo_for_temps 18500
# define ggt_for_temps boolean_t
# define ggl_for_temps 128
# define ggo_last_fnquery_return_sub 18628
# define ggt_last_fnquery_return_sub mval
# define ggl_last_fnquery_return_sub 768
# define ggo_lcl_coll_xform_buff 19396
# define ggt_lcl_coll_xform_buff char *
# define ggo_parm_ary 19400
# define ggt_parm_ary char *
# define ggl_parm_ary 20
# define ggo_parm_ary_len 19420
# define ggt_parm_ary_len int
# define ggl_parm_ary_len 20
# define ggo_parm_str_len 19440
# define ggt_parm_str_len int
# define ggl_parm_str_len 20
# define ggo_prombuf 19460
# define ggt_prombuf char
# define ggl_prombuf 32
# define ggo_rt_name_tbl 19492
# define ggt_rt_name_tbl hash_table_mname
# define ggo_tp_restart_failhist_arry 19548
# define ggt_tp_restart_failhist_arry char
# define ggl_tp_restart_failhist_arry 32
# define ggo_callin_hashtab 19580
# define ggt_callin_hashtab hash_table_str *
# define ggo_ci_table 19584
# define ggt_ci_table callin_entry_list *
# define ggo_extcall_package_root 19588
# define ggt_extcall_package_root struct extcall_package_list *
# define ggo_gtmci_nested_level 19592
# define ggt_gtmci_nested_level unsigned int
# define size_gtm_threadgbl_struct 19596
#else
# define ggo_grabbing_crit 0
# define ggt_grabbing_crit gd_region *
# define ggo_code_generated 4
# define ggt_code_generated boolean_t
# define ggo_compile_time 8
# define ggt_compile_time boolean_t
# define ggo_dollar_zcstatus 12
# define ggt_dollar_zcstatus int4
# define ggo_expr_depth 16
# define ggt_expr_depth unsigned int
# define ggo_expr_start 20
# define ggt_expr_start triple *
# define ggo_expr_start_orig 24
# define ggt_expr_start_orig triple *
# define ggo_for_nest_level 28
# define ggt_for_nest_level uint4
# define ggo_for_stack_ptr 32
# define ggt_for_stack_ptr oprtype **
# define ggo_gtm_fullbool 36
# define ggt_gtm_fullbool unsigned int
# define ggo_last_source_column 40
# define ggt_last_source_column short int
# define ggo_pos_in_chain 44
# define ggt_pos_in_chain triple
# define ggo_s2n_intlit 116
# define ggt_s2n_intlit boolean_t
# define ggo_shift_side_effects 120
# define ggt_shift_side_effects int
# define ggo_source_error_found 124
# define ggt_source_error_found int4
# define ggo_temp_subs 128
# define ggt_temp_subs boolean_t
# define ggo_trigger_compile 132
# define ggt_trigger_compile boolean_t
# define ggo_donot_commit 136
# define ggt_donot_commit boolean_t
# define ggo_gd_targ_addr 140
# define ggt_gd_targ_addr gd_addr *
# define ggo_gtm_gvundef_fatal 144
# define ggt_gtm_gvundef_fatal boolean_t
# define ggo_gv_extname_size 148
# define ggt_gv_extname_size int4
# define ggo_gv_last_subsc_null 152
# define ggt_gv_last_subsc_null boolean_t
# define ggo_gv_mergekey2 156
# define ggt_gv_mergekey2 gv_key *
# define ggo_gv_reorgkey 160
# define ggt_gv_reorgkey gv_key *
# define ggo_gv_some_subsc_null 164
# define ggt_gv_some_subsc_null boolean_t
# define ggo_gv_sparekey 168
# define ggt_gv_sparekey gv_key *
# define ggo_gv_sparekey_mval 172
# define ggt_gv_sparekey_mval mval
# define ggo_gv_sparekey_size 196
# define ggt_gv_sparekey_size int4
# define ggo_gv_tporigkey_ptr 200
# define ggt_gv_tporigkey_ptr gv_orig_key_array *
# define ggo_in_op_gvget 204
# define ggt_in_op_gvget boolean_t
# define ggo_last_fnquery_return_subcnt 208
# define ggt_last_fnquery_return_subcnt int
# define ggo_last_fnquery_return_varname 212
# define ggt_last_fnquery_return_varname mval
# define ggo_ok_to_call_wcs_recover 236
# define ggt_ok_to_call_wcs_recover boolean_t
# define ggo_prev_gv_target 240
# define ggt_prev_gv_target gv_namehead *
# define ggo_ready2signal_gvundef 244
# define ggt_ready2signal_gvundef boolean_t
# define ggo_semop2long 248
# define ggt_semop2long volatile boolean_t
# define ggo_semwait2long 252
# define ggt_semwait2long volatile boolean_t
# define ggo_tp_restart_count 256
# define ggt_tp_restart_count uint4
# define ggo_tp_restart_dont_counts 260
# define ggt_tp_restart_dont_counts uint4
# define ggo_tp_restart_entryref 264
# define ggt_tp_restart_entryref mval
# define ggo_tp_restart_failhist_indx 288
# define ggt_tp_restart_failhist_indx int4
# define ggo_tp_restart_needlock_tn 292
# define ggt_tp_restart_needlock_tn trans_num
# define ggo_tp_restart_needlock_cnt 300
# define ggt_tp_restart_needlock_cnt uint4
# define ggo_transform 304
# define ggt_transform boolean_t
# define ggo_in_op_fnnext 308
# define ggt_in_op_fnnext boolean_t
# define ggo_local_collseq 312
# define ggt_local_collseq collseq *
# define ggo_local_collseq_stdnull 316
# define ggt_local_collseq_stdnull boolean_t
# define ggo_lv_null_subs 320
# define ggt_lv_null_subs int
# define ggo_max_lcl_coll_xform_bufsiz 324
# define ggt_max_lcl_coll_xform_bufsiz int
# define ggo_replgbl 328
# define ggt_replgbl replgbl_t
# define ggo_collseq_list 360
# define ggt_collseq_list collseq *
# define ggo_create_fatal_error_zshow_dmp_fptr 364
# define ggt_create_fatal_error_zshow_dmp_fptr void
# define gga_create_fatal_error_zshow_dmp_fptr ()
typedef void (*ggf_create_fatal_error_zshow_dmp_fptr)();
# define ggo_disable_sigcont 368
# define ggt_disable_sigcont boolean_t
# define ggo_dollar_zcompile 372
# define ggt_dollar_zcompile mstr
# define ggo_dollar_zmode 384
# define ggt_dollar_zmode mval
# define ggo_dollar_zroutines 408
# define ggt_dollar_zroutines mstr
# define ggo_error_on_jnl_file_lost 420
# define ggt_error_on_jnl_file_lost unsigned int
# define ggo_fnzsearch_lv_vars 424
# define ggt_fnzsearch_lv_vars lv_val *
# define ggo_fnzsearch_sub_mval 428
# define ggt_fnzsearch_sub_mval mval
# define ggo_fnzsearch_nullsubs_sav 452
# define ggt_fnzsearch_nullsubs_sav int
# define ggo_gtm_env_init_done 456
# define ggt_gtm_env_init_done boolean_t
# define ggo_gtm_env_xlate_entry 460
# define ggt_gtm_env_xlate_entry int
# define gga_gtm_env_xlate_entry ()
typedef int (*ggf_gtm_env_xlate_entry)();
# define ggo_gtm_environment_init 464
# define ggt_gtm_environment_init boolean_t
# define ggo_gtm_sigusr1_handler 468
# define ggt_gtm_sigusr1_handler void
# define gga_gtm_sigusr1_handler ()
typedef void (*ggf_gtm_sigusr1_handler)();
# define ggo_gtm_waitstuck_script 472
# define ggt_gtm_waitstuck_script mstr
# define ggo_gtmprompt 484
# define ggt_gtmprompt mstr
# define ggo_in_zwrite 496
# define ggt_in_zwrite boolean_t
# define ggo_mprof_chunk_avail_size 500
# define ggt_mprof_chunk_avail_size int
# define ggo_mprof_ptr 504
# define ggt_mprof_ptr mprof_wrapper *
# define ggo_mprof_stack_curr_frame 508
# define ggt_mprof_stack_curr_frame mprof_stack_frame *
# define ggo_mprof_stack_next_frame 512
# define ggt_mprof_stack_next_frame mprof_stack_frame *
# define ggo_open_shlib_root 516
# define ggt_open_shlib_root open_shlib *
# define ggo_parms_cnt 520
# define ggt_parms_cnt unsigned int
# define ggo_pipefifo_interrupt 524
# define ggt_pipefifo_interrupt int
# define ggo_prof_fp 528
# define ggt_prof_fp mprof_stack_frame *
# define ggo_trans_code_pop 532
# define ggt_trans_code_pop mval *
# define ggo_view_ydirt_str 536
# define ggt_view_ydirt_str char *
# define ggo_view_ydirt_str_len 540
# define ggt_view_ydirt_str_len int4
# define ggo_zdate_form 544
# define ggt_zdate_form int4
# define ggo_zro_root 548
# define ggt_zro_root zro_ent *
# define ggo_zsearch_var 552
# define ggt_zsearch_var lv_val *
# define ggo_zsearch_dir1 556
# define ggt_zsearch_dir1 lv_val *
# define ggo_zsearch_dir2 560
# define ggt_zsearch_dir2 lv_val *
# define ggo_fnpca 564
# define ggt_fnpca fnpc_area
# define ggo_for_stack 18372
# define ggt_for_stack oprtype *
# define ggl_for_stack 128
# define ggo_for_temps 18500
# define ggt_for_temps boolean_t
# define ggl_for_temps 128
# define ggo_last_fnquery_return_sub 18628
# define ggt_last_fnquery_return_sub mval
# define ggl_last_fnquery_return_sub 768
# define ggo_lcl_coll_xform_buff 19396
# define ggt_lcl_coll_xform_buff char *
# define ggo_parm_ary 19400
# define ggt_parm_ary char *
# define ggl_parm_ary 20
# define ggo_parm_ary_len 19420
# define ggt_parm_ary_len int
# define ggl_parm_ary_len 20
# define ggo_parm_str_len 19440
# define ggt_parm_str_len int
# define ggl_parm_str_len 20
# define ggo_prombuf 19460
# define ggt_prombuf char
# define ggl_prombuf 32
# define ggo_rt_name_tbl 19492
# define ggt_rt_name_tbl hash_table_mname
# define ggo_tp_restart_failhist_arry 19548
# define ggt_tp_restart_failhist_arry char
# define ggl_tp_restart_failhist_arry 32
# define ggo_callin_hashtab 19580
# define ggt_callin_hashtab hash_table_str *
# define ggo_ci_table 19584
# define ggt_ci_table callin_entry_list *
# define ggo_extcall_package_root 19588
# define ggt_extcall_package_root struct extcall_package_list *
# define ggo_gtmci_nested_level 19592
# define ggt_gtmci_nested_level unsigned int
# define size_gtm_threadgbl_struct 19596
#endif
#endif