Index: trunk/include/kern_head.h
===================================================================
--- trunk/include/kern_head.h	(revision 459)
+++ 	(revision )
@@ -1,1824 +1,0 @@
-
-
-/* x86_64 sys_call_table for kernel 2.4.x
- * generated from 2.6.33 unistd_64.h
- * grep ^__SYSCALL unistd_64.h | \
- *   sed s/.*,[[:blank:]]// | sed 's/)//' | \
- *   awk 'BEGIN{n = 0;}{ printf "    %-32s /%c %03d %c/\n", \
- *                              sprintf("\"%s\",", $1), "*", n, "*"; ++n; }'
- *
- */
-char * syscalls_64[] = {
-    "sys_read",                      /* 000 */
-    "sys_write",                     /* 001 */
-    "sys_open",                      /* 002 */
-    "sys_close",                     /* 003 */
-    "sys_newstat",                   /* 004 */
-    "sys_newfstat",                  /* 005 */
-    "sys_newlstat",                  /* 006 */
-    "sys_poll",                      /* 007 */
-    "sys_lseek",                     /* 008 */
-    "sys_mmap",                      /* 009 */
-    "sys_mprotect",                  /* 010 */
-    "sys_munmap",                    /* 011 */
-    "sys_brk",                       /* 012 */
-    "sys_rt_sigaction",              /* 013 */
-    "sys_rt_sigprocmask",            /* 014 */
-    "stub_rt_sigreturn",             /* 015 */
-    "sys_ioctl",                     /* 016 */
-    "sys_pread64",                   /* 017 */
-    "sys_pwrite64",                  /* 018 */
-    "sys_readv",                     /* 019 */
-    "sys_writev",                    /* 020 */
-    "sys_access",                    /* 021 */
-    "sys_pipe",                      /* 022 */
-    "sys_select",                    /* 023 */
-    "sys_sched_yield",               /* 024 */
-    "sys_mremap",                    /* 025 */
-    "sys_msync",                     /* 026 */
-    "sys_mincore",                   /* 027 */
-    "sys_madvise",                   /* 028 */
-    "sys_shmget",                    /* 029 */
-    "sys_shmat",                     /* 030 */
-    "sys_shmctl",                    /* 031 */
-    "sys_dup",                       /* 032 */
-    "sys_dup2",                      /* 033 */
-    "sys_pause",                     /* 034 */
-    "sys_nanosleep",                 /* 035 */
-    "sys_getitimer",                 /* 036 */
-    "sys_alarm",                     /* 037 */
-    "sys_setitimer",                 /* 038 */
-    "sys_getpid",                    /* 039 */
-    "sys_sendfile64",                /* 040 */
-    "sys_socket",                    /* 041 */
-    "sys_connect",                   /* 042 */
-    "sys_accept",                    /* 043 */
-    "sys_sendto",                    /* 044 */
-    "sys_recvfrom",                  /* 045 */
-    "sys_sendmsg",                   /* 046 */
-    "sys_recvmsg",                   /* 047 */
-    "sys_shutdown",                  /* 048 */
-    "sys_bind",                      /* 049 */
-    "sys_listen",                    /* 050 */
-    "sys_getsockname",               /* 051 */
-    "sys_getpeername",               /* 052 */
-    "sys_socketpair",                /* 053 */
-    "sys_setsockopt",                /* 054 */
-    "sys_getsockopt",                /* 055 */
-    "stub_clone",                    /* 056 */
-    "stub_fork",                     /* 057 */
-    "stub_vfork",                    /* 058 */
-    "stub_execve",                   /* 059 */
-    "sys_exit",                      /* 060 */
-    "sys_wait4",                     /* 061 */
-    "sys_kill",                      /* 062 */
-    "sys_uname",                     /* 063 */
-    "sys_semget",                    /* 064 */
-    "sys_semop",                     /* 065 */
-    "sys_semctl",                    /* 066 */
-    "sys_shmdt",                     /* 067 */
-    "sys_msgget",                    /* 068 */
-    "sys_msgsnd",                    /* 069 */
-    "sys_msgrcv",                    /* 070 */
-    "sys_msgctl",                    /* 071 */
-    "sys_fcntl",                     /* 072 */
-    "sys_flock",                     /* 073 */
-    "sys_fsync",                     /* 074 */
-    "sys_fdatasync",                 /* 075 */
-    "sys_truncate",                  /* 076 */
-    "sys_ftruncate",                 /* 077 */
-    "sys_getdents",                  /* 078 */
-    "sys_getcwd",                    /* 079 */
-    "sys_chdir",                     /* 080 */
-    "sys_fchdir",                    /* 081 */
-    "sys_rename",                    /* 082 */
-    "sys_mkdir",                     /* 083 */
-    "sys_rmdir",                     /* 084 */
-    "sys_creat",                     /* 085 */
-    "sys_link",                      /* 086 */
-    "sys_unlink",                    /* 087 */
-    "sys_symlink",                   /* 088 */
-    "sys_readlink",                  /* 089 */
-    "sys_chmod",                     /* 090 */
-    "sys_fchmod",                    /* 091 */
-    "sys_chown",                     /* 092 */
-    "sys_fchown",                    /* 093 */
-    "sys_lchown",                    /* 094 */
-    "sys_umask",                     /* 095 */
-    "sys_gettimeofday",              /* 096 */
-    "sys_getrlimit",                 /* 097 */
-    "sys_getrusage",                 /* 098 */
-    "sys_sysinfo",                   /* 099 */
-    "sys_times",                     /* 100 */
-    "sys_ptrace",                    /* 101 */
-    "sys_getuid",                    /* 102 */
-    "sys_syslog",                    /* 103 */
-    "sys_getgid",                    /* 104 */
-    "sys_setuid",                    /* 105 */
-    "sys_setgid",                    /* 106 */
-    "sys_geteuid",                   /* 107 */
-    "sys_getegid",                   /* 108 */
-    "sys_setpgid",                   /* 109 */
-    "sys_getppid",                   /* 110 */
-    "sys_getpgrp",                   /* 111 */
-    "sys_setsid",                    /* 112 */
-    "sys_setreuid",                  /* 113 */
-    "sys_setregid",                  /* 114 */
-    "sys_getgroups",                 /* 115 */
-    "sys_setgroups",                 /* 116 */
-    "sys_setresuid",                 /* 117 */
-    "sys_getresuid",                 /* 118 */
-    "sys_setresgid",                 /* 119 */
-    "sys_getresgid",                 /* 120 */
-    "sys_getpgid",                   /* 121 */
-    "sys_setfsuid",                  /* 122 */
-    "sys_setfsgid",                  /* 123 */
-    "sys_getsid",                    /* 124 */
-    "sys_capget",                    /* 125 */
-    "sys_capset",                    /* 126 */
-    "sys_rt_sigpending",             /* 127 */
-    "sys_rt_sigtimedwait",           /* 128 */
-    "sys_rt_sigqueueinfo",           /* 129 */
-    "sys_rt_sigsuspend",             /* 130 */
-    "stub_sigaltstack",              /* 131 */
-    "sys_utime",                     /* 132 */
-    "sys_mknod",                     /* 133 */
-    "sys_ni_syscall",                /* 134 */
-    "sys_personality",               /* 135 */
-    "sys_ustat",                     /* 136 */
-    "sys_statfs",                    /* 137 */
-    "sys_fstatfs",                   /* 138 */
-    "sys_sysfs",                     /* 139 */
-    "sys_getpriority",               /* 140 */
-    "sys_setpriority",               /* 141 */
-    "sys_sched_setparam",            /* 142 */
-    "sys_sched_getparam",            /* 143 */
-    "sys_sched_setscheduler",        /* 144 */
-    "sys_sched_getscheduler",        /* 145 */
-    "sys_sched_get_priority_max",    /* 146 */
-    "sys_sched_get_priority_min",    /* 147 */
-    "sys_sched_rr_get_interval",     /* 148 */
-    "sys_mlock",                     /* 149 */
-    "sys_munlock",                   /* 150 */
-    "sys_mlockall",                  /* 151 */
-    "sys_munlockall",                /* 152 */
-    "sys_vhangup",                   /* 153 */
-    "sys_modify_ldt",                /* 154 */
-    "sys_pivot_root",                /* 155 */
-    "sys_sysctl",                    /* 156 */
-    "sys_prctl",                     /* 157 */
-    "sys_arch_prctl",                /* 158 */
-    "sys_adjtimex",                  /* 159 */
-    "sys_setrlimit",                 /* 160 */
-    "sys_chroot",                    /* 161 */
-    "sys_sync",                      /* 162 */
-    "sys_acct",                      /* 163 */
-    "sys_settimeofday",              /* 164 */
-    "sys_mount",                     /* 165 */
-    "sys_umount",                    /* 166 */
-    "sys_swapon",                    /* 167 */
-    "sys_swapoff",                   /* 168 */
-    "sys_reboot",                    /* 169 */
-    "sys_sethostname",               /* 170 */
-    "sys_setdomainname",             /* 171 */
-    "stub_iopl",                     /* 172 */
-    "sys_ioperm",                    /* 173 */
-    "sys_ni_syscall",                /* 174 */
-    "sys_init_module",               /* 175 */
-    "sys_delete_module",             /* 176 */
-    "sys_ni_syscall",                /* 177 */
-    "sys_ni_syscall",                /* 178 */
-    "sys_quotactl",                  /* 179 */
-    "sys_nfsservctl",                /* 180 */
-    "sys_ni_syscall",                /* 181 */
-    "sys_ni_syscall",                /* 182 */
-    "sys_ni_syscall",                /* 183 */
-    "sys_ni_syscall",                /* 184 */
-    "sys_ni_syscall",                /* 185 */
-    "sys_gettid",                    /* 186 */
-    "sys_readahead",                 /* 187 */
-    "sys_setxattr",                  /* 188 */
-    "sys_lsetxattr",                 /* 189 */
-    "sys_fsetxattr",                 /* 190 */
-    "sys_getxattr",                  /* 191 */
-    "sys_lgetxattr",                 /* 192 */
-    "sys_fgetxattr",                 /* 193 */
-    "sys_listxattr",                 /* 194 */
-    "sys_llistxattr",                /* 195 */
-    "sys_flistxattr",                /* 196 */
-    "sys_removexattr",               /* 197 */
-    "sys_lremovexattr",              /* 198 */
-    "sys_fremovexattr",              /* 199 */
-    "sys_tkill",                     /* 200 */
-    "sys_time",                      /* 201 */
-    "sys_futex",                     /* 202 */
-    "sys_sched_setaffinity",         /* 203 */
-    "sys_sched_getaffinity",         /* 204 */
-    "sys_ni_syscall",                /* 205 */
-    "sys_io_setup",                  /* 206 */
-    "sys_io_destroy",                /* 207 */
-    "sys_io_getevents",              /* 208 */
-    "sys_io_submit",                 /* 209 */
-    "sys_io_cancel",                 /* 210 */
-    "sys_ni_syscall",                /* 211 */
-    "sys_lookup_dcookie",            /* 212 */
-    "sys_epoll_create",              /* 213 */
-    "sys_ni_syscall",                /* 214 */
-    "sys_ni_syscall",                /* 215 */
-    "sys_remap_file_pages",          /* 216 */
-    "sys_getdents64",                /* 217 */
-    "sys_set_tid_address",           /* 218 */
-    "sys_restart_syscall",           /* 219 */
-    "sys_semtimedop",                /* 220 */
-    "sys_fadvise64",                 /* 221 */
-    "sys_timer_create",              /* 222 */
-    "sys_timer_settime",             /* 223 */
-    "sys_timer_gettime",             /* 224 */
-    "sys_timer_getoverrun",          /* 225 */
-    "sys_timer_delete",              /* 226 */
-    "sys_clock_settime",             /* 227 */
-    "sys_clock_gettime",             /* 228 */
-    "sys_clock_getres",              /* 229 */
-    "sys_clock_nanosleep",           /* 230 */
-    "sys_exit_group",                /* 231 */
-    "sys_epoll_wait",                /* 232 */
-    "sys_epoll_ctl",                 /* 233 */
-    "sys_tgkill",                    /* 234 */
-    "sys_utimes",                    /* 235 */
-    "sys_ni_syscall",                /* 236 */
-    "sys_mbind",                     /* 237 */
-    "sys_set_mempolicy",             /* 238 */
-    "sys_get_mempolicy",             /* 239 */
-    "sys_mq_open",                   /* 240 */
-    "sys_mq_unlink",                 /* 241 */
-    "sys_mq_timedsend",              /* 242 */
-    "sys_mq_timedreceive",           /* 243 */
-    "sys_mq_notify",                 /* 244 */
-    "sys_mq_getsetattr",             /* 245 */
-    "sys_kexec_load",                /* 246 */
-    "sys_waitid",                    /* 247 */
-    "sys_add_key",                   /* 248 */
-    "sys_request_key",               /* 249 */
-    "sys_keyctl",                    /* 250 */
-    "sys_ioprio_set",                /* 251 */
-    "sys_ioprio_get",                /* 252 */
-    "sys_inotify_init",              /* 253 */
-    "sys_inotify_add_watch",         /* 254 */
-    "sys_inotify_rm_watch",          /* 255 */
-    "sys_migrate_pages",             /* 256 */
-    "sys_openat",                    /* 257 */
-    "sys_mkdirat",                   /* 258 */
-    "sys_mknodat",                   /* 259 */
-    "sys_fchownat",                  /* 260 */
-    "sys_futimesat",                 /* 261 */
-    "sys_newfstatat",                /* 262 */
-    "sys_unlinkat",                  /* 263 */
-    "sys_renameat",                  /* 264 */
-    "sys_linkat",                    /* 265 */
-    "sys_symlinkat",                 /* 266 */
-    "sys_readlinkat",                /* 267 */
-    "sys_fchmodat",                  /* 268 */
-    "sys_faccessat",                 /* 269 */
-    "sys_pselect6",                  /* 270 */
-    "sys_ppoll",                     /* 271 */
-    "sys_unshare",                   /* 272 */
-    "sys_set_robust_list",           /* 273 */
-    "sys_get_robust_list",           /* 274 */
-    "sys_splice",                    /* 275 */
-    "sys_tee",                       /* 276 */
-    "sys_sync_file_range",           /* 277 */
-    "sys_vmsplice",                  /* 278 */
-    "sys_move_pages",                /* 279 */
-    "sys_utimensat",                 /* 280 */
-    "sys_epoll_pwait",               /* 281 */
-    "sys_signalfd",                  /* 282 */
-    "sys_timerfd_create",            /* 283 */
-    "sys_eventfd",                   /* 284 */
-    "sys_fallocate",                 /* 285 */
-    "sys_timerfd_settime",           /* 286 */
-    "sys_timerfd_gettime",           /* 287 */
-    "sys_accept4",                   /* 288 */
-    "sys_signalfd4",                 /* 289 */
-    "sys_eventfd2",                  /* 290 */
-    "sys_epoll_create1",             /* 291 */
-    "sys_dup3",                      /* 292 */
-    "sys_pipe2",                     /* 293 */
-    "sys_inotify_init1",             /* 294 */
-    "sys_preadv",                    /* 295 */
-    "sys_pwritev",                   /* 296 */
-    "sys_rt_tgsigqueueinfo",         /* 297 */
-    "sys_perf_event_open",           /* 298 */
-    "sys_recvmmsg",                  /* 299 */
-    NULL
-};
-
-/* i386 sys_call_table for kernel 2.4.x
- */
-char * syscalls_32[] = {
-    "sys_restart_syscall",    /* 0 - old setup() system call*/
-    "sys_exit",
-    "sys_fork",
-    "sys_read",
-    "sys_write",
-    "sys_open",        /* 5 */
-    "sys_close",
-    "sys_waitpid",
-    "sys_creat",
-    "sys_link",
-    "sys_unlink",        /* 10 */
-    "sys_execve",
-    "sys_chdir",
-    "sys_time",
-    "sys_mknod",
-    "sys_chmod",        /* 15 */
-    "sys_lchown16",
-    "sys_break",
-    "sys_stat",
-    "sys_lseek",
-    "sys_getpid",        /* 20 */
-    "sys_mount",
-    "sys_oldumount",
-    "sys_setuid16",
-    "sys_getuid16",
-    "sys_stime",        /* 25 */
-    "sys_ptrace",
-    "sys_alarm",
-    "sys_fstat",
-    "sys_pause",
-    "sys_utime",        /* 30 */
-    "sys_stty",
-    "sys_gtty",
-    "sys_access",
-    "sys_nice",
-    "sys_ftime",        /* 35 */
-    "sys_sync",
-    "sys_kill",
-    "sys_rename",
-    "sys_mkdir",
-    "sys_rmdir",        /* 40 */
-    "sys_dup",
-    "sys_pipe",
-    "sys_times",
-    "sys_prof",
-    "sys_brk",        /* 45 */
-    "sys_setgid16",
-    "sys_getgid16",
-    "sys_signal",
-    "sys_geteuid16",
-    "sys_getegid16",    /* 50 */
-    "sys_acct",
-    "sys_umount2",
-    "sys_lock",
-    "sys_ioctl",
-    "sys_fcntl",        /* 55 */
-    "sys_mpx",
-    "sys_setpgid",
-    "sys_ulimit",
-    "sys_olduname",
-    "sys_umask",        /* 60 */
-    "sys_chroot",
-    "sys_ustat",
-    "sys_dup2",
-    "sys_getppid",
-    "sys_getpgrp",        /* 65 */
-    "sys_setsid",
-    "sys_sigaction",
-    "sys_sgetmask",
-    "sys_ssetmask",
-    "sys_setreuid16",    /* 70 */
-    "sys_setregid16",
-    "sys_sigsuspend",
-    "sys_sigpending",
-    "sys_sethostname",
-    "sys_setrlimit",    /* 75 */
-    "sys_getrlimit",
-    "sys_getrusage",
-    "sys_gettimeofday",
-    "sys_settimeofday",
-    "sys_getgroups16",    /* 80 */
-    "sys_setgroups16",
-    "old_select",
-    "sys_symlink",
-    "sys_lstat",
-    "sys_readlink",        /* 85 */
-    "sys_uselib",
-    "sys_swapon",
-    "sys_reboot",
-    "old_readdir",
-    "old_mmap",        /* 90 */
-    "sys_munmap",
-    "sys_truncate",
-    "sys_ftruncate",
-    "sys_fchmod",
-    "sys_fchown16",        /* 95 */
-    "sys_getpriority",
-    "sys_setpriority",
-    "sys_profil",
-    "sys_statfs",
-    "sys_fstatfs",        /* 100 */
-    "sys_ioperm",
-    "sys_socketcall",
-    "sys_syslog",
-    "sys_setitimer",
-    "sys_getitimer",    /* 105 */
-    "sys_newstat",
-    "sys_newlstat",
-    "sys_newfstat",
-    "sys_olduname",
-    "sys_iopl",        /* 110 */
-    "sys_vhangup",
-    "sys_idle",
-    "sys_vm86old",
-    "sys_wait4",
-    "sys_swapoff",        /* 115 */
-    "sys_sysinfo",
-    "sys_ipc",
-    "sys_fsync",
-    "sys_sigreturn",
-    "sys_clone",        /* 120 */
-    "sys_setdomainname",
-    "sys_newuname",
-    "sys_modify_ldt",
-    "sys_adjtimex",
-    "sys_mprotect",        /* 125 */
-    "sys_sigprocmask",
-    "sys_create_module",
-    "sys_init_module",
-    "sys_delete_module",
-    "sys_get_kernel_syms",    /* 130 */
-    "sys_quotactl",
-    "sys_getpgid",
-    "sys_fchdir",
-    "sys_bdflush",
-    "sys_sysfs",        /* 135 */
-    "sys_personality",
-    "sys_afs_syscall",
-    "sys_setfsuid16",
-    "sys_setfsgid16",
-    "sys_llseek",        /* 140 */
-    "sys_getdents",
-    "sys_select",
-    "sys_flock",
-    "sys_msync",
-    "sys_readv",        /* 145 */
-    "sys_writev",
-    "sys_getsid",
-    "sys_fdatasync",
-    "sys__sysctl",
-    "sys_mlock",        /* 150 */
-    "sys_munlock",
-    "sys_mlockall",
-    "sys_munlockall",
-    "sys_sched_setparam",
-    "sys_sched_getparam",  /* 155 */
-    "sys_sched_setscheduler",
-    "sys_sched_getscheduler",
-    "sys_sched_yield",
-    "sys_sched_get_priority_max",
-    "sys_sched_get_priority_min", /* 160 */
-    "sys_sched_rr_get_interval",
-    "sys_nanosleep",
-    "sys_mremap",
-    "sys_setresuid",
-    "sys_getresuid",    /* 165 */
-    "sys_vm86",
-    "sys_query_module",
-    "sys_poll",
-    "sys_nfsservctl",
-    "sys_setresgid",    /* 170 */
-    "sys_getresgid",
-    "sys_prctl",
-    "sys_rt_sigreturn",
-    "sys_rt_sigaction",
-    "sys_rt_sigprocmask",    /* 175 */
-    "sys_rt_sigpending",
-    "sys_rt_sigtimedwait",
-    "sys_rt_sigqueueinfo",
-    "sys_rt_sigsuspend",
-    "sys_pread",        /* 180 */
-    "sys_pwrite",
-    "sys_chown16",
-    "sys_getcwd",
-    "sys_capget",
-    "sys_capset",      /* 185 */
-    "sys_sigaltstack",
-    "sys_sendfile",
-    "sys_getpmsg",        /* streams1 */
-    "sys_putpmsg",        /* streams2 */
-    "sys_vfork",      /* 190 */
-    "sys_ugetrlimit",
-    "sys_mmap2",
-    "sys_truncate64",
-    "sys_ftruncate64",
-    "sys_stat64",        /* 195 */
-    "sys_lstat64",
-    "sys_fstat64",
-    "sys_lchown32",
-    "sys_getuid32",
-    "sys_getgid32",        /* 200 */
-    "sys_geteuid32",
-    "sys_getegid32",
-    "sys_setreuid32",
-    "sys_setregid32",
-    "sys_getgroups32",    /* 205 */
-    "sys_setgroups32",
-    "sys_fchown32",
-    "sys_setresuid32",
-    "sys_getresuid32",
-    "sys_setresgid32",    /* 210 */
-    "sys_getresgid32",
-    "sys_chown32",
-    "sys_setuid32",
-    "sys_setgid32",
-    "sys_setfsuid32",        /* 215 */
-    "sys_setfsgid32",
-    "sys_pivot_root",
-    "sys_mincore",
-    "sys_madvise",
-    "sys_getdents64",    /* 220 */
-    "sys_fcntl64",
-    "sys_tux",     /* reserved for TUX, unused */
-    "sys_security",
-    "sys_gettid",
-    "sys_readahead",     /* 225 */
-    "sys_setxattr",
-    "sys_lsetxattr",
-    "sys_fsetxattr",
-    "sys_getxattr",
-    "sys_lgetxattr",     /* 230 */
-    "sys_fgetxattr",
-    "sys_listxattr",
-    "sys_llistxattr",
-    "sys_flistxattr",
-    "sys_removexattr",   /* 235 */
-    "sys_lremovexattr",
-    "sys_fremovexattr",
-    "sys_tkill",
-    "sys_sendfile64",
-    "sys_futex",         /* 240 */
-    "sys_sched_setaffinity",
-    "sys_sched_getaffinity",
-    "sys_set_thread_area",
-    "sys_get_thread_area",   
-    "sys_io_setup",           /* 245 */
-    "sys_io_destroy",         
-    "sys_io_getevents",       
-    "sys_io_submit",          
-    "sys_io_cancel",          
-    "sys_alloc_hugepages",    /* 250 */
-    "sys_free_hugepages",     
-    "sys_exit_group",         
-    "sys_lookup_dcookie",     /* 2.6 */
-    "sys_epoll_create",
-    "sys_epoll_ctl",          /* 255 */
-    "sys_epoll_wait",
-    "sys_remap_file_pages",
-    "sys_set_tid_address",
-    "sys_timer_create",
-    "sys_timer_settime",      /* 260 */
-    "sys_timer_gettime",
-    "sys_timer_getoverrun",
-    "sys_timer_delete",
-    "sys_clock_settime",
-    "sys_clock_gettime",      /* 265 */
-    "sys_clock_getres",
-    "sys_clock_nanosleep",
-    "sys_statfs64",
-    "sys_fstatfs64",
-    "sys_tgkill",             /* 270 */
-    "sys_utimes",
-    "sys_fadvise64_64",
-    "sys_vserver",            /* last 2.4 */
-    "sys_mbind",
-    "sys_get_mempolicy",      /* 275 */
-    "sys_set_mempolicy",
-    "sys_mq_open",
-    "sys_mq_unlink",
-    "sys_mq_timedsend",
-    "sys_mq_timedreceive",    /* 280 */
-    "sys_mq_notify",
-    "sys_mq_getsetattr",
-    "sys_kexec_load",
-    "sys_waitid",
-    "sys_sys_setaltroot",     /* 285 */
-    "sys_add_key",
-    "sys_request_key",
-    "sys_keyctl",
-    "sys_ioprio_set",
-    "sys_ioprio_get",         /* 290 */
-    "sys_inotify_init",
-    "sys_inotify_add_watch",
-    "sys_inotify_rm_watch",
-    "sys_migrate_pages",
-    "sys_openat",             /* 295 */
-    "sys_mkdirat",
-    "sys_mknodat",
-    "sys_fchownat",
-    "sys_futimesat",
-    "sys_fstatat64",          /* 300 */
-    "sys_unlinkat",
-    "sys_renameat",
-    "sys_linkat",
-    "sys_symlinkat",
-    "sys_readlinkat",         /* 305 */
-    "sys_fchmodat",
-    "sys_faccessat",
-    "sys_pselect6",
-    "sys_ppoll",
-    "sys_unshare",            /* 310 */
-    "sys_set_robust_list",
-    "sys_get_robust_list",
-    "sys_splice",
-    "sys_sync_file_range",
-    "sys_tee",                /* 315 */
-    "sys_vmsplice",
-    "sys_move_pages",
-    "sys_getcpu",
-    "sys_epoll_pwait",
-    "sys_utimensat",          /* 320 */
-    "sys_signalfd",
-    "sys_timerfd_create",
-    "sys_eventfd",
-    "sys_fallocate",          /* last 2.6.24 */
-    "sys_timerfd_settime",    /* 325 */
-    "sys_timerfd_gettime",
-    "sys_signalfd4",
-    "sys_eventfd2",
-    "sys_epoll_create1",
-    "sys_dup3",               /* 330 */
-    "sys_pipe2",
-    "sys_inotify_init1",      /* end 2.6.27 */
-    "sys_preadv",
-    "sys_pwritev",            /* end 2.6.30 */
-    "sys_rt_tgsigqueueinfo",  /* 335 */
-    "sys_perf_event_open",    /* end 2.6.31 */
-    "sys_recvmmsg",
-    NULL
-};
-
-
-
-/* i386 sys_call_table for openbsd
- */
-char * callz_obsd[]={
-  "_nosys",               /*   0 */
-  "_sys_exit",
-  "_sys_fork",
-  "_sys_read",
-  "_sys_write",
-  "_sys_open",            /*   5 */
-  "_sys_close",
-  "_sys_wait4",
-  "_compat_43_sys_creat",
-  "_sys_link",
-  "_sys_unlink",          /*  10 */
-  "_sys_nosys",
-  "_sys_chdir",
-  "_sys_fchdir",
-  "_sys_mknod",
-  "_sys_chmod",           /*  15 */
-  "_sys_chown",
-  "_sys_break",
-  "_nosys",
-  "_compat_43_sys_lseek",
-  "_sys_getpid",          /*  20 */       
-  "_sys_mount",
-  "_sys_unmount",
-  "_sys_setuid",
-  "_sys_getuid",
-  "_sys_geteuid",         /*  25 */
-  "_sys_ptrace",
-  "_sys_recvmsg",  /*	27 */
-  "_sys_sendmsg",  /*	28 */
-  "_sys_recvfrom", /*	29 */
-  "_sys_accept",   /*	30 */
-  "_sys_getpeername", /*	31 */
-  "_sys_getsockname", /*	32 */
-  "_sys_access",   /*	33 */
-  "_sys_chflags",  /*	34 */
-  "_sys_fchflags", /*	35 */
-  "_sys_sync",     /*	36 */
-  "_sys_kill",     /*	37 */
-  "_compat_43_sys_stat",			/* 38 is old stat */
-  "_sys_getppid",  /*	39 */
-  "_compat_43_sys_lstat",		        /* 40 is old lstat */
-  "_sys_dup",      /*	41 */
-  "_sys_opipe",    /*	42 */
-  "_sys_getegid",  /*	43 */
-  "_sys_profil",   /*	44 */
-  "_sys_ktrace",   /*	45 */
-  "_sys_sigaction",/*       46 */
-  "_sys_getgid",   /*	47 */
-  "_sys_sigprocmask",
-  "_sys_getlogin", /*	49 */
-  "_sys_setlogin", /*	50 */
-  "_sys_acct",     /*	51 */
-  "_sys_sigpending",
-  "_sys_osigaltstack", /*	53 */
-  "_sys_ioctl",    /*	54 */
-  "_sys_reboot",   /*	55 */
-  "_sys_revoke",   /*	56 */
-  "_sys_symlink",  /*	57 */
-  "_sys_readlink", /*	58 */
-  "_sys_execve",   /*	59 */
-  "_sys_umask",    /*	60 */
-  "_sys_chroot",   /*	61 */
-  "_compat_43_sys_fstat",			/* 62 is old fstat */
-  "_compat_43_sys_getkerninfo",			/* 63 is old ogetkerninfo */
-  "_compat_43_sys_getpagesize",			/* 64 is old ogetpagesize */
-  "_nosys",                     /* 65 is omsync */
-  "_sys_vfork",    /*	66 */
-  "_nosys",			/* 67 is obsolete vread */
-  "_nosys",			/* 68 is obsolete vwrite */
-  "_sys_sbrk",     /*	69 */
-  "_sys_sstk",     /*	70 */
-  "_compat_43_sys_mmap",			/* 71 is ommap */
-  "_sys_ovadvise",  /*	72 */
-  "_sys_munmap",   /*	73 */
-  "_sys_mprotect", /*	74 */
-  "_sys_madvise",  /*	75 */
-  "_nosys",			/* 76 is obsolete vhangup */
-  "_nosys",			/* 77 is obsolete vlimit */
-  "_sys_mincore",  /*	78 */
-  "_sys_getgroups",/*	79 */
-  "_sys_setgroups",/*	80 */
-  "_sys_getpgrp",  /*	81 */
-  "_sys_setpgid",  /*	82 */
-  "_sys_setitimer",/*	83 */
-  "_compat_43_sys_wait",			/* 84 is owait */
-  "_nosys",                      /* 85 is swapon */
-  "_sys_getitimer",/*	86 */
-  "_compat_43_sys_gethostname",			/* 87 is ogethostname */
-  "_compat_43_sys_sethostname",			/* 88 is osethostname */
-  "_compat_43_sys_getdtablesize",               /* 89 os ogetdtablesize */
-  "_sys_dup2",     /*	90 */
-  "_nosys",			/* 91 is ??? */
-  "_sys_fcntl",    /*	92 */
-  "_sys_select",   /*	93 */
-  "_nosys",			/* 94 is ??? */
-  "_sys_fsync",    /*	95 */
-  "_sys_setpriority", /*	96 */
-  "_sys_socket",   /*	97 */
-  "_sys_connect",  /*	98 */
-  "_compat_43_sys_accept",			/* 99 is oaccept */
-  "_sys_getpriority", /*	100 */
-  "_compat_43_sys_send",			/* 101 is osend */
-  "_compat_43_sys_recv",			/* 102 is orecv */
-  "_sys_sigreturn",
-  "_sys_bind",     /*	104 */
-  "_sys_setsockopt", /*	105 */
-  "_sys_listen",   /*	106 */
-  "_nosys",			/* 107 is obsolete vtimes */
-  "_compat_43_sys_sigvec",			/* 108 is osigvec */
-  "_compat_43_sys_sigblock",			/* 109 is osigblock */
-  "_compat_43_sys_sigsetmask",			/* 110 is osigsetmask */
-  "_sys_sigsuspend",
-  "_compat_43_sys_sigstack",			/* 112 is osigstack */
-  "_compat_43_sys_recvmsg",			/* 113 is orecvmsg */
-  "_compat_43_sys_sendmsg",			/* 114 is osendmsg */
-  "_nosys",			/* 115 is obsolete vtrace */
-  "_sys_gettimeofday", /*	116 */ 
-  "_sys_getrusage",    /*	117 */
-  "_sys_getsockopt",   /*	118 */
-  "_nosys",			/* 119 is obsolete resuba */
-  "_sys_readv",        /*	120 */
-  "_sys_writev",       /*	121 */
-  "_sys_settimeofday", /*	122 */
-  "_sys_fchown",       /*	123 */
-  "_sys_fchmod",       /*	124 */
-  "_compat_43_sys_recvfrom",			/* 125 is orecvfrom */
-  "_sys_setreuid",     /*	126 */
-  "_sys_setregid",     /*	127 */
-  "_sys_rename",       /*	128 */
-  "_compat_43_sys_truncate",			/* 129 is old truncate */
-  "_compat_43_sys_ftruncate",			/* 130 is old ftruncate */
-  "_sys_flock",        /*	131 */
-  "_sys_mkfifo",       /*	132 */
-  "_sys_sendto",       /*	133 */
-  "_sys_shutdown",     /*	134 */
-  "_sys_socketpair",   /*	135 */
-  "_sys_mkdir",        /*	136 */
-  "_sys_rmdir",        /*	137 */
-  "_sys_utimes",       /*	138 */
-  "_nosys",			/* 139 is obsolete 4.2 sigreturn */
-  "_sys_adjtime",      /*	140 */
-  "_compat_43_sys_getpeername",			/* 141 is ogetpeername */
-  "_compat_43_sys_gethostid",			/* 142 is ogethostid */
-  "_compat_43_sys_sethostid",			/* 143 is osethostid */
-  "_compat_43_sys_getrlimit",			/* 144 is ogetrlimit */
-  "_compat_43_sys_setrlimit",			/* 145 is osetrlimit */
-  "_compat_43_sys_killpg",			/* 146 is okillpg */
-  "_sys_setsid",       /*	147 */
-  "_sys_quotactl",     /*	148 */
-  "_compat_43_sys_quota",			/* 149 is oquota */
-  "_compat_43_sys_getsockname",			/* 150 is ogetsockname */
-  "_nosys",			/* 151 is ??? */
-  "_nosys",			/* 152 is ??? */
-  "_nosys",			/* 153 is ??? */
-  "_nosys",			/* 154 is ??? */
-  "_sys_nfssvc",       /*	155 */
-  "_compat_43_sys_getdirentries",	        /* 156 is ogetdirentries */
-  "_nosys",                      /* 157 is ostatfs */
-  "_nosys",                     /* 158 is ofstatfs */
-  "_nosys",			/* 159 is ??? */
-  "_nosys",			/* 160 is ??? */
-  "_sys_getfh",        /*	161 */
-  "_nosys",               /* 162 is ogetdomainname */
-  "_nosys",               /* 163 is osetdomainname */
-  "_nosys",                       /* 164 is ouname */
-  "_sys_sysarch",      /*	165 */
-  "_nosys",
-  "_nosys",			/* 167 is ??? */
-  "_nosys",			/* 168 is ??? */
-  "_nosys",       /*	169 is compat_10 osemsys */
-  "_nosys",       /*	170 is compat_10 omsgsys */
-  "_nosys",       /*	171 is compat_10 oshmsys */
-  "_nosys",			/* 172 is ??? */
-  "_sys_pread",        /*	173 */
-  "_sys_pwrite",       /*	174 */
-  "_nosys",			/* 175 is ??? */
-  "_nosys",                     /* 176 is ??? */
-  "_nosys",			/* 177 is ??? */
-  "_nosys",			/* 178 is ??? */
-  "_nosys",			/* 179 is ??? */
-  "_nosys",			/* 180 is ??? */
-  "_sys_setgid",       /*	181 */
-  "_sys_setegid",      /*	182 */
-  "_sys_seteuid",      /*	183 */
-  "_sys_bmapv",	   /*   184 */
-  "_sys_markv",	   /*   185 */
-  "_sys_segclean",	   /*   186 */
-  "_sys_segwait",	   /*   187 */
-  "_compat_35_sys_stat",        /*	188 is compat_35 stat35 */
-  "_compat_35_sys_fstat",       /*	189 is compat_35 fstat35 */
-  "_compat_35_sys_lstat",       /*	190 is compat_35 lstat35 */
-  "_sys_pathconf",     /*	191 */
-  "_sys_fpathconf",    /*	192 */
-  "_sys_swapctl",	   /*   193 */
-  "_sys_getrlimit",    /*	194 */
-  "_sys_setrlimit",    /*	195 */
-  "_sys_getdirentries", /*	196 */
-  "_sys_mmap",         /*	197 */
-  "_sys___syscall",    /*	198 */
-  "_sys_lseek",        /*	199 */
-  "_sys_truncate",     /*	200 */
-  "_sys_ftruncate",    /*	201 */
-  "_sys___sysctl",     /*	202 */
-  "_sys_mlock",        /*	203 */
-  "_sys_munlock",      /*	204 */
-  "_sys_undelete",     /*	205 */
-  "_sys_futimes",      /*	206 */
-  "_sys_getpgid",      /*	207 */
-  "_sys_xfspioctl",    /*   208 */
-  "_nosys",                     /* 209 is ??? */
-  "_nosys",			/* 210 is ??? */
-  "_nosys",			/* 211 is ??? */
-  "_nosys",			/* 212 is ??? */
-  "_nosys",			/* 213 is ??? */
-  "_nosys",			/* 214 is ??? */
-  "_nosys",			/* 215 is ??? */
-  "_nosys",			/* 216 is ??? */
-  "_nosys",			/* 217 is ??? */
-  "_nosys",			/* 218 is ??? */
-  "_nosys",			/* 219 is ??? */
-  "_nosys",                     /* 220 is ??? */
-  "_sys_semget",       /*	221 */
-  "_compat_35_sys_semop",       /* 222 is compat_35 semop */
-  "_nosys",			/* 223 is obsolete sys_semconfig */
-  "_nosys",                     /* 224 is compat_23 msgctl23 */
-  "_sys_msgget",       /*	225 */
-  "_sys_msgsnd",       /*	226 */
-  "_sys_msgrcv",       /*	227 */
-  "_sys_shmat",        /*	228 */
-  "_nosys",                     /* 229 is compat_23 shmctl23 */
-  "_sys_shmdt",        /*	230 */
-  "_compat_35_sys_shmget",      /* 231 is compat_35 shmget */
-  "_sys_clock_gettime", /*	232 */
-  "_sys_clock_settime", /*	233 */
-  "_sys_clock_getres", /*	234 */
-  "_nosys",			/* 235 is ??? */
-  "_nosys",			/* 236 is ??? */
-  "_nosys",			/* 237 is ??? */
-  "_nosys",			/* 238 is ??? */
-  "_nosys",			/* 239 is ??? */
-  "_sys_nanosleep",    /*	240 */
-  "_nosys",			/* 241 is ??? */
-  "_nosys",			/* 242 is ??? */
-  "_nosys",			/* 243 is ??? */
-  "_nosys",			/* 244 is ??? */
-  "_nosys",			/* 245 is ??? */
-  "_nosys",			/* 246 is ??? */
-  "_nosys",			/* 247 is ??? */
-  "_nosys",			/* 248 is ??? */
-  "_nosys",			/* 249 is ??? */
-  "_sys_minherit",     /*	250 */
-  "_sys_rfork",        /*	251 */
-  "_sys_poll",         /*	252 */
-  "_sys_issetugid",    /*	253 */
-  "_sys_lchown",       /*	254 */
-  "_sys_getsid",	   /*   255 */
-  "_sys_msync",	   /*   256 */
-  "_compat_35_sys___semctl",		/* 257 is compat_35 semctl35 */
-  "_compat_35_sys_shmctl",		/* 258 is is compat_35 shmctl35 */
-  "_compat_35_sys_msgctl",		/* 259 is is compat_35 msgctl35 */
-  "_sys_getfsstat",	   /* 260  */
-  "_sys_statfs",	   /* 261  */
-  "_sys_fstatfs",	   /* 262  */
-  "_sys_pipe",	   /* 263  */
-  "_sys_fhopen",	   /* 264  */
-  "_compat_35_sys_fhstat",	        /* 265 is compat_35 fhstat */
-  "_sys_fhstatfs",	   /* 266  */
-  "_sys_preadv",	   /* 267  */
-  "_sys_pwritev",	   /* 268  */
-  "_sys_kqueue",	   /* 269  */
-  "_sys_kevent",	   /* 270  */
-  "_sys_mlockall",	   /* 271  */
-  "_sys_munlockall",   /* 272  */
-  "_sys_getpeereid",   /* 273  */
-  "_nosys",                     /*	274 */
-  "_nosys",                     /*	275 */
-  "_nosys",                     /*	276 */
-  "_nosys",                     /*	277 */
-  "_nosys",                     /*	278 */
-  "_nosys",                     /*	279 */
-  "_nosys",                     /*	280 */
-  "_sys_getresuid",	   /* 281  */
-  "_sys_setresuid",	   /* 282  */
-  "_sys_getresgid",	   /* 283  */
-  "_sys_setresgid",	   /* 284  */
-  "_nosys",			/* 285 is ??? */
-  "_sys_mquery",       /* 286  */
-  "_sys_closefrom",	   /* 287  */
-  "_sys_sigaltstack",  /* 288  */
-  "_sys_shmget",	   /* 289  */
-  "_sys_semop",	   /* 290  */
-  "_sys_stat",	   /* 291  */
-  "_sys_fstat",	   /* 292  */
-  "_sys_lstat",	   /* 293  */
-  "_sys_fhstat",	   /* 294  */
-  "_sys___semctl",	   /* 295  */
-  "_sys_shmctl",	   /* 296  */
-  "_sys_msgctl",           /* 297  */
-  "_sys_sched_yield",      /* 298  */
-  "_sys_getthrid",         /* 299  */
-  "_sys_thrsleep",         /* 300  */
-  "_sys_thrwakeup",        /* 301  */
-  "_sys_threxit",          /* 302  */
-  "_sys_thrsigdivert",     /* 303  */
-  "_sys___getcwd",         /* 304  */
-  NULL
-};
-
-
-
-/* i386 sys_call_table for freebsd
- */
-char * callz_fbsd[]={
-  "_syscall",  /*	 0 */
-  "sys_exit",  /*	 1 */
-  "_fork",     /*	 2 */
-  "_read",     /*	 3 */
-  "_write",    /*	 4 */
-  "_open",     /*	 5 */
-  "_close",    /*	 6 */
-  "_wait4",    /*	 7 */
-  "_nosys",			/* 8 is old creat */
-  "_link",     /*	 9 */
-  "_unlink",   /*	10 */
-  "_nosys",			/* 11 is obsolete execv */
-  "_chdir",    /*	12 */
-  "_fchdir",   /*	13 */
-  "_mknod",    /*	14 */
-  "_chmod",    /*	15 */
-  "_chown",    /*	16 */
-  "_break",    /*	17 */
-  "_getfsstat",/*	18 */
-  "_nosys",	        	/* 19 is old lseek */
-  "_getpid",   /*	20 */
-  "_mount",    /*	21 */
-  "_unmount",  /*	22 */
-  "_setuid",   /*	23 */
-  "_getuid",   /*	24 */
-  "_geteuid",  /*	25 */
-  "_ptrace",   /*	26 */
-  "_recvmsg",  /*	27 */
-  "_sendmsg",  /*	28 */
-  "_recvfrom", /*	29 */
-  "_accept",   /*	30 */
-  "_getpeername", /*	31 */
-  "_getsockname", /*	32 */
-  "_access",   /*	33 */
-  "_chflags",  /*	34 */
-  "_fchflags", /*	35 */
-  "_sync",     /*	36 */
-  "_kill",     /*	37 */
-  "_nosys",			/* 38 is old stat */
-  "_getppid",  /*	39 */
-  "_nosys",		        /* 40 is old lstat */
-  "_dup",      /*	41 */
-  "_pipe",     /*	42 */
-  "_getegid",  /*	43 */
-  "_profil",   /*	44 */
-  "_ktrace",   /*	45 */
-  "_nosys",			/* 46 is old sigaction */
-  "_getgid",   /*	47 */
-  "_nosys",			/* 48 is old sigprocmask */
-  "_getlogin", /*	49 */
-  "_setlogin", /*	50 */
-  "_acct",     /*	51 */
-  "_nosys",			/* 52 is old sigpending */
-  "_sigaltstack", /*	53 */
-  "_ioctl",    /*	54 */
-  "_reboot",   /*	55 */
-  "_revoke",   /*	56 */
-  "_symlink",  /*	57 */
-  "_readlink", /*	58 */
-  "_execve",   /*	59 */
-  "_umask",    /*	60 */
-  "_chroot",   /*	61 */
-  "_nosys",			/* 62 is old fstat */
-  "_nosys",			/* 63 is old getkerninfo */
-  "_nosys",			/* 64 is old getpagesize */
-  "_msync",    /*	65 */
-  "_vfork",    /*	66 */
-  "_nosys",			/* 67 is obsolete vread */
-  "_nosys",			/* 68 is obsolete vwrite */
-  "_sbrk",     /*	69 */
-  "_sstk",     /*	70 */
-  "_nosys",			/* 71 is old mmap */
-  "_vadvise",  /*	72 */
-  "_munmap",   /*	73 */
-  "_mprotect", /*	74 */
-  "_madvise",  /*	75 */
-  "_nosys",			/* 76 is obsolete vhangup */
-  "_nosys",			/* 77 is obsolete vlimit */
-  "_mincore",  /*	78 */
-  "_getgroups",/*	79 */
-  "_setgroups",/*	80 */
-  "_getpgrp",  /*	81 */
-  "_setpgid",  /*	82 */
-  "_setitimer",/*	83 */
-  "_nosys",			/* 84 is old wait */
-  "_swapon",   /*	85 */
-  "_getitimer",/*	86 */
-  "_nosys",			/* 87 is old gethostname */
-  "_nosys",			/* 88 is old sethostname */
-  "_getdtablesize", /*	89 */
-  "_dup2",     /*	90 */
-  "_nosys",			/* 91 is ??? */
-  "_fcntl",    /*	92 */
-  "_select",   /*	93 */
-  "_nosys",			/* 94 is ??? */
-  "_fsync",    /*	95 */
-  "_setpriority", /*	96 */
-  "_socket",   /*	97 */
-  "_connect",  /*	98 */
-  "_nosys",			/* 99 is old accept */
-  "_getpriority", /*	100 */
-  "_nosys",			/* 101 is old send */
-  "_nosys",			/* 102 is old recv */
-  "_nosys",			/* 103 is old sigreturn */
-  "_bind",    /*	104 */
-  "_setsockopt", /*	105 */
-  "_listen",  /*	106 */
-  "_nosys",			/* 107 is obsolete vtimes */
-  "_nosys",			/* 108 is old sigvec */
-  "_nosys",			/* 109 is old sigblock */
-  "_nosys",			/* 110 is old sigsetmask */
-  "_nosys",			/* 111 is old sigsuspend */
-  "_nosys",			/* 112 is old sigstack */
-  "_nosys",			/* 113 is old recvmsg */
-  "_nosys",			/* 114 is old sendmsg */
-  "_nosys",			/* 115 is obsolete vtrace */
-  "_gettimeofday", /*	116 */ 
-  "_getrusage",    /*	117 */
-  "_getsockopt",   /*	118 */
-  "_nosys",			/* 119 is ??? */
-  "_readv",        /*	120 */
-  "_writev",       /*	121 */
-  "_settimeofday", /*	122 */
-  "_fchown",       /*	123 */
-  "_fchmod",       /*	124 */
-  "_nosys",			/* 125 is old recvfrom */
-  "_setreuid",     /*	126 */
-  "_setregid",     /*	127 */
-  "_rename",       /*	128 */
-  "_nosys",			/* 129 is old truncate */
-  "_nosys",			/* 130 is old ftruncate */
-  "_flock",        /*	131 */
-  "_mkfifo",       /*	132 */
-  "_sendto",       /*	133 */
-  "_shutdown",     /*	134 */
-  "_socketpair",   /*	135 */
-  "_mkdir",        /*	136 */
-  "_rmdir",        /*	137 */
-  "_utimes",       /*	138 */
-  "_nosys",			/* 139 is obsolete 4.2 sigreturn */
-  "_adjtime",      /*	140 */
-  "_nosys",			/* 141 is old getpeername */
-  "_nosys",			/* 142 is old gethostid */
-  "_nosys",			/* 143 is old sethostid */
-  "_nosys",			/* 144 is old getrlimit */
-  "_nosys",			/* 145 is old setrlimit */
-  "_nosys",			/* 146 is old killpg */
-  "_setsid",       /*	147 */
-  "_quotactl",     /*	148 */
-  "_nosys",			/* 149 is old quota */
-  "_nosys",			/* 150 is old getsockname */
-  "_nosys",			/* 151 is ??? */
-  "_nosys",			/* 152 is ??? */
-  "_nosys",			/* 153 is ??? */
-  "_nosys",			/* 154 is ??? */
-  "_nfssvc",       /*	155 */
-  "_nosys",		        /* 156 is old getdirentries */
-  "_statfs",       /*	157 */
-  "_fstatfs",      /*	158 */
-  "_nosys",			/* 159 is ??? */
-  "_nosys",			/* 160 is ??? */
-  "_getfh",        /*	161 */
-  "_getdomainname", /*	162 */
-  "_setdomainname", /*	163 */
-  "_uname",        /*	164 */
-  "_sysarch",      /*	165 */
-  "_rtprio",       /*	166 */
-  "_nosys",			/* 167 is ??? */
-  "_nosys",			/* 168 is ??? */
-  "_semsys",       /*	169 */
-  "_msgsys",       /*	170 */
-  "_shmsys",       /*	171 */
-  "_nosys",			/* 172 is ??? */
-  "_pread",        /*	173 */
-  "_pwrite",       /*	174 */
-  "_nosys",			/* 175 is ??? */
-  "_ntp_adjtime",  /*	176 */
-  "_nosys",			/* 177 is ??? */
-  "_nosys",			/* 178 is ??? */
-  "_nosys",			/* 179 is ??? */
-  "_nosys",			/* 180 is ??? */
-  "_setgid",       /*	181 */
-  "_setegid",      /*	182 */
-  "_seteuid",      /*	183 */
-  "_nosys",			/* 184 is ??? */
-  "_nosys",			/* 185 is ??? */
-  "_nosys",			/* 186 is ??? */
-  "_nosys",			/* 187 is ??? */
-  "_stat",         /*	188 */
-  "_fstat",        /*	189 */
-  "_lstat",        /*	190 */
-  "_pathconf",     /*	191 */
-  "_fpathconf",    /*	192 */
-  "_nosys",			/* 193 is ??? */
-  "_getrlimit",    /*	194 */
-  "_setrlimit",    /*	195 */
-  "_getdirentries", /*	196 */
-  "_mmap",         /*	197 */
-  "___syscall",    /*	198 */
-  "_lseek",        /*	199 */
-  "_truncate",     /*	200 */
-  "_ftruncate",    /*	201 */
-  "___sysctl",     /*	202 */
-  "_mlock",        /*	203 */
-  "_munlock",      /*	204 */
-  "_undelete",     /*	205 */
-  "_futimes",      /*	206 */
-  "_getpgid",      /*	207 */
-  "_nosys",			/* 208 is ??? */
-  "_poll",         /*	209 */
-  "_nosys",			/* 210 is ??? */
-  "_nosys",			/* 211 is ??? */
-  "_nosys",			/* 212 is ??? */
-  "_nosys",			/* 213 is ??? */
-  "_nosys",			/* 214 is ??? */
-  "_nosys",			/* 215 is ??? */
-  "_nosys",			/* 216 is ??? */
-  "_nosys",			/* 217 is ??? */
-  "_nosys",			/* 218 is ??? */
-  "_nosys",			/* 219 is ??? */
-  "___semctl",     /*	220 */
-  "_semget",       /*	221 */
-  "_semop",        /*	222 */
-  "_nosys",			/* 223 is ??? */
-  "_msgctl",       /*	224 */
-  "_msgget",       /*	225 */
-  "_msgsnd",       /*	226 */
-  "_msgrcv",       /*	227 */
-  "_shmat",        /*	228 */
-  "_shmctl",       /*	229 */
-  "_shmdt",        /*	230 */
-  "_shmget",       /*	231 */
-  "_clock_gettime", /*	232 */
-  "_clock_settime", /*	233 */
-  "_clock_getres", /*	234 */
-  "_nosys",			/* 235 is ??? */
-  "_nosys",			/* 236 is ??? */
-  "_nosys",			/* 237 is ??? */
-  "_nosys",			/* 238 is ??? */
-  "_nosys",			/* 239 is ??? */
-  "_nanosleep",    /*	240 */
-  "_nosys",			/* 241 is ??? */
-  "_nosys",			/* 242 is ??? */
-  "_nosys",			/* 243 is ??? */
-  "_nosys",			/* 244 is ??? */
-  "_nosys",			/* 245 is ??? */
-  "_nosys",			/* 246 is ??? */
-  "_nosys",			/* 247 is ??? */
-  "_nosys",			/* 248 is ??? */
-  "_nosys",			/* 249 is ??? */
-  "_minherit",     /*	250 */
-  "_rfork",        /*	251 */
-  "_openbsd_poll", /*	252 */
-  "_issetugid",    /*	253 */
-  "_lchown",       /*	254 */
-  "_nosys",			/* 255 is ??? */
-  "_nosys",			/* 256 is ??? */
-  "_nosys",			/* 257 is ??? */
-  "_nosys",			/* 258 is ??? */
-  "_nosys",			/* 259 is ??? */
-  "_nosys",			/* 260 is ??? */
-  "_nosys",			/* 261 is ??? */
-  "_nosys",			/* 262 is ??? */
-  "_nosys",			/* 263 is ??? */
-  "_nosys",			/* 264 is ??? */
-  "_nosys",			/* 265 is ??? */
-  "_nosys",			/* 266 is ??? */
-  "_nosys",			/* 267 is ??? */
-  "_nosys",			/* 268 is ??? */
-  "_nosys",			/* 269 is ??? */
-  "_nosys",			/* 270 is ??? */
-  "_nosys",			/* 271 is ??? */
-  "_getdents",     /*	272 */
-  "_nosys",			/* 273 is ??? */
-  "_lchmod",       /*	274 */
-  "_netbsd_lchown", /*	275 */
-  "_lutimes",      /*	276 */
-  "_netbsd_msync", /*	277 */
-  "_nstat",        /*	278 */
-  "_nfstat",       /*	279 */
-  "_nlstat",       /*	280 */
-  "_nosys",			/* 281 is ??? */
-  "_nosys",			/* 282 is ??? */
-  "_nosys",			/* 283 is ??? */
-  "_nosys",			/* 284 is ??? */
-  "_nosys",			/* 285 is ??? */
-  "_nosys",			/* 286 is ??? */
-  "_nosys",			/* 287 is ??? */
-  "_nosys",			/* 288 is ??? */
-  "_nosys",			/* 289 is ??? */
-  "_nosys",			/* 290 is ??? */
-  "_nosys",			/* 291 is ??? */
-  "_nosys",			/* 292 is ??? */
-  "_nosys",			/* 293 is ??? */
-  "_nosys",			/* 294 is ??? */
-  "_nosys",			/* 295 is ??? */
-  "_nosys",			/* 296 is ??? */
-  "_fhstatfs",     /*	297 */
-  "_fhopen",       /*	298 */
-  "_fhstat",       /*	299 */
-  "_modnext",      /*	300 */
-  "_modstat",      /*	301 */
-  "_modfnext",     /*	302 */
-  "_modfind",      /*	303 */
-  "_kldload",      /*	304 */
-  "_kldunload",    /*	305 */
-  "_kldfind",      /*	306 */
-  "_kldnext",      /*	307 */
-  "_kldstat",      /*	308 */
-  "_kldfirstmod",  /*	309 */
-  "_getsid",       /*	310 */
-  "_setresuid",    /*	311 */
-  "_setresgid",    /*	312 */
-  "_nosys",			/* 313 is obsolete signanosleep */
-  "_aio_return",   /*	314 */
-  "_aio_suspend",  /*	315 */
-  "_aio_cancel",   /*	316 */
-  "_aio_error",    /*	317 */
-  "_aio_read",     /*	318 */
-  "_aio_write",    /*	319 */
-  "_lio_listio",   /*	320 */
-  "_yield",        /*	321 */
-  "_thr_sleep",    /*	322 */
-  "_thr_wakeup",   /*	323 */
-  "_mlockall",     /*	324 */
-  "_munlockall",   /*	325 */
-  "___getcwd",     /*	326 */
-  "_sched_setparam", /*	327 */
-  "_sched_getparam", /*	328 */
-  "_sched_setscheduler", /*	329 */
-  "_sched_getscheduler", /*	330 */
-  "_sched_yield",  /*	331 */
-  "_sched_get_priority_max", /*	332 */
-  "_sched_get_priority_min", /*	333 */
-  "_sched_rr_get_interval", /*	334 */
-  "_utrace",       /*	335 */
-  "_sendfile",     /*	336 */
-  "_kldsym",       /*	337 */
-  "_jail",         /*	338 */
-  "_nosys",			/* 339 is ??? */
-  "_sigprocmask",  /*	340 */
-  "_sigsuspend",   /*	341 */
-  "_sigaction",    /*	342 */
-  "_sigpending",   /*	343 */
-  "_sigreturn",    /*	344 */
-  "_nosys",			/* 345 is ??? */
-  "_nosys",			/* 346 is ??? */
-  "___acl_get_file", /*	347 */
-  "___acl_set_file", /*	348 */
-  "___acl_get_fd", /*	349 */
-  "___acl_set_fd", /*	350 */
-  "___acl_delete_file", /*	351 */
-  "___acl_delete_fd",   /*	352 */
-  "___acl_aclcheck_file", /*	353 */
-  "___acl_aclcheck_fd", /*	354 */
-  "_extattrctl",   /*	355 */
-  "_extattr_set_file", /*	356 */
-  "_extattr_get_file", /*	357 */
-  "_extattr_delete_file", /*	358 */
-  "_aio_waitcomplete", /*	359 */
-  "_getresuid",    /*	360 */
-  "_getresgid",    /*	361 */
-  "_kqueue",       /*	362 */
-  "_kevent",       /*	363 */
-  "_nosys",			/* 364 is ??? */
-  "_nosys",			/* 365 is ??? */
-  "_nosys",			/* 366 is ??? */
-  "_nosys",			/* 367 is ??? */
-  "_nosys",			/* 368 is ??? */
-  "_nosys",			/* 369 is ??? */
-  "_nosys",			/* 370 is ??? */
-  "_nosys",			/* 371 is ??? */
-  "_nosys",			/* 372 is ??? */
-  "_nosys",			/* 373 is ??? */
-  "_nosys",			/* 374 is ??? */
-  "_nosys",			/* 375 is ??? */
-  "_nosys",			/* 376 is ??? */
-  "_nosys",			/* 377 is ??? */
-  "_nosys",			/* 378 is ??? */
-  "_nosys",			/* 379 is ??? */
-  "_nosys",			/* 380 is ??? */
-  "_nosys",			/* 381 is ??? */
-  "_nosys",			/* 382 is ??? */
-  "_nosys",			/* 383 is ??? */
-  "_nosys",			/* 384 is ??? */
-  "_nosys",			/* 385 is ??? */
-  "_nosys",			/* 386 is ??? */
-  "_nosys",			/* 387 is ??? */
-  "_nosys",			/* 388 is ??? */
-  "_nosys",			/* 389 is ??? */
-  "_nosys",			/* 390 is ??? */
-  "_nosys",			/* 391 is ??? */
-  "_nosys",			/* 392 is ??? */
-  "_sendfile",	/* 393 */
-  NULL
-};
-
-/* i386 sys_call_table for freebsd
- */
-char * callz_fbsd5[]={
-  "_syscall",  /*	 0 */
-  "sys_exit",  /*	 1 */
-  "_fork",     /*	 2 */
-  "_read",     /*	 3 */
-  "_write",    /*	 4 */
-  "_open",     /*	 5 */
-  "_close",    /*	 6 */
-  "_wait4",    /*	 7 */
-  "_nosys",			/* 8 is old creat */
-  "_link",     /*	 9 */
-  "_unlink",   /*	10 */
-  "_nosys",			/* 11 is obsolete execv */
-  "_chdir",    /*	12 */
-  "_fchdir",   /*	13 */
-  "_mknod",    /*	14 */
-  "_chmod",    /*	15 */
-  "_chown",    /*	16 */
-  "_break",    /*	17 */
-  "_nosys",                     /* 18 is old getfsstat */
-  "_nosys",	        	/* 19 is old lseek */
-  "_getpid",   /*	20 */
-  "_mount",    /*	21 */
-  "_unmount",  /*	22 */
-  "_setuid",   /*	23 */
-  "_getuid",   /*	24 */
-  "_geteuid",  /*	25 */
-  "_ptrace",   /*	26 */
-  "_recvmsg",  /*	27 */
-  "_sendmsg",  /*	28 */
-  "_recvfrom", /*	29 */
-  "_accept",   /*	30 */
-  "_getpeername", /*	31 */
-  "_getsockname", /*	32 */
-  "_access",   /*	33 */
-  "_chflags",  /*	34 */
-  "_fchflags", /*	35 */
-  "_sync",     /*	36 */
-  "_kill",     /*	37 */
-  "_nosys",			/* 38 is old stat */
-  "_getppid",  /*	39 */
-  "_nosys",		        /* 40 is old lstat */
-  "_dup",      /*	41 */
-  "_pipe",     /*	42 */
-  "_getegid",  /*	43 */
-  "_profil",   /*	44 */
-  "_ktrace",   /*	45 */
-  "_nosys",			/* 46 is old sigaction */
-  "_getgid",   /*	47 */
-  "_nosys",			/* 48 is old sigprocmask */
-  "_getlogin", /*	49 */
-  "_setlogin", /*	50 */
-  "_acct",     /*	51 */
-  "_nosys",			/* 52 is old sigpending */
-  "_sigaltstack", /*	53 */
-  "_ioctl",    /*	54 */
-  "_reboot",   /*	55 */
-  "_revoke",   /*	56 */
-  "_symlink",  /*	57 */
-  "_readlink", /*	58 */
-  "_execve",   /*	59 */
-  "_umask",    /*	60 */
-  "_chroot",   /*	61 */
-  "_nosys",			/* 62 is old fstat */
-  "_nosys",			/* 63 is old getkerninfo */
-  "_nosys",			/* 64 is old getpagesize */
-  "_msync",    /*	65 */
-  "_vfork",    /*	66 */
-  "_nosys",			/* 67 is obsolete vread */
-  "_nosys",			/* 68 is obsolete vwrite */
-  "_sbrk",     /*	69 */
-  "_sstk",     /*	70 */
-  "_nosys",			/* 71 is old mmap */
-  "_vadvise",  /*	72 */
-  "_munmap",   /*	73 */
-  "_mprotect", /*	74 */
-  "_madvise",  /*	75 */
-  "_nosys",			/* 76 is obsolete vhangup */
-  "_nosys",			/* 77 is obsolete vlimit */
-  "_mincore",  /*	78 */
-  "_getgroups",/*	79 */
-  "_setgroups",/*	80 */
-  "_getpgrp",  /*	81 */
-  "_setpgid",  /*	82 */
-  "_setitimer",/*	83 */
-  "_nosys",			/* 84 is old wait */
-  "_swapon",   /*	85 */
-  "_getitimer",/*	86 */
-  "_nosys",			/* 87 is old gethostname */
-  "_nosys",			/* 88 is old sethostname */
-  "_getdtablesize", /*	89 */
-  "_dup2",     /*	90 */
-  "_nosys",			/* 91 is ??? */
-  "_fcntl",    /*	92 */
-  "_select",   /*	93 */
-  "_nosys",			/* 94 is ??? */
-  "_fsync",    /*	95 */
-  "_setpriority", /*	96 */
-  "_socket",   /*	97 */
-  "_connect",  /*	98 */
-  "_nosys",			/* 99 is old accept */
-  "_getpriority", /*	100 */
-  "_nosys",			/* 101 is old send */
-  "_nosys",			/* 102 is old recv */
-  "_nosys",			/* 103 is old sigreturn */
-  "_bind",    /*	104 */
-  "_setsockopt", /*	105 */
-  "_listen",  /*	106 */
-  "_nosys",			/* 107 is obsolete vtimes */
-  "_nosys",			/* 108 is old sigvec */
-  "_nosys",			/* 109 is old sigblock */
-  "_nosys",			/* 110 is old sigsetmask */
-  "_nosys",			/* 111 is old sigsuspend */
-  "_nosys",			/* 112 is old sigstack */
-  "_nosys",			/* 113 is old recvmsg */
-  "_nosys",			/* 114 is old sendmsg */
-  "_nosys",			/* 115 is obsolete vtrace */
-  "_gettimeofday", /*	116 */ 
-  "_getrusage",    /*	117 */
-  "_getsockopt",   /*	118 */
-  "_nosys",			/* 119 is ??? */
-  "_readv",        /*	120 */
-  "_writev",       /*	121 */
-  "_settimeofday", /*	122 */
-  "_fchown",       /*	123 */
-  "_fchmod",       /*	124 */
-  "_nosys",			/* 125 is old recvfrom */
-  "_setreuid",     /*	126 */
-  "_setregid",     /*	127 */
-  "_rename",       /*	128 */
-  "_nosys",			/* 129 is old truncate */
-  "_nosys",			/* 130 is old ftruncate */
-  "_flock",        /*	131 */
-  "_mkfifo",       /*	132 */
-  "_sendto",       /*	133 */
-  "_shutdown",     /*	134 */
-  "_socketpair",   /*	135 */
-  "_mkdir",        /*	136 */
-  "_rmdir",        /*	137 */
-  "_utimes",       /*	138 */
-  "_nosys",			/* 139 is obsolete 4.2 sigreturn */
-  "_adjtime",      /*	140 */
-  "_nosys",			/* 141 is old getpeername */
-  "_nosys",			/* 142 is old gethostid */
-  "_nosys",			/* 143 is old sethostid */
-  "_nosys",			/* 144 is old getrlimit */
-  "_nosys",			/* 145 is old setrlimit */
-  "_nosys",			/* 146 is old killpg */
-  "_setsid",       /*	147 */
-  "_quotactl",     /*	148 */
-  "_nosys",			/* 149 is old quota */
-  "_nosys",			/* 150 is old getsockname */
-  "_nosys",			/* 151 is ??? */
-  "_nosys",			/* 152 is ??? */
-  "_nosys",			/* 153 is ??? */
-  "_nosys",			/* 154 is ??? */
-  "_nfssvc",       /*	155 */
-  "_nosys",		        /* 156 is old getdirentries */
-  "_nosys",                     /* 157 is old statfs */
-  "_nosys",                     /* 158 is old fstatfs */
-  "_nosys",			/* 159 is ??? */
-  "_lgetfh",       /*   160 */
-  "_getfh",        /*	161 */
-  "_getdomainname", /*	162 */
-  "_setdomainname", /*	163 */
-  "_uname",        /*	164 */
-  "_sysarch",      /*	165 */
-  "_rtprio",       /*	166 */
-  "_nosys",			/* 167 is ??? */
-  "_nosys",			/* 168 is ??? */
-  "_semsys",       /*	169 */
-  "_msgsys",       /*	170 */
-  "_shmsys",       /*	171 */
-  "_nosys",			/* 172 is ??? */
-  "_pread",        /*	173 */
-  "_pwrite",       /*	174 */
-  "_nosys",			/* 175 is ??? */
-  "_ntp_adjtime",  /*	176 */
-  "_nosys",			/* 177 is ??? */
-  "_nosys",			/* 178 is ??? */
-  "_nosys",			/* 179 is ??? */
-  "_nosys",			/* 180 is ??? */
-  "_setgid",       /*	181 */
-  "_setegid",      /*	182 */
-  "_seteuid",      /*	183 */
-  "_nosys",			/* 184 is ??? */
-  "_nosys",			/* 185 is ??? */
-  "_nosys",			/* 186 is ??? */
-  "_nosys",			/* 187 is ??? */
-  "_stat",         /*	188 */
-  "_fstat",        /*	189 */
-  "_lstat",        /*	190 */
-  "_pathconf",     /*	191 */
-  "_fpathconf",    /*	192 */
-  "_nosys",			/* 193 is ??? */
-  "_getrlimit",    /*	194 */
-  "_setrlimit",    /*	195 */
-  "_getdirentries", /*	196 */
-  "_mmap",         /*	197 */
-  "___syscall",    /*	198 */
-  "_lseek",        /*	199 */
-  "_truncate",     /*	200 */
-  "_ftruncate",    /*	201 */
-  "___sysctl",     /*	202 */
-  "_mlock",        /*	203 */
-  "_munlock",      /*	204 */
-  "_undelete",     /*	205 */
-  "_futimes",      /*	206 */
-  "_getpgid",      /*	207 */
-  "_nosys",			/* 208 is ??? */
-  "_poll",         /*	209 */
-  "_nosys",			/* 210 is ??? */
-  "_nosys",			/* 211 is ??? */
-  "_nosys",			/* 212 is ??? */
-  "_nosys",			/* 213 is ??? */
-  "_nosys",			/* 214 is ??? */
-  "_nosys",			/* 215 is ??? */
-  "_nosys",			/* 216 is ??? */
-  "_nosys",			/* 217 is ??? */
-  "_nosys",			/* 218 is ??? */
-  "_nosys",			/* 219 is ??? */
-  "___semctl",     /*	220 */
-  "_semget",       /*	221 */
-  "_semop",        /*	222 */
-  "_nosys",			/* 223 is ??? */
-  "_msgctl",       /*	224 */
-  "_msgget",       /*	225 */
-  "_msgsnd",       /*	226 */
-  "_msgrcv",       /*	227 */
-  "_shmat",        /*	228 */
-  "_shmctl",       /*	229 */
-  "_shmdt",        /*	230 */
-  "_shmget",       /*	231 */
-  "_clock_gettime", /*	232 */
-  "_clock_settime", /*	233 */
-  "_clock_getres", /*	234 */
-  "_nosys",			/* 235 is ??? */
-  "_nosys",			/* 236 is ??? */
-  "_nosys",			/* 237 is ??? */
-  "_nosys",			/* 238 is ??? */
-  "_nosys",			/* 239 is ??? */
-  "_nanosleep",    /*	240 */
-  "_nosys",			/* 241 is ??? */
-  "_nosys",			/* 242 is ??? */
-  "_nosys",			/* 243 is ??? */
-  "_nosys",			/* 244 is ??? */
-  "_nosys",			/* 245 is ??? */
-  "_nosys",			/* 246 is ??? */
-  "_nosys",			/* 247 is ??? */
-  "_nosys",			/* 248 is ??? */
-  "_nosys",			/* 249 is ??? */
-  "_minherit",     /*	250 */
-  "_rfork",        /*	251 */
-  "_openbsd_poll", /*	252 */
-  "_issetugid",    /*	253 */
-  "_lchown",       /*	254 */
-  "_nosys",			/* 255 is ??? */
-  "_nosys",			/* 256 is ??? */
-  "_nosys",			/* 257 is ??? */
-  "_nosys",			/* 258 is ??? */
-  "_nosys",			/* 259 is ??? */
-  "_nosys",			/* 260 is ??? */
-  "_nosys",			/* 261 is ??? */
-  "_nosys",			/* 262 is ??? */
-  "_nosys",			/* 263 is ??? */
-  "_nosys",			/* 264 is ??? */
-  "_nosys",			/* 265 is ??? */
-  "_nosys",			/* 266 is ??? */
-  "_nosys",			/* 267 is ??? */
-  "_nosys",			/* 268 is ??? */
-  "_nosys",			/* 269 is ??? */
-  "_nosys",			/* 270 is ??? */
-  "_nosys",			/* 271 is ??? */
-  "_getdents",     /*	272 */
-  "_nosys",			/* 273 is ??? */
-  "_lchmod",       /*	274 */
-  "_netbsd_lchown", /*	275 */
-  "_lutimes",      /*	276 */
-  "_netbsd_msync", /*	277 */
-  "_nstat",        /*	278 */
-  "_nfstat",       /*	279 */
-  "_nlstat",       /*	280 */
-  "_nosys",			/* 281 is ??? */
-  "_nosys",			/* 282 is ??? */
-  "_nosys",			/* 283 is ??? */
-  "_nosys",			/* 284 is ??? */
-  "_nosys",			/* 285 is ??? */
-  "_nosys",			/* 286 is ??? */
-  "_nosys",			/* 287 is ??? */
-  "_nosys",			/* 288 is ??? */
-  "_nosys",			/* 289 is ??? */
-  "_nosys",			/* 290 is ??? */
-  "_nosys",			/* 291 is ??? */
-  "_nosys",			/* 292 is ??? */
-  "_nosys",			/* 293 is ??? */
-  "_nosys",			/* 294 is ??? */
-  "_nosys",			/* 295 is ??? */
-  "_nosys",			/* 296 is ??? */
-  "_nosys",                     /* 297 is old fhstatfs */
-  "_fhopen",       /*	298 */
-  "_fhstat",       /*	299 */
-  "_modnext",      /*	300 */
-  "_modstat",      /*	301 */
-  "_modfnext",     /*	302 */
-  "_modfind",      /*	303 */
-  "_kldload",      /*	304 */
-  "_kldunload",    /*	305 */
-  "_kldfind",      /*	306 */
-  "_kldnext",      /*	307 */
-  "_kldstat",      /*	308 */
-  "_kldfirstmod",  /*	309 */
-  "_getsid",       /*	310 */
-  "_setresuid",    /*	311 */
-  "_setresgid",    /*	312 */
-  "_nosys",			/* 313 is obsolete signanosleep */
-  "_aio_return",   /*	314 */
-  "_aio_suspend",  /*	315 */
-  "_aio_cancel",   /*	316 */
-  "_aio_error",    /*	317 */
-  "_aio_read",     /*	318 */
-  "_aio_write",    /*	319 */
-  "_lio_listio",   /*	320 */
-  "_yield",        /*	321 */
-  "_thr_sleep",    /*	322 */
-  "_thr_wakeup",   /*	323 */
-  "_mlockall",     /*	324 */
-  "_munlockall",   /*	325 */
-  "___getcwd",     /*	326 */
-  "_sched_setparam", /*	327 */
-  "_sched_getparam", /*	328 */
-  "_sched_setscheduler", /*	329 */
-  "_sched_getscheduler", /*	330 */
-  "_sched_yield",  /*	331 */
-  "_sched_get_priority_max", /*	332 */
-  "_sched_get_priority_min", /*	333 */
-  "_sched_rr_get_interval", /*	334 */
-  "_utrace",       /*	335 */
-  "_nosys",                  /* 336 is old sendfile */
-  "_kldsym",       /*	337 */
-  "_jail",         /*	338 */
-  "_nosys",			/* 339 is ??? */
-  "_sigprocmask",  /*	340 */
-  "_sigsuspend",   /*	341 */
-  "_nosys",                     /* 342 is old sigaction */
-  "_sigpending",   /*	343 */
-  "_nosys",                     /* 344 is old sigreturn */
-  "_sigtimedwait", /*   345 */
-  "_sigwaitinfo",  /*   346 */
-  "___acl_get_file", /*	347 */
-  "___acl_set_file", /*	348 */
-  "___acl_get_fd", /*	349 */
-  "___acl_set_fd", /*	350 */
-  "___acl_delete_file", /*	351 */
-  "___acl_delete_fd",   /*	352 */
-  "___acl_aclcheck_file", /*	353 */
-  "___acl_aclcheck_fd", /*	354 */
-  "_extattrctl",   /*	355 */
-  "_extattr_set_file", /*	356 */
-  "_extattr_get_file", /*	357 */
-  "_extattr_delete_file", /*	358 */
-  "_aio_waitcomplete", /*	359 */
-  "_getresuid",    /*	360 */
-  "_getresgid",    /*	361 */
-  "_kqueue",       /*	362 */
-  "_kevent",       /*	363 */
-  "_nosys",			/* 364 is ??? */
-  "_nosys",			/* 365 is ??? */
-  "_nosys",			/* 366 is ??? */
-  "_nosys",			/* 367 is ??? */
-  "_nosys",			/* 368 is ??? */
-  "_nosys",			/* 369 is ??? */
-  "_nosys",			/* 370 is ??? */
-  "_extattr_set_fd",            /* 371 */
-  "_extattr_get_fd",            /* 372 */
-  "_extattr_delete_fd",         /* 373 */
-  "___setugid",                 /* 374 */
-  "_nfsclnt",                   /* 375 */
-  "_eaccess",                   /* 376 */
-  "_nosys",			/* 377 is ??? */
-  "_nmount",                    /* 378 */
-  "_kse_exit",                  /* 379 */
-  "_kse_wakeup",                /* 380 */
-  "_kse_create",                /* 381 */
-  "_kse_thr_interrupt",         /* 382 */
-  "_kse_release",               /* 383 */
-  "___mac_get_proc",            /* 384 */
-  "___mac_set_proc",            /* 385 */
-  "___mac_get_fd",              /* 386 */
-  "___mac_get_file",            /* 387 */
-  "___mac_set_fd",              /* 388 */
-  "___mac_set_file",            /* 389 */
-  "_kenv",			/* 390 */
-  "_lchflags",                  /* 391 */
-  "_uuidgen",                   /* 392 */
-  "_sendfile",	  /* 393 */
-  "_mac_syscall",	  /* 394 */
-  "_getfsstat",	  /* 395 */
-  "_statfs",	  /* 396 */
-  "_fstatfs",	  /* 397 */
-  "_fhstatfs",	  /* 398 */
-  "_nosys",	  /* 399 */
-  "_ksem_close",  /* 400 */
-  "_ksem_post",	  /* 401 */
-  "_ksem_wait",	  /* 402 */
-  "_ksem_trywait",	  /* 403 */
-  "_ksem_init",	  /* 404 */
-  "_ksem_open",	  /* 405 */
-  "_ksem_unlink",	  /* 406 */
-  "_ksem_getvalue",	  /* 407 */
-  "_ksem_destroy",	  /* 408 */
-  "___mac_get_pid",	  /* 409 */
-  "___mac_get_link",	  /* 410 */
-  "___mac_set_link",	  /* 411 */
-  "_extattr_set_link",	  /* 412 */
-  "_extattr_get_link",	  /* 413 */
-  "_extattr_delete_link",	  /* 414 */
-  "___mac_execve",	  /* 415 */
-  "_sigaction",	  /* 416 */
-  "_sigreturn",	  /* 417 */
-  "_nosys",	  /* 418 */
-  "_nosys",	  /* 419 */
-  "_nosys",	  /* 420 */
-  "_getcontext",	  /* 421 */
-  "_setcontext",	  /* 422 */
-  "_swapcontext",	  /* 423 */
-  "_swapoff",	  /* 424 */
-  "___acl_get_link",	  /* 425 */
-  "___acl_set_link",	  /* 426 */
-  "___acl_delete_link",	  /* 427 */
-  "___acl_aclcheck_link",	  /* 428 */
-  "_sigwait",	  /* 429 */
-  "_thr_create",	  /* 430 */
-  "_thr_exit",	  /* 431 */
-  "_thr_self",	  /* 432 */
-  "_thr_kill",	  /* 433 */
-  "__umtx_lock",	  /* 434 */
-  "__umtx_unlock",	  /* 435 */
-  "_jail_attach",	  /* 436 */
-  "_extattr_list_fd",	  /* 437 */
-  "_extattr_list_file",	  /* 438 */
-  "_extattr_list_link",	  /* 439 */
-  "_kse_switchin",        /* 440 */
-  "_ksem_timedwait",      /* 441 */
-  "_thr_suspend",         /* 442 */
-  "_thr_wake",            /* 443 */
-  "_kldunloadf",          /* 444 */
-  NULL
-};
-
Index: trunk/include/rijndael-alg-fst.h
===================================================================
--- trunk/include/rijndael-alg-fst.h	(revision 459)
+++ trunk/include/rijndael-alg-fst.h	(revision 481)
@@ -1,46 +1,44 @@
-/*
- * rijndael-alg-fst.h   v2.3   April '2000
+/*	$NetBSD: rijndael-alg-fst.h,v 1.4 2005/12/11 12:20:52 christos Exp $	*/
+/*	$KAME: rijndael-alg-fst.h,v 1.5 2003/07/15 10:47:16 itojun Exp $	*/
+/**
+ * rijndael-alg-fst.h
  *
- * Optimised ANSI C code
+ * @version 3.0 (December 2000)
  *
+ * Optimised ANSI C code for the Rijndael cipher (now AES)
+ *
+ * @author Vincent Rijmen <vincent.rijmen@esat.kuleuven.ac.be>
+ * @author Antoon Bosselaers <antoon.bosselaers@esat.kuleuven.ac.be>
+ * @author Paulo Barreto <paulo.barreto@terra.com.br>
+ *
+ * This code is hereby placed in the public domain.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE AUTHORS ''AS IS'' AND ANY EXPRESS
+ * OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+ * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
+ * ARE DISCLAIMED.  IN NO EVENT SHALL THE AUTHORS OR CONTRIBUTORS BE
+ * LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
+ * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
+ * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR
+ * BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
+ * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
+ * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
+ * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  */
-
-/*@-fixedformalarray@*/
-
 #ifndef __RIJNDAEL_ALG_FST_H
 #define __RIJNDAEL_ALG_FST_H
 
-#define MAXKC			(256/32)
-#define MAXROUNDS		14
-
-/* USUAL_TYPES */
-#ifndef USUAL_TYPES
-#define USUAL_TYPES
-typedef unsigned char	byte;
-typedef unsigned char	word8;	
-typedef unsigned short	word16;	
-typedef unsigned int	word32;
-#endif 
+#define RIJNDAEL_MAXKC	(256/32)
+#define RIJNDAEL_MAXKB	(256/8)
+#define RIJNDAEL_MAXNR	14
 
 #ifdef SH_ENCRYPT
 
-int rijndaelKeySched(word8 k[MAXKC][4], word8 rk[MAXROUNDS+1][4][4], int ROUNDS);
-
-int rijndaelKeyEncToDec(word8 W[MAXROUNDS+1][4][4], int ROUNDS);
-
-int rijndaelEncrypt(word8 a[16], word8 b[16], word8 rk[MAXROUNDS+1][4][4], int ROUNDS);
-
-
-int rijndaelDecrypt(word8 a[16], word8 b[16], word8 rk[MAXROUNDS+1][4][4], int ROUNDS);
-
-#ifdef INTERMEDIATE_VALUE_KAT
-int rijndaelEncryptRound(word8 a[4][4], word8 rk[MAXROUNDS+1][4][4], int ROUNDS, int rounds);
-int rijndaelDecryptRound(word8 a[4][4], word8 rk[MAXROUNDS+1][4][4], int ROUNDS, int rounds);
-#endif
+int rijndaelKeySetupEnc(u32 rk[/*4*(Nr + 1)*/], const u8 cipherKey[], int keyBits);
+int rijndaelKeySetupDec(u32 rk[/*4*(Nr + 1)*/], const u8 cipherKey[], int keyBits);
+void rijndaelEncrypt(const u32 rk[/*4*(Nr + 1)*/], int Nr, const u8 pt[16], u8 ct[16]);
+void rijndaelDecrypt(const u32 rk[/*4*(Nr + 1)*/], int Nr, const u8 ct[16], u8 pt[16]);
 
 /* SH_ENCRYPT */
 #endif
-
-/* __RIJNDAEL_ALG_FST_H */
-#endif 
-
+#endif /* __RIJNDAEL_ALG_FST_H */
Index: trunk/include/rijndael-api-fst.h
===================================================================
--- trunk/include/rijndael-api-fst.h	(revision 459)
+++ trunk/include/rijndael-api-fst.h	(revision 481)
@@ -1,7 +1,39 @@
-/*
- * rijndael-api-fst.h   v2.3   April '2000
+/*	$NetBSD: rijndael-api-fst.h,v 1.8 2007/01/21 23:00:08 cbiere Exp $	*/
+
+/**
+ * rijndael-api-fst.h
  *
- * Optimised ANSI C code
+ * @version 2.9 (December 2000)
  *
+ * Optimised ANSI C code for the Rijndael cipher (now AES)
+ *
+ * @author Vincent Rijmen <vincent.rijmen@esat.kuleuven.ac.be>
+ * @author Antoon Bosselaers <antoon.bosselaers@esat.kuleuven.ac.be>
+ * @author Paulo Barreto <paulo.barreto@terra.com.br>
+ *
+ * This code is hereby placed in the public domain.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE AUTHORS ''AS IS'' AND ANY EXPRESS
+ * OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+ * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
+ * ARE DISCLAIMED.  IN NO EVENT SHALL THE AUTHORS OR CONTRIBUTORS BE
+ * LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
+ * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
+ * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR
+ * BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
+ * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
+ * OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
+ * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ *
+ * Acknowledgements:
+ *
+ * We are deeply indebted to the following people for their bug reports,
+ * fixes, and improvement suggestions to this implementation. Though we
+ * tried to list all contributions, we apologise in advance for any
+ * missing reference.
+ *
+ * Andrew Bales <Andrew.Bales@Honeywell.com>
+ * Markus Friedl <markus.friedl@informatik.uni-erlangen.de>
+ * John Skodon <skodonj@webquill.com>
  */
 
@@ -9,15 +41,30 @@
 #define __RIJNDAEL_API_FST_H
 
+/* Blocksize: 16 * 8 = 128; 128 * 1 = 128 */
+#define     B_SIZ    16
+#define     BNUM      1
+
+
+#if defined(UINT32)
+typedef unsigned char u8;
+typedef UINT32 u32;
+#else
+
+typedef unsigned char u8;
+#if defined(HAVE_INT_32)
+typedef unsigned int u32;
+#elif defined(HAVE_LONG_32)
+typedef unsigned long u32;
+#elif defined(HAVE_SHORT_32)
+typedef unsigned short u32;
+#else
+#error "No 32 bit integer type found"
+#endif
+
+#endif
+
 #include "rijndael-alg-fst.h"
 
-/*  Defines:
-    Add any additional defines you need
-*/
-
-#define     BNUM                  1
-#define     B_SIZ                 16
-#define     STRICT_ALIGN          1 /*  For safety          */
-
-
+/*  Generic Defines  */
 #define     DIR_ENCRYPT           0 /*  Are we encrpyting?  */
 #define     DIR_DECRYPT           1 /*  Are we decrpyting?  */
@@ -33,6 +80,5 @@
 #define     BITSPERBLOCK        128 /* Default number of bits in a cipher block */
 
-/*  Error Codes - CHANGE POSSIBLE: inclusion of additional error codes  */
-
+/*  Error Codes  */
 #define     BAD_KEY_DIR          -1 /*  Key direction is invalid, e.g., unknown value */
 #define     BAD_KEY_MAT          -2 /*  Key material not of correct length */
@@ -45,63 +91,46 @@
 #define     BAD_OTHER            -9 /*  Unknown error */
 
-/*  CHANGE POSSIBLE:  inclusion of algorithm specific defines  */
-#define     MAX_KEY_SIZE         64 /* # of ASCII char's needed to represent a key */
-#define     MAX_IV_SIZE          16 /* # bytes needed to represent an IV  */
+/*  Algorithm-specific Defines  */
+#define     RIJNDAEL_MAX_KEY_SIZE         64 /* # of ASCII char's needed to represent a key */
+#define     RIJNDAEL_MAX_IV_SIZE          16 /* # bytes needed to represent an IV  */
 
 #ifdef SH_ENCRYPT
 
-/*  Typedefs:
+/*  Typedefs  */
 
-	Typedef'ed data storage elements.  Add any algorithm specific 
-parameters at the bottom of the structs as appropriate.
-*/
-
-typedef unsigned char   RIJ_BYTE;
+typedef unsigned char   BYTE;
 
 /*  The structure for key information */
 typedef struct {
-    RIJ_BYTE  direction;                /* Key used for encrypting or decrypting? */
-    int   keyLen;                   /* Length of the key  */
-    char  keyMaterial[MAX_KEY_SIZE+1];  /* Raw key data in ASCII, e.g., user input or KAT values */
-        /*  The following parameters are algorithm dependent, replace or add as necessary  */
-	int   ROUNDS;                   /* key-length-dependent number of rounds */
-    int   blockLen;                 /* block length */
-    word8 keySched[MAXROUNDS+1][4][4];	/* key schedule		*/
+  u32   rk[4*(RIJNDAEL_MAXNR + 1)];        /* key schedule */
+  u32   ek[4*(RIJNDAEL_MAXNR + 1)];        /* CFB1 key schedule (encryption only) */
+  BYTE  direction;                /* Key used for encrypting or decrypting? */
+  int   keyLen;                   /* Length of the key  */
+  char  keyMaterial[RIJNDAEL_MAX_KEY_SIZE+1];  /* Raw key data in ASCII, e.g., user input or KAT values */
+  int   Nr;                       /* key-length-dependent number of rounds */
 } keyInstance;
 
 /*  The structure for cipher information */
 typedef struct {                    /* changed order of the components */
-    RIJ_BYTE  mode;                     /* MODE_ECB, MODE_CBC, or MODE_CFB1 */
-    RIJ_BYTE  IV[MAX_IV_SIZE];          /* A possible Initialization Vector for ciphering */
-        /*  Add any algorithm specific parameters needed here  */
-    int   blockLen;                 /* Sample: Handles non-128 bit block sizes (if available) */
+    u32  IV[RIJNDAEL_MAX_IV_SIZE / sizeof(u32)];
+			/* A possible Initialization Vector for ciphering */
+    BYTE  mode;                     /* MODE_ECB, MODE_CBC, or MODE_CFB1 */
 } cipherInstance;
 
 /*  Function prototypes  */
-/*  CHANGED: nothing
-	TODO: implement the following extensions to setup 192-bit and 256-bit block lengths:
-        makeKeyEx():    parameter blockLen added
-                        -- this parameter is absolutely necessary if you want to
-                        setup the round keys in a variable block length setting 
-	    cipherInitEx(): parameter blockLen added (for obvious reasons)		
- */
 
-int makeKey(keyInstance *key, RIJ_BYTE direction, int keyLen, char *keyMaterial);
+int rijndael_makeKey(keyInstance *, BYTE, int, const char *);
 
-int cipherInit(cipherInstance *cipher, RIJ_BYTE mode, char *IV);
+int rijndael_cipherInit(cipherInstance *, BYTE, const char *);
 
-int blockEncrypt(cipherInstance *cipher, keyInstance *key,
-		 RIJ_BYTE *input, int inputLen, RIJ_BYTE *outBuffer);
+int rijndael_blockEncrypt(cipherInstance *, keyInstance *, const BYTE *, int, BYTE *);
 
-int blockDecrypt(cipherInstance *cipher, keyInstance *key,
-		 RIJ_BYTE *input, int inputLen, RIJ_BYTE *outBuffer);
-#ifdef INTERMEDIATE_VALUE_KAT
-int cipherUpdateRounds(cipherInstance *cipher, keyInstance *key,
-		       RIJ_BYTE *input, int inputLen, RIJ_BYTE *outBuffer, int rounds);
-#endif
+int rijndael_padEncrypt(cipherInstance *, keyInstance *, const BYTE *, int, BYTE *);
+
+int rijndael_blockDecrypt(cipherInstance *, keyInstance *, const BYTE *, int, BYTE *);
+
+int rijndael_padDecrypt(cipherInstance *, keyInstance *, const BYTE *, int, BYTE *);
 
 /* SH_ENCRYPT */
 #endif
-
-/*  __RIJNDAEL_API_FST_H */
-#endif 
+#endif /* __RIJNDAEL_API_FST_H */
Index: trunk/include/rijndael-boxes-fst.h
===================================================================
--- trunk/include/rijndael-boxes-fst.h	(revision 459)
+++ 	(revision )
@@ -1,914 +1,0 @@
-word8 S[256] = {
- 99, 124, 119, 123, 242, 107, 111, 197,  48,   1, 103,  43, 254, 215, 171, 118, 
-202, 130, 201, 125, 250,  89,  71, 240, 173, 212, 162, 175, 156, 164, 114, 192, 
-183, 253, 147,  38,  54,  63, 247, 204,  52, 165, 229, 241, 113, 216,  49,  21, 
-  4, 199,  35, 195,  24, 150,   5, 154,   7,  18, 128, 226, 235,  39, 178, 117, 
-  9, 131,  44,  26,  27, 110,  90, 160,  82,  59, 214, 179,  41, 227,  47, 132, 
- 83, 209,   0, 237,  32, 252, 177,  91, 106, 203, 190,  57,  74,  76,  88, 207, 
-208, 239, 170, 251,  67,  77,  51, 133,  69, 249,   2, 127,  80,  60, 159, 168, 
- 81, 163,  64, 143, 146, 157,  56, 245, 188, 182, 218,  33,  16, 255, 243, 210, 
-205,  12,  19, 236,  95, 151,  68,  23, 196, 167, 126,  61, 100,  93,  25, 115, 
- 96, 129,  79, 220,  34,  42, 144, 136,  70, 238, 184,  20, 222,  94,  11, 219, 
-224,  50,  58,  10,  73,   6,  36,  92, 194, 211, 172,  98, 145, 149, 228, 121, 
-231, 200,  55, 109, 141, 213,  78, 169, 108,  86, 244, 234, 101, 122, 174,   8, 
-186, 120,  37,  46,  28, 166, 180, 198, 232, 221, 116,  31,  75, 189, 139, 138, 
-112,  62, 181, 102,  72,   3, 246,  14,  97,  53,  87, 185, 134, 193,  29, 158, 
-225, 248, 152,  17, 105, 217, 142, 148, 155,  30, 135, 233, 206,  85,  40, 223, 
-140, 161, 137,  13, 191, 230,  66, 104,  65, 153,  45,  15, 176,  84, 187,  22
-};
-
-#ifdef INTERMEDIATE_VALUE_KAT
-word8 Si[256] = {
- 82,   9, 106, 213,  48,  54, 165,  56, 191,  64, 163, 158, 129, 243, 215, 251, 
-124, 227,  57, 130, 155,  47, 255, 135,  52, 142,  67,  68, 196, 222, 233, 203, 
- 84, 123, 148,  50, 166, 194,  35,  61, 238,  76, 149,  11,  66, 250, 195,  78, 
-  8,  46, 161, 102,  40, 217,  36, 178, 118,  91, 162,  73, 109, 139, 209,  37, 
-114, 248, 246, 100, 134, 104, 152,  22, 212, 164,  92, 204,  93, 101, 182, 146, 
-108, 112,  72,  80, 253, 237, 185, 218,  94,  21,  70,  87, 167, 141, 157, 132, 
-144, 216, 171,   0, 140, 188, 211,  10, 247, 228,  88,   5, 184, 179,  69,   6, 
-208,  44,  30, 143, 202,  63,  15,   2, 193, 175, 189,   3,   1,  19, 138, 107, 
- 58, 145,  17,  65,  79, 103, 220, 234, 151, 242, 207, 206, 240, 180, 230, 115, 
-150, 172, 116,  34, 231, 173,  53, 133, 226, 249,  55, 232,  28, 117, 223, 110, 
- 71, 241,  26, 113,  29,  41, 197, 137, 111, 183,  98,  14, 170,  24, 190,  27, 
-252,  86,  62,  75, 198, 210, 121,  32, 154, 219, 192, 254, 120, 205,  90, 244, 
- 31, 221, 168,  51, 136,   7, 199,  49, 177,  18,  16,  89,  39, 128, 236,  95, 
- 96,  81, 127, 169,  25, 181,  74,  13,  45, 229, 122, 159, 147, 201, 156, 239, 
-160, 224,  59,  77, 174,  42, 245, 176, 200, 235, 187,  60, 131,  83, 153,  97, 
- 23,  43,   4, 126, 186, 119, 214,  38, 225, 105,  20,  99,  85,  33,  12, 125
-};
-#endif /* INTERMEDIATE_VALUE_KAT */
-
-word8 T1[256][4] = {
-{ 0xc6,0x63,0x63,0xa5},{  0xf8,0x7c,0x7c,0x84},{  0xee,0x77,0x77,0x99},{  0xf6,0x7b,0x7b,0x8d}, 
-{ 0xff,0xf2,0xf2,0x0d},{  0xd6,0x6b,0x6b,0xbd},{  0xde,0x6f,0x6f,0xb1},{  0x91,0xc5,0xc5,0x54}, 
-{ 0x60,0x30,0x30,0x50},{  0x02,0x01,0x01,0x03},{  0xce,0x67,0x67,0xa9},{  0x56,0x2b,0x2b,0x7d}, 
-{ 0xe7,0xfe,0xfe,0x19},{  0xb5,0xd7,0xd7,0x62},{  0x4d,0xab,0xab,0xe6},{  0xec,0x76,0x76,0x9a}, 
-{ 0x8f,0xca,0xca,0x45},{  0x1f,0x82,0x82,0x9d},{  0x89,0xc9,0xc9,0x40},{  0xfa,0x7d,0x7d,0x87}, 
-{ 0xef,0xfa,0xfa,0x15},{  0xb2,0x59,0x59,0xeb},{  0x8e,0x47,0x47,0xc9},{  0xfb,0xf0,0xf0,0x0b}, 
-{ 0x41,0xad,0xad,0xec},{  0xb3,0xd4,0xd4,0x67},{  0x5f,0xa2,0xa2,0xfd},{  0x45,0xaf,0xaf,0xea}, 
-{ 0x23,0x9c,0x9c,0xbf},{  0x53,0xa4,0xa4,0xf7},{  0xe4,0x72,0x72,0x96},{  0x9b,0xc0,0xc0,0x5b}, 
-{ 0x75,0xb7,0xb7,0xc2},{  0xe1,0xfd,0xfd,0x1c},{  0x3d,0x93,0x93,0xae},{  0x4c,0x26,0x26,0x6a}, 
-{ 0x6c,0x36,0x36,0x5a},{  0x7e,0x3f,0x3f,0x41},{  0xf5,0xf7,0xf7,0x02},{  0x83,0xcc,0xcc,0x4f}, 
-{ 0x68,0x34,0x34,0x5c},{  0x51,0xa5,0xa5,0xf4},{  0xd1,0xe5,0xe5,0x34},{  0xf9,0xf1,0xf1,0x08}, 
-{ 0xe2,0x71,0x71,0x93},{  0xab,0xd8,0xd8,0x73},{  0x62,0x31,0x31,0x53},{  0x2a,0x15,0x15,0x3f}, 
-{ 0x08,0x04,0x04,0x0c},{  0x95,0xc7,0xc7,0x52},{  0x46,0x23,0x23,0x65},{  0x9d,0xc3,0xc3,0x5e}, 
-{ 0x30,0x18,0x18,0x28},{  0x37,0x96,0x96,0xa1},{  0x0a,0x05,0x05,0x0f},{  0x2f,0x9a,0x9a,0xb5}, 
-{ 0x0e,0x07,0x07,0x09},{  0x24,0x12,0x12,0x36},{  0x1b,0x80,0x80,0x9b},{  0xdf,0xe2,0xe2,0x3d}, 
-{ 0xcd,0xeb,0xeb,0x26},{  0x4e,0x27,0x27,0x69},{  0x7f,0xb2,0xb2,0xcd},{  0xea,0x75,0x75,0x9f}, 
-{ 0x12,0x09,0x09,0x1b},{  0x1d,0x83,0x83,0x9e},{  0x58,0x2c,0x2c,0x74},{  0x34,0x1a,0x1a,0x2e}, 
-{ 0x36,0x1b,0x1b,0x2d},{  0xdc,0x6e,0x6e,0xb2},{  0xb4,0x5a,0x5a,0xee},{  0x5b,0xa0,0xa0,0xfb}, 
-{ 0xa4,0x52,0x52,0xf6},{  0x76,0x3b,0x3b,0x4d},{  0xb7,0xd6,0xd6,0x61},{  0x7d,0xb3,0xb3,0xce}, 
-{ 0x52,0x29,0x29,0x7b},{  0xdd,0xe3,0xe3,0x3e},{  0x5e,0x2f,0x2f,0x71},{  0x13,0x84,0x84,0x97}, 
-{ 0xa6,0x53,0x53,0xf5},{  0xb9,0xd1,0xd1,0x68},{  0x00,0x00,0x00,0x00},{  0xc1,0xed,0xed,0x2c}, 
-{ 0x40,0x20,0x20,0x60},{  0xe3,0xfc,0xfc,0x1f},{  0x79,0xb1,0xb1,0xc8},{  0xb6,0x5b,0x5b,0xed}, 
-{ 0xd4,0x6a,0x6a,0xbe},{  0x8d,0xcb,0xcb,0x46},{  0x67,0xbe,0xbe,0xd9},{  0x72,0x39,0x39,0x4b}, 
-{ 0x94,0x4a,0x4a,0xde},{  0x98,0x4c,0x4c,0xd4},{  0xb0,0x58,0x58,0xe8},{  0x85,0xcf,0xcf,0x4a}, 
-{ 0xbb,0xd0,0xd0,0x6b},{  0xc5,0xef,0xef,0x2a},{  0x4f,0xaa,0xaa,0xe5},{  0xed,0xfb,0xfb,0x16}, 
-{ 0x86,0x43,0x43,0xc5},{  0x9a,0x4d,0x4d,0xd7},{  0x66,0x33,0x33,0x55},{  0x11,0x85,0x85,0x94}, 
-{ 0x8a,0x45,0x45,0xcf},{  0xe9,0xf9,0xf9,0x10},{  0x04,0x02,0x02,0x06},{  0xfe,0x7f,0x7f,0x81}, 
-{ 0xa0,0x50,0x50,0xf0},{  0x78,0x3c,0x3c,0x44},{  0x25,0x9f,0x9f,0xba},{  0x4b,0xa8,0xa8,0xe3}, 
-{ 0xa2,0x51,0x51,0xf3},{  0x5d,0xa3,0xa3,0xfe},{  0x80,0x40,0x40,0xc0},{  0x05,0x8f,0x8f,0x8a}, 
-{ 0x3f,0x92,0x92,0xad},{  0x21,0x9d,0x9d,0xbc},{  0x70,0x38,0x38,0x48},{  0xf1,0xf5,0xf5,0x04}, 
-{ 0x63,0xbc,0xbc,0xdf},{  0x77,0xb6,0xb6,0xc1},{  0xaf,0xda,0xda,0x75},{  0x42,0x21,0x21,0x63}, 
-{ 0x20,0x10,0x10,0x30},{  0xe5,0xff,0xff,0x1a},{  0xfd,0xf3,0xf3,0x0e},{  0xbf,0xd2,0xd2,0x6d}, 
-{ 0x81,0xcd,0xcd,0x4c},{  0x18,0x0c,0x0c,0x14},{  0x26,0x13,0x13,0x35},{  0xc3,0xec,0xec,0x2f}, 
-{ 0xbe,0x5f,0x5f,0xe1},{  0x35,0x97,0x97,0xa2},{  0x88,0x44,0x44,0xcc},{  0x2e,0x17,0x17,0x39}, 
-{ 0x93,0xc4,0xc4,0x57},{  0x55,0xa7,0xa7,0xf2},{  0xfc,0x7e,0x7e,0x82},{  0x7a,0x3d,0x3d,0x47}, 
-{ 0xc8,0x64,0x64,0xac},{  0xba,0x5d,0x5d,0xe7},{  0x32,0x19,0x19,0x2b},{  0xe6,0x73,0x73,0x95}, 
-{ 0xc0,0x60,0x60,0xa0},{  0x19,0x81,0x81,0x98},{  0x9e,0x4f,0x4f,0xd1},{  0xa3,0xdc,0xdc,0x7f}, 
-{ 0x44,0x22,0x22,0x66},{  0x54,0x2a,0x2a,0x7e},{  0x3b,0x90,0x90,0xab},{  0x0b,0x88,0x88,0x83}, 
-{ 0x8c,0x46,0x46,0xca},{  0xc7,0xee,0xee,0x29},{  0x6b,0xb8,0xb8,0xd3},{  0x28,0x14,0x14,0x3c}, 
-{ 0xa7,0xde,0xde,0x79},{  0xbc,0x5e,0x5e,0xe2},{  0x16,0x0b,0x0b,0x1d},{  0xad,0xdb,0xdb,0x76}, 
-{ 0xdb,0xe0,0xe0,0x3b},{  0x64,0x32,0x32,0x56},{  0x74,0x3a,0x3a,0x4e},{  0x14,0x0a,0x0a,0x1e}, 
-{ 0x92,0x49,0x49,0xdb},{  0x0c,0x06,0x06,0x0a},{  0x48,0x24,0x24,0x6c},{  0xb8,0x5c,0x5c,0xe4}, 
-{ 0x9f,0xc2,0xc2,0x5d},{  0xbd,0xd3,0xd3,0x6e},{  0x43,0xac,0xac,0xef},{  0xc4,0x62,0x62,0xa6}, 
-{ 0x39,0x91,0x91,0xa8},{  0x31,0x95,0x95,0xa4},{  0xd3,0xe4,0xe4,0x37},{  0xf2,0x79,0x79,0x8b}, 
-{ 0xd5,0xe7,0xe7,0x32},{  0x8b,0xc8,0xc8,0x43},{  0x6e,0x37,0x37,0x59},{  0xda,0x6d,0x6d,0xb7}, 
-{ 0x01,0x8d,0x8d,0x8c},{  0xb1,0xd5,0xd5,0x64},{  0x9c,0x4e,0x4e,0xd2},{  0x49,0xa9,0xa9,0xe0}, 
-{ 0xd8,0x6c,0x6c,0xb4},{  0xac,0x56,0x56,0xfa},{  0xf3,0xf4,0xf4,0x07},{  0xcf,0xea,0xea,0x25}, 
-{ 0xca,0x65,0x65,0xaf},{  0xf4,0x7a,0x7a,0x8e},{  0x47,0xae,0xae,0xe9},{  0x10,0x08,0x08,0x18}, 
-{ 0x6f,0xba,0xba,0xd5},{  0xf0,0x78,0x78,0x88},{  0x4a,0x25,0x25,0x6f},{  0x5c,0x2e,0x2e,0x72}, 
-{ 0x38,0x1c,0x1c,0x24},{  0x57,0xa6,0xa6,0xf1},{  0x73,0xb4,0xb4,0xc7},{  0x97,0xc6,0xc6,0x51}, 
-{ 0xcb,0xe8,0xe8,0x23},{  0xa1,0xdd,0xdd,0x7c},{  0xe8,0x74,0x74,0x9c},{  0x3e,0x1f,0x1f,0x21}, 
-{ 0x96,0x4b,0x4b,0xdd},{  0x61,0xbd,0xbd,0xdc},{  0x0d,0x8b,0x8b,0x86},{  0x0f,0x8a,0x8a,0x85}, 
-{ 0xe0,0x70,0x70,0x90},{  0x7c,0x3e,0x3e,0x42},{  0x71,0xb5,0xb5,0xc4},{  0xcc,0x66,0x66,0xaa}, 
-{ 0x90,0x48,0x48,0xd8},{  0x06,0x03,0x03,0x05},{  0xf7,0xf6,0xf6,0x01},{  0x1c,0x0e,0x0e,0x12}, 
-{ 0xc2,0x61,0x61,0xa3},{  0x6a,0x35,0x35,0x5f},{  0xae,0x57,0x57,0xf9},{  0x69,0xb9,0xb9,0xd0}, 
-{ 0x17,0x86,0x86,0x91},{  0x99,0xc1,0xc1,0x58},{  0x3a,0x1d,0x1d,0x27},{  0x27,0x9e,0x9e,0xb9}, 
-{ 0xd9,0xe1,0xe1,0x38},{  0xeb,0xf8,0xf8,0x13},{  0x2b,0x98,0x98,0xb3},{  0x22,0x11,0x11,0x33}, 
-{ 0xd2,0x69,0x69,0xbb},{  0xa9,0xd9,0xd9,0x70},{  0x07,0x8e,0x8e,0x89},{  0x33,0x94,0x94,0xa7}, 
-{ 0x2d,0x9b,0x9b,0xb6},{  0x3c,0x1e,0x1e,0x22},{  0x15,0x87,0x87,0x92},{  0xc9,0xe9,0xe9,0x20}, 
-{ 0x87,0xce,0xce,0x49},{  0xaa,0x55,0x55,0xff},{  0x50,0x28,0x28,0x78},{  0xa5,0xdf,0xdf,0x7a}, 
-{ 0x03,0x8c,0x8c,0x8f},{  0x59,0xa1,0xa1,0xf8},{  0x09,0x89,0x89,0x80},{  0x1a,0x0d,0x0d,0x17}, 
-{ 0x65,0xbf,0xbf,0xda},{  0xd7,0xe6,0xe6,0x31},{  0x84,0x42,0x42,0xc6},{  0xd0,0x68,0x68,0xb8}, 
-{ 0x82,0x41,0x41,0xc3},{  0x29,0x99,0x99,0xb0},{  0x5a,0x2d,0x2d,0x77},{  0x1e,0x0f,0x0f,0x11}, 
-{ 0x7b,0xb0,0xb0,0xcb},{  0xa8,0x54,0x54,0xfc},{  0x6d,0xbb,0xbb,0xd6},{  0x2c,0x16,0x16,0x3a } 
-};
-
-word8 T2[256][4] = {
-{ 0xa5,0xc6,0x63,0x63},{  0x84,0xf8,0x7c,0x7c},{  0x99,0xee,0x77,0x77},{  0x8d,0xf6,0x7b,0x7b}, 
-{ 0x0d,0xff,0xf2,0xf2},{  0xbd,0xd6,0x6b,0x6b},{  0xb1,0xde,0x6f,0x6f},{  0x54,0x91,0xc5,0xc5}, 
-{ 0x50,0x60,0x30,0x30},{  0x03,0x02,0x01,0x01},{  0xa9,0xce,0x67,0x67},{  0x7d,0x56,0x2b,0x2b}, 
-{ 0x19,0xe7,0xfe,0xfe},{  0x62,0xb5,0xd7,0xd7},{  0xe6,0x4d,0xab,0xab},{  0x9a,0xec,0x76,0x76}, 
-{ 0x45,0x8f,0xca,0xca},{  0x9d,0x1f,0x82,0x82},{  0x40,0x89,0xc9,0xc9},{  0x87,0xfa,0x7d,0x7d}, 
-{ 0x15,0xef,0xfa,0xfa},{  0xeb,0xb2,0x59,0x59},{  0xc9,0x8e,0x47,0x47},{  0x0b,0xfb,0xf0,0xf0}, 
-{ 0xec,0x41,0xad,0xad},{  0x67,0xb3,0xd4,0xd4},{  0xfd,0x5f,0xa2,0xa2},{  0xea,0x45,0xaf,0xaf}, 
-{ 0xbf,0x23,0x9c,0x9c},{  0xf7,0x53,0xa4,0xa4},{  0x96,0xe4,0x72,0x72},{  0x5b,0x9b,0xc0,0xc0}, 
-{ 0xc2,0x75,0xb7,0xb7},{  0x1c,0xe1,0xfd,0xfd},{  0xae,0x3d,0x93,0x93},{  0x6a,0x4c,0x26,0x26}, 
-{ 0x5a,0x6c,0x36,0x36},{  0x41,0x7e,0x3f,0x3f},{  0x02,0xf5,0xf7,0xf7},{  0x4f,0x83,0xcc,0xcc}, 
-{ 0x5c,0x68,0x34,0x34},{  0xf4,0x51,0xa5,0xa5},{  0x34,0xd1,0xe5,0xe5},{  0x08,0xf9,0xf1,0xf1}, 
-{ 0x93,0xe2,0x71,0x71},{  0x73,0xab,0xd8,0xd8},{  0x53,0x62,0x31,0x31},{  0x3f,0x2a,0x15,0x15}, 
-{ 0x0c,0x08,0x04,0x04},{  0x52,0x95,0xc7,0xc7},{  0x65,0x46,0x23,0x23},{  0x5e,0x9d,0xc3,0xc3}, 
-{ 0x28,0x30,0x18,0x18},{  0xa1,0x37,0x96,0x96},{  0x0f,0x0a,0x05,0x05},{  0xb5,0x2f,0x9a,0x9a}, 
-{ 0x09,0x0e,0x07,0x07},{  0x36,0x24,0x12,0x12},{  0x9b,0x1b,0x80,0x80},{  0x3d,0xdf,0xe2,0xe2}, 
-{ 0x26,0xcd,0xeb,0xeb},{  0x69,0x4e,0x27,0x27},{  0xcd,0x7f,0xb2,0xb2},{  0x9f,0xea,0x75,0x75}, 
-{ 0x1b,0x12,0x09,0x09},{  0x9e,0x1d,0x83,0x83},{  0x74,0x58,0x2c,0x2c},{  0x2e,0x34,0x1a,0x1a}, 
-{ 0x2d,0x36,0x1b,0x1b},{  0xb2,0xdc,0x6e,0x6e},{  0xee,0xb4,0x5a,0x5a},{  0xfb,0x5b,0xa0,0xa0}, 
-{ 0xf6,0xa4,0x52,0x52},{  0x4d,0x76,0x3b,0x3b},{  0x61,0xb7,0xd6,0xd6},{  0xce,0x7d,0xb3,0xb3}, 
-{ 0x7b,0x52,0x29,0x29},{  0x3e,0xdd,0xe3,0xe3},{  0x71,0x5e,0x2f,0x2f},{  0x97,0x13,0x84,0x84}, 
-{ 0xf5,0xa6,0x53,0x53},{  0x68,0xb9,0xd1,0xd1},{  0x00,0x00,0x00,0x00},{  0x2c,0xc1,0xed,0xed}, 
-{ 0x60,0x40,0x20,0x20},{  0x1f,0xe3,0xfc,0xfc},{  0xc8,0x79,0xb1,0xb1},{  0xed,0xb6,0x5b,0x5b}, 
-{ 0xbe,0xd4,0x6a,0x6a},{  0x46,0x8d,0xcb,0xcb},{  0xd9,0x67,0xbe,0xbe},{  0x4b,0x72,0x39,0x39}, 
-{ 0xde,0x94,0x4a,0x4a},{  0xd4,0x98,0x4c,0x4c},{  0xe8,0xb0,0x58,0x58},{  0x4a,0x85,0xcf,0xcf}, 
-{ 0x6b,0xbb,0xd0,0xd0},{  0x2a,0xc5,0xef,0xef},{  0xe5,0x4f,0xaa,0xaa},{  0x16,0xed,0xfb,0xfb}, 
-{ 0xc5,0x86,0x43,0x43},{  0xd7,0x9a,0x4d,0x4d},{  0x55,0x66,0x33,0x33},{  0x94,0x11,0x85,0x85}, 
-{ 0xcf,0x8a,0x45,0x45},{  0x10,0xe9,0xf9,0xf9},{  0x06,0x04,0x02,0x02},{  0x81,0xfe,0x7f,0x7f}, 
-{ 0xf0,0xa0,0x50,0x50},{  0x44,0x78,0x3c,0x3c},{  0xba,0x25,0x9f,0x9f},{  0xe3,0x4b,0xa8,0xa8}, 
-{ 0xf3,0xa2,0x51,0x51},{  0xfe,0x5d,0xa3,0xa3},{  0xc0,0x80,0x40,0x40},{  0x8a,0x05,0x8f,0x8f}, 
-{ 0xad,0x3f,0x92,0x92},{  0xbc,0x21,0x9d,0x9d},{  0x48,0x70,0x38,0x38},{  0x04,0xf1,0xf5,0xf5}, 
-{ 0xdf,0x63,0xbc,0xbc},{  0xc1,0x77,0xb6,0xb6},{  0x75,0xaf,0xda,0xda},{  0x63,0x42,0x21,0x21}, 
-{ 0x30,0x20,0x10,0x10},{  0x1a,0xe5,0xff,0xff},{  0x0e,0xfd,0xf3,0xf3},{  0x6d,0xbf,0xd2,0xd2}, 
-{ 0x4c,0x81,0xcd,0xcd},{  0x14,0x18,0x0c,0x0c},{  0x35,0x26,0x13,0x13},{  0x2f,0xc3,0xec,0xec}, 
-{ 0xe1,0xbe,0x5f,0x5f},{  0xa2,0x35,0x97,0x97},{  0xcc,0x88,0x44,0x44},{  0x39,0x2e,0x17,0x17}, 
-{ 0x57,0x93,0xc4,0xc4},{  0xf2,0x55,0xa7,0xa7},{  0x82,0xfc,0x7e,0x7e},{  0x47,0x7a,0x3d,0x3d}, 
-{ 0xac,0xc8,0x64,0x64},{  0xe7,0xba,0x5d,0x5d},{  0x2b,0x32,0x19,0x19},{  0x95,0xe6,0x73,0x73}, 
-{ 0xa0,0xc0,0x60,0x60},{  0x98,0x19,0x81,0x81},{  0xd1,0x9e,0x4f,0x4f},{  0x7f,0xa3,0xdc,0xdc}, 
-{ 0x66,0x44,0x22,0x22},{  0x7e,0x54,0x2a,0x2a},{  0xab,0x3b,0x90,0x90},{  0x83,0x0b,0x88,0x88}, 
-{ 0xca,0x8c,0x46,0x46},{  0x29,0xc7,0xee,0xee},{  0xd3,0x6b,0xb8,0xb8},{  0x3c,0x28,0x14,0x14}, 
-{ 0x79,0xa7,0xde,0xde},{  0xe2,0xbc,0x5e,0x5e},{  0x1d,0x16,0x0b,0x0b},{  0x76,0xad,0xdb,0xdb}, 
-{ 0x3b,0xdb,0xe0,0xe0},{  0x56,0x64,0x32,0x32},{  0x4e,0x74,0x3a,0x3a},{  0x1e,0x14,0x0a,0x0a}, 
-{ 0xdb,0x92,0x49,0x49},{  0x0a,0x0c,0x06,0x06},{  0x6c,0x48,0x24,0x24},{  0xe4,0xb8,0x5c,0x5c}, 
-{ 0x5d,0x9f,0xc2,0xc2},{  0x6e,0xbd,0xd3,0xd3},{  0xef,0x43,0xac,0xac},{  0xa6,0xc4,0x62,0x62}, 
-{ 0xa8,0x39,0x91,0x91},{  0xa4,0x31,0x95,0x95},{  0x37,0xd3,0xe4,0xe4},{  0x8b,0xf2,0x79,0x79}, 
-{ 0x32,0xd5,0xe7,0xe7},{  0x43,0x8b,0xc8,0xc8},{  0x59,0x6e,0x37,0x37},{  0xb7,0xda,0x6d,0x6d}, 
-{ 0x8c,0x01,0x8d,0x8d},{  0x64,0xb1,0xd5,0xd5},{  0xd2,0x9c,0x4e,0x4e},{  0xe0,0x49,0xa9,0xa9}, 
-{ 0xb4,0xd8,0x6c,0x6c},{  0xfa,0xac,0x56,0x56},{  0x07,0xf3,0xf4,0xf4},{  0x25,0xcf,0xea,0xea}, 
-{ 0xaf,0xca,0x65,0x65},{  0x8e,0xf4,0x7a,0x7a},{  0xe9,0x47,0xae,0xae},{  0x18,0x10,0x08,0x08}, 
-{ 0xd5,0x6f,0xba,0xba},{  0x88,0xf0,0x78,0x78},{  0x6f,0x4a,0x25,0x25},{  0x72,0x5c,0x2e,0x2e}, 
-{ 0x24,0x38,0x1c,0x1c},{  0xf1,0x57,0xa6,0xa6},{  0xc7,0x73,0xb4,0xb4},{  0x51,0x97,0xc6,0xc6}, 
-{ 0x23,0xcb,0xe8,0xe8},{  0x7c,0xa1,0xdd,0xdd},{  0x9c,0xe8,0x74,0x74},{  0x21,0x3e,0x1f,0x1f}, 
-{ 0xdd,0x96,0x4b,0x4b},{  0xdc,0x61,0xbd,0xbd},{  0x86,0x0d,0x8b,0x8b},{  0x85,0x0f,0x8a,0x8a}, 
-{ 0x90,0xe0,0x70,0x70},{  0x42,0x7c,0x3e,0x3e},{  0xc4,0x71,0xb5,0xb5},{  0xaa,0xcc,0x66,0x66}, 
-{ 0xd8,0x90,0x48,0x48},{  0x05,0x06,0x03,0x03},{  0x01,0xf7,0xf6,0xf6},{  0x12,0x1c,0x0e,0x0e}, 
-{ 0xa3,0xc2,0x61,0x61},{  0x5f,0x6a,0x35,0x35},{  0xf9,0xae,0x57,0x57},{  0xd0,0x69,0xb9,0xb9}, 
-{ 0x91,0x17,0x86,0x86},{  0x58,0x99,0xc1,0xc1},{  0x27,0x3a,0x1d,0x1d},{  0xb9,0x27,0x9e,0x9e}, 
-{ 0x38,0xd9,0xe1,0xe1},{  0x13,0xeb,0xf8,0xf8},{  0xb3,0x2b,0x98,0x98},{  0x33,0x22,0x11,0x11}, 
-{ 0xbb,0xd2,0x69,0x69},{  0x70,0xa9,0xd9,0xd9},{  0x89,0x07,0x8e,0x8e},{  0xa7,0x33,0x94,0x94}, 
-{ 0xb6,0x2d,0x9b,0x9b},{  0x22,0x3c,0x1e,0x1e},{  0x92,0x15,0x87,0x87},{  0x20,0xc9,0xe9,0xe9}, 
-{ 0x49,0x87,0xce,0xce},{  0xff,0xaa,0x55,0x55},{  0x78,0x50,0x28,0x28},{  0x7a,0xa5,0xdf,0xdf}, 
-{ 0x8f,0x03,0x8c,0x8c},{  0xf8,0x59,0xa1,0xa1},{  0x80,0x09,0x89,0x89},{  0x17,0x1a,0x0d,0x0d}, 
-{ 0xda,0x65,0xbf,0xbf},{  0x31,0xd7,0xe6,0xe6},{  0xc6,0x84,0x42,0x42},{  0xb8,0xd0,0x68,0x68}, 
-{ 0xc3,0x82,0x41,0x41},{  0xb0,0x29,0x99,0x99},{  0x77,0x5a,0x2d,0x2d},{  0x11,0x1e,0x0f,0x0f}, 
-{ 0xcb,0x7b,0xb0,0xb0},{  0xfc,0xa8,0x54,0x54},{  0xd6,0x6d,0xbb,0xbb},{  0x3a,0x2c,0x16,0x16 } 
-};
-
-word8 T3[256][4] = {
-{ 0x63,0xa5,0xc6,0x63},{  0x7c,0x84,0xf8,0x7c},{  0x77,0x99,0xee,0x77},{  0x7b,0x8d,0xf6,0x7b}, 
-{ 0xf2,0x0d,0xff,0xf2},{  0x6b,0xbd,0xd6,0x6b},{  0x6f,0xb1,0xde,0x6f},{  0xc5,0x54,0x91,0xc5}, 
-{ 0x30,0x50,0x60,0x30},{  0x01,0x03,0x02,0x01},{  0x67,0xa9,0xce,0x67},{  0x2b,0x7d,0x56,0x2b}, 
-{ 0xfe,0x19,0xe7,0xfe},{  0xd7,0x62,0xb5,0xd7},{  0xab,0xe6,0x4d,0xab},{  0x76,0x9a,0xec,0x76}, 
-{ 0xca,0x45,0x8f,0xca},{  0x82,0x9d,0x1f,0x82},{  0xc9,0x40,0x89,0xc9},{  0x7d,0x87,0xfa,0x7d}, 
-{ 0xfa,0x15,0xef,0xfa},{  0x59,0xeb,0xb2,0x59},{  0x47,0xc9,0x8e,0x47},{  0xf0,0x0b,0xfb,0xf0}, 
-{ 0xad,0xec,0x41,0xad},{  0xd4,0x67,0xb3,0xd4},{  0xa2,0xfd,0x5f,0xa2},{  0xaf,0xea,0x45,0xaf}, 
-{ 0x9c,0xbf,0x23,0x9c},{  0xa4,0xf7,0x53,0xa4},{  0x72,0x96,0xe4,0x72},{  0xc0,0x5b,0x9b,0xc0}, 
-{ 0xb7,0xc2,0x75,0xb7},{  0xfd,0x1c,0xe1,0xfd},{  0x93,0xae,0x3d,0x93},{  0x26,0x6a,0x4c,0x26}, 
-{ 0x36,0x5a,0x6c,0x36},{  0x3f,0x41,0x7e,0x3f},{  0xf7,0x02,0xf5,0xf7},{  0xcc,0x4f,0x83,0xcc}, 
-{ 0x34,0x5c,0x68,0x34},{  0xa5,0xf4,0x51,0xa5},{  0xe5,0x34,0xd1,0xe5},{  0xf1,0x08,0xf9,0xf1}, 
-{ 0x71,0x93,0xe2,0x71},{  0xd8,0x73,0xab,0xd8},{  0x31,0x53,0x62,0x31},{  0x15,0x3f,0x2a,0x15}, 
-{ 0x04,0x0c,0x08,0x04},{  0xc7,0x52,0x95,0xc7},{  0x23,0x65,0x46,0x23},{  0xc3,0x5e,0x9d,0xc3}, 
-{ 0x18,0x28,0x30,0x18},{  0x96,0xa1,0x37,0x96},{  0x05,0x0f,0x0a,0x05},{  0x9a,0xb5,0x2f,0x9a}, 
-{ 0x07,0x09,0x0e,0x07},{  0x12,0x36,0x24,0x12},{  0x80,0x9b,0x1b,0x80},{  0xe2,0x3d,0xdf,0xe2}, 
-{ 0xeb,0x26,0xcd,0xeb},{  0x27,0x69,0x4e,0x27},{  0xb2,0xcd,0x7f,0xb2},{  0x75,0x9f,0xea,0x75}, 
-{ 0x09,0x1b,0x12,0x09},{  0x83,0x9e,0x1d,0x83},{  0x2c,0x74,0x58,0x2c},{  0x1a,0x2e,0x34,0x1a}, 
-{ 0x1b,0x2d,0x36,0x1b},{  0x6e,0xb2,0xdc,0x6e},{  0x5a,0xee,0xb4,0x5a},{  0xa0,0xfb,0x5b,0xa0}, 
-{ 0x52,0xf6,0xa4,0x52},{  0x3b,0x4d,0x76,0x3b},{  0xd6,0x61,0xb7,0xd6},{  0xb3,0xce,0x7d,0xb3}, 
-{ 0x29,0x7b,0x52,0x29},{  0xe3,0x3e,0xdd,0xe3},{  0x2f,0x71,0x5e,0x2f},{  0x84,0x97,0x13,0x84}, 
-{ 0x53,0xf5,0xa6,0x53},{  0xd1,0x68,0xb9,0xd1},{  0x00,0x00,0x00,0x00},{  0xed,0x2c,0xc1,0xed}, 
-{ 0x20,0x60,0x40,0x20},{  0xfc,0x1f,0xe3,0xfc},{  0xb1,0xc8,0x79,0xb1},{  0x5b,0xed,0xb6,0x5b}, 
-{ 0x6a,0xbe,0xd4,0x6a},{  0xcb,0x46,0x8d,0xcb},{  0xbe,0xd9,0x67,0xbe},{  0x39,0x4b,0x72,0x39}, 
-{ 0x4a,0xde,0x94,0x4a},{  0x4c,0xd4,0x98,0x4c},{  0x58,0xe8,0xb0,0x58},{  0xcf,0x4a,0x85,0xcf}, 
-{ 0xd0,0x6b,0xbb,0xd0},{  0xef,0x2a,0xc5,0xef},{  0xaa,0xe5,0x4f,0xaa},{  0xfb,0x16,0xed,0xfb}, 
-{ 0x43,0xc5,0x86,0x43},{  0x4d,0xd7,0x9a,0x4d},{  0x33,0x55,0x66,0x33},{  0x85,0x94,0x11,0x85}, 
-{ 0x45,0xcf,0x8a,0x45},{  0xf9,0x10,0xe9,0xf9},{  0x02,0x06,0x04,0x02},{  0x7f,0x81,0xfe,0x7f}, 
-{ 0x50,0xf0,0xa0,0x50},{  0x3c,0x44,0x78,0x3c},{  0x9f,0xba,0x25,0x9f},{  0xa8,0xe3,0x4b,0xa8}, 
-{ 0x51,0xf3,0xa2,0x51},{  0xa3,0xfe,0x5d,0xa3},{  0x40,0xc0,0x80,0x40},{  0x8f,0x8a,0x05,0x8f}, 
-{ 0x92,0xad,0x3f,0x92},{  0x9d,0xbc,0x21,0x9d},{  0x38,0x48,0x70,0x38},{  0xf5,0x04,0xf1,0xf5}, 
-{ 0xbc,0xdf,0x63,0xbc},{  0xb6,0xc1,0x77,0xb6},{  0xda,0x75,0xaf,0xda},{  0x21,0x63,0x42,0x21}, 
-{ 0x10,0x30,0x20,0x10},{  0xff,0x1a,0xe5,0xff},{  0xf3,0x0e,0xfd,0xf3},{  0xd2,0x6d,0xbf,0xd2}, 
-{ 0xcd,0x4c,0x81,0xcd},{  0x0c,0x14,0x18,0x0c},{  0x13,0x35,0x26,0x13},{  0xec,0x2f,0xc3,0xec}, 
-{ 0x5f,0xe1,0xbe,0x5f},{  0x97,0xa2,0x35,0x97},{  0x44,0xcc,0x88,0x44},{  0x17,0x39,0x2e,0x17}, 
-{ 0xc4,0x57,0x93,0xc4},{  0xa7,0xf2,0x55,0xa7},{  0x7e,0x82,0xfc,0x7e},{  0x3d,0x47,0x7a,0x3d}, 
-{ 0x64,0xac,0xc8,0x64},{  0x5d,0xe7,0xba,0x5d},{  0x19,0x2b,0x32,0x19},{  0x73,0x95,0xe6,0x73}, 
-{ 0x60,0xa0,0xc0,0x60},{  0x81,0x98,0x19,0x81},{  0x4f,0xd1,0x9e,0x4f},{  0xdc,0x7f,0xa3,0xdc}, 
-{ 0x22,0x66,0x44,0x22},{  0x2a,0x7e,0x54,0x2a},{  0x90,0xab,0x3b,0x90},{  0x88,0x83,0x0b,0x88}, 
-{ 0x46,0xca,0x8c,0x46},{  0xee,0x29,0xc7,0xee},{  0xb8,0xd3,0x6b,0xb8},{  0x14,0x3c,0x28,0x14}, 
-{ 0xde,0x79,0xa7,0xde},{  0x5e,0xe2,0xbc,0x5e},{  0x0b,0x1d,0x16,0x0b},{  0xdb,0x76,0xad,0xdb}, 
-{ 0xe0,0x3b,0xdb,0xe0},{  0x32,0x56,0x64,0x32},{  0x3a,0x4e,0x74,0x3a},{  0x0a,0x1e,0x14,0x0a}, 
-{ 0x49,0xdb,0x92,0x49},{  0x06,0x0a,0x0c,0x06},{  0x24,0x6c,0x48,0x24},{  0x5c,0xe4,0xb8,0x5c}, 
-{ 0xc2,0x5d,0x9f,0xc2},{  0xd3,0x6e,0xbd,0xd3},{  0xac,0xef,0x43,0xac},{  0x62,0xa6,0xc4,0x62}, 
-{ 0x91,0xa8,0x39,0x91},{  0x95,0xa4,0x31,0x95},{  0xe4,0x37,0xd3,0xe4},{  0x79,0x8b,0xf2,0x79}, 
-{ 0xe7,0x32,0xd5,0xe7},{  0xc8,0x43,0x8b,0xc8},{  0x37,0x59,0x6e,0x37},{  0x6d,0xb7,0xda,0x6d}, 
-{ 0x8d,0x8c,0x01,0x8d},{  0xd5,0x64,0xb1,0xd5},{  0x4e,0xd2,0x9c,0x4e},{  0xa9,0xe0,0x49,0xa9}, 
-{ 0x6c,0xb4,0xd8,0x6c},{  0x56,0xfa,0xac,0x56},{  0xf4,0x07,0xf3,0xf4},{  0xea,0x25,0xcf,0xea}, 
-{ 0x65,0xaf,0xca,0x65},{  0x7a,0x8e,0xf4,0x7a},{  0xae,0xe9,0x47,0xae},{  0x08,0x18,0x10,0x08}, 
-{ 0xba,0xd5,0x6f,0xba},{  0x78,0x88,0xf0,0x78},{  0x25,0x6f,0x4a,0x25},{  0x2e,0x72,0x5c,0x2e}, 
-{ 0x1c,0x24,0x38,0x1c},{  0xa6,0xf1,0x57,0xa6},{  0xb4,0xc7,0x73,0xb4},{  0xc6,0x51,0x97,0xc6}, 
-{ 0xe8,0x23,0xcb,0xe8},{  0xdd,0x7c,0xa1,0xdd},{  0x74,0x9c,0xe8,0x74},{  0x1f,0x21,0x3e,0x1f}, 
-{ 0x4b,0xdd,0x96,0x4b},{  0xbd,0xdc,0x61,0xbd},{  0x8b,0x86,0x0d,0x8b},{  0x8a,0x85,0x0f,0x8a}, 
-{ 0x70,0x90,0xe0,0x70},{  0x3e,0x42,0x7c,0x3e},{  0xb5,0xc4,0x71,0xb5},{  0x66,0xaa,0xcc,0x66}, 
-{ 0x48,0xd8,0x90,0x48},{  0x03,0x05,0x06,0x03},{  0xf6,0x01,0xf7,0xf6},{  0x0e,0x12,0x1c,0x0e}, 
-{ 0x61,0xa3,0xc2,0x61},{  0x35,0x5f,0x6a,0x35},{  0x57,0xf9,0xae,0x57},{  0xb9,0xd0,0x69,0xb9}, 
-{ 0x86,0x91,0x17,0x86},{  0xc1,0x58,0x99,0xc1},{  0x1d,0x27,0x3a,0x1d},{  0x9e,0xb9,0x27,0x9e}, 
-{ 0xe1,0x38,0xd9,0xe1},{  0xf8,0x13,0xeb,0xf8},{  0x98,0xb3,0x2b,0x98},{  0x11,0x33,0x22,0x11}, 
-{ 0x69,0xbb,0xd2,0x69},{  0xd9,0x70,0xa9,0xd9},{  0x8e,0x89,0x07,0x8e},{  0x94,0xa7,0x33,0x94}, 
-{ 0x9b,0xb6,0x2d,0x9b},{  0x1e,0x22,0x3c,0x1e},{  0x87,0x92,0x15,0x87},{  0xe9,0x20,0xc9,0xe9}, 
-{ 0xce,0x49,0x87,0xce},{  0x55,0xff,0xaa,0x55},{  0x28,0x78,0x50,0x28},{  0xdf,0x7a,0xa5,0xdf}, 
-{ 0x8c,0x8f,0x03,0x8c},{  0xa1,0xf8,0x59,0xa1},{  0x89,0x80,0x09,0x89},{  0x0d,0x17,0x1a,0x0d}, 
-{ 0xbf,0xda,0x65,0xbf},{  0xe6,0x31,0xd7,0xe6},{  0x42,0xc6,0x84,0x42},{  0x68,0xb8,0xd0,0x68}, 
-{ 0x41,0xc3,0x82,0x41},{  0x99,0xb0,0x29,0x99},{  0x2d,0x77,0x5a,0x2d},{  0x0f,0x11,0x1e,0x0f}, 
-{ 0xb0,0xcb,0x7b,0xb0},{  0x54,0xfc,0xa8,0x54},{  0xbb,0xd6,0x6d,0xbb},{  0x16,0x3a,0x2c,0x16 } 
-};
-
-word8 T4[256][4] = {
-{ 0x63,0x63,0xa5,0xc6},{  0x7c,0x7c,0x84,0xf8},{  0x77,0x77,0x99,0xee},{  0x7b,0x7b,0x8d,0xf6}, 
-{ 0xf2,0xf2,0x0d,0xff},{  0x6b,0x6b,0xbd,0xd6},{  0x6f,0x6f,0xb1,0xde},{  0xc5,0xc5,0x54,0x91}, 
-{ 0x30,0x30,0x50,0x60},{  0x01,0x01,0x03,0x02},{  0x67,0x67,0xa9,0xce},{  0x2b,0x2b,0x7d,0x56}, 
-{ 0xfe,0xfe,0x19,0xe7},{  0xd7,0xd7,0x62,0xb5},{  0xab,0xab,0xe6,0x4d},{  0x76,0x76,0x9a,0xec}, 
-{ 0xca,0xca,0x45,0x8f},{  0x82,0x82,0x9d,0x1f},{  0xc9,0xc9,0x40,0x89},{  0x7d,0x7d,0x87,0xfa}, 
-{ 0xfa,0xfa,0x15,0xef},{  0x59,0x59,0xeb,0xb2},{  0x47,0x47,0xc9,0x8e},{  0xf0,0xf0,0x0b,0xfb}, 
-{ 0xad,0xad,0xec,0x41},{  0xd4,0xd4,0x67,0xb3},{  0xa2,0xa2,0xfd,0x5f},{  0xaf,0xaf,0xea,0x45}, 
-{ 0x9c,0x9c,0xbf,0x23},{  0xa4,0xa4,0xf7,0x53},{  0x72,0x72,0x96,0xe4},{  0xc0,0xc0,0x5b,0x9b}, 
-{ 0xb7,0xb7,0xc2,0x75},{  0xfd,0xfd,0x1c,0xe1},{  0x93,0x93,0xae,0x3d},{  0x26,0x26,0x6a,0x4c}, 
-{ 0x36,0x36,0x5a,0x6c},{  0x3f,0x3f,0x41,0x7e},{  0xf7,0xf7,0x02,0xf5},{  0xcc,0xcc,0x4f,0x83}, 
-{ 0x34,0x34,0x5c,0x68},{  0xa5,0xa5,0xf4,0x51},{  0xe5,0xe5,0x34,0xd1},{  0xf1,0xf1,0x08,0xf9}, 
-{ 0x71,0x71,0x93,0xe2},{  0xd8,0xd8,0x73,0xab},{  0x31,0x31,0x53,0x62},{  0x15,0x15,0x3f,0x2a}, 
-{ 0x04,0x04,0x0c,0x08},{  0xc7,0xc7,0x52,0x95},{  0x23,0x23,0x65,0x46},{  0xc3,0xc3,0x5e,0x9d}, 
-{ 0x18,0x18,0x28,0x30},{  0x96,0x96,0xa1,0x37},{  0x05,0x05,0x0f,0x0a},{  0x9a,0x9a,0xb5,0x2f}, 
-{ 0x07,0x07,0x09,0x0e},{  0x12,0x12,0x36,0x24},{  0x80,0x80,0x9b,0x1b},{  0xe2,0xe2,0x3d,0xdf}, 
-{ 0xeb,0xeb,0x26,0xcd},{  0x27,0x27,0x69,0x4e},{  0xb2,0xb2,0xcd,0x7f},{  0x75,0x75,0x9f,0xea}, 
-{ 0x09,0x09,0x1b,0x12},{  0x83,0x83,0x9e,0x1d},{  0x2c,0x2c,0x74,0x58},{  0x1a,0x1a,0x2e,0x34}, 
-{ 0x1b,0x1b,0x2d,0x36},{  0x6e,0x6e,0xb2,0xdc},{  0x5a,0x5a,0xee,0xb4},{  0xa0,0xa0,0xfb,0x5b}, 
-{ 0x52,0x52,0xf6,0xa4},{  0x3b,0x3b,0x4d,0x76},{  0xd6,0xd6,0x61,0xb7},{  0xb3,0xb3,0xce,0x7d}, 
-{ 0x29,0x29,0x7b,0x52},{  0xe3,0xe3,0x3e,0xdd},{  0x2f,0x2f,0x71,0x5e},{  0x84,0x84,0x97,0x13}, 
-{ 0x53,0x53,0xf5,0xa6},{  0xd1,0xd1,0x68,0xb9},{  0x00,0x00,0x00,0x00},{  0xed,0xed,0x2c,0xc1}, 
-{ 0x20,0x20,0x60,0x40},{  0xfc,0xfc,0x1f,0xe3},{  0xb1,0xb1,0xc8,0x79},{  0x5b,0x5b,0xed,0xb6}, 
-{ 0x6a,0x6a,0xbe,0xd4},{  0xcb,0xcb,0x46,0x8d},{  0xbe,0xbe,0xd9,0x67},{  0x39,0x39,0x4b,0x72}, 
-{ 0x4a,0x4a,0xde,0x94},{  0x4c,0x4c,0xd4,0x98},{  0x58,0x58,0xe8,0xb0},{  0xcf,0xcf,0x4a,0x85}, 
-{ 0xd0,0xd0,0x6b,0xbb},{  0xef,0xef,0x2a,0xc5},{  0xaa,0xaa,0xe5,0x4f},{  0xfb,0xfb,0x16,0xed}, 
-{ 0x43,0x43,0xc5,0x86},{  0x4d,0x4d,0xd7,0x9a},{  0x33,0x33,0x55,0x66},{  0x85,0x85,0x94,0x11}, 
-{ 0x45,0x45,0xcf,0x8a},{  0xf9,0xf9,0x10,0xe9},{  0x02,0x02,0x06,0x04},{  0x7f,0x7f,0x81,0xfe}, 
-{ 0x50,0x50,0xf0,0xa0},{  0x3c,0x3c,0x44,0x78},{  0x9f,0x9f,0xba,0x25},{  0xa8,0xa8,0xe3,0x4b}, 
-{ 0x51,0x51,0xf3,0xa2},{  0xa3,0xa3,0xfe,0x5d},{  0x40,0x40,0xc0,0x80},{  0x8f,0x8f,0x8a,0x05}, 
-{ 0x92,0x92,0xad,0x3f},{  0x9d,0x9d,0xbc,0x21},{  0x38,0x38,0x48,0x70},{  0xf5,0xf5,0x04,0xf1}, 
-{ 0xbc,0xbc,0xdf,0x63},{  0xb6,0xb6,0xc1,0x77},{  0xda,0xda,0x75,0xaf},{  0x21,0x21,0x63,0x42}, 
-{ 0x10,0x10,0x30,0x20},{  0xff,0xff,0x1a,0xe5},{  0xf3,0xf3,0x0e,0xfd},{  0xd2,0xd2,0x6d,0xbf}, 
-{ 0xcd,0xcd,0x4c,0x81},{  0x0c,0x0c,0x14,0x18},{  0x13,0x13,0x35,0x26},{  0xec,0xec,0x2f,0xc3}, 
-{ 0x5f,0x5f,0xe1,0xbe},{  0x97,0x97,0xa2,0x35},{  0x44,0x44,0xcc,0x88},{  0x17,0x17,0x39,0x2e}, 
-{ 0xc4,0xc4,0x57,0x93},{  0xa7,0xa7,0xf2,0x55},{  0x7e,0x7e,0x82,0xfc},{  0x3d,0x3d,0x47,0x7a}, 
-{ 0x64,0x64,0xac,0xc8},{  0x5d,0x5d,0xe7,0xba},{  0x19,0x19,0x2b,0x32},{  0x73,0x73,0x95,0xe6}, 
-{ 0x60,0x60,0xa0,0xc0},{  0x81,0x81,0x98,0x19},{  0x4f,0x4f,0xd1,0x9e},{  0xdc,0xdc,0x7f,0xa3}, 
-{ 0x22,0x22,0x66,0x44},{  0x2a,0x2a,0x7e,0x54},{  0x90,0x90,0xab,0x3b},{  0x88,0x88,0x83,0x0b}, 
-{ 0x46,0x46,0xca,0x8c},{  0xee,0xee,0x29,0xc7},{  0xb8,0xb8,0xd3,0x6b},{  0x14,0x14,0x3c,0x28}, 
-{ 0xde,0xde,0x79,0xa7},{  0x5e,0x5e,0xe2,0xbc},{  0x0b,0x0b,0x1d,0x16},{  0xdb,0xdb,0x76,0xad}, 
-{ 0xe0,0xe0,0x3b,0xdb},{  0x32,0x32,0x56,0x64},{  0x3a,0x3a,0x4e,0x74},{  0x0a,0x0a,0x1e,0x14}, 
-{ 0x49,0x49,0xdb,0x92},{  0x06,0x06,0x0a,0x0c},{  0x24,0x24,0x6c,0x48},{  0x5c,0x5c,0xe4,0xb8}, 
-{ 0xc2,0xc2,0x5d,0x9f},{  0xd3,0xd3,0x6e,0xbd},{  0xac,0xac,0xef,0x43},{  0x62,0x62,0xa6,0xc4}, 
-{ 0x91,0x91,0xa8,0x39},{  0x95,0x95,0xa4,0x31},{  0xe4,0xe4,0x37,0xd3},{  0x79,0x79,0x8b,0xf2}, 
-{ 0xe7,0xe7,0x32,0xd5},{  0xc8,0xc8,0x43,0x8b},{  0x37,0x37,0x59,0x6e},{  0x6d,0x6d,0xb7,0xda}, 
-{ 0x8d,0x8d,0x8c,0x01},{  0xd5,0xd5,0x64,0xb1},{  0x4e,0x4e,0xd2,0x9c},{  0xa9,0xa9,0xe0,0x49}, 
-{ 0x6c,0x6c,0xb4,0xd8},{  0x56,0x56,0xfa,0xac},{  0xf4,0xf4,0x07,0xf3},{  0xea,0xea,0x25,0xcf}, 
-{ 0x65,0x65,0xaf,0xca},{  0x7a,0x7a,0x8e,0xf4},{  0xae,0xae,0xe9,0x47},{  0x08,0x08,0x18,0x10}, 
-{ 0xba,0xba,0xd5,0x6f},{  0x78,0x78,0x88,0xf0},{  0x25,0x25,0x6f,0x4a},{  0x2e,0x2e,0x72,0x5c}, 
-{ 0x1c,0x1c,0x24,0x38},{  0xa6,0xa6,0xf1,0x57},{  0xb4,0xb4,0xc7,0x73},{  0xc6,0xc6,0x51,0x97}, 
-{ 0xe8,0xe8,0x23,0xcb},{  0xdd,0xdd,0x7c,0xa1},{  0x74,0x74,0x9c,0xe8},{  0x1f,0x1f,0x21,0x3e}, 
-{ 0x4b,0x4b,0xdd,0x96},{  0xbd,0xbd,0xdc,0x61},{  0x8b,0x8b,0x86,0x0d},{  0x8a,0x8a,0x85,0x0f}, 
-{ 0x70,0x70,0x90,0xe0},{  0x3e,0x3e,0x42,0x7c},{  0xb5,0xb5,0xc4,0x71},{  0x66,0x66,0xaa,0xcc}, 
-{ 0x48,0x48,0xd8,0x90},{  0x03,0x03,0x05,0x06},{  0xf6,0xf6,0x01,0xf7},{  0x0e,0x0e,0x12,0x1c}, 
-{ 0x61,0x61,0xa3,0xc2},{  0x35,0x35,0x5f,0x6a},{  0x57,0x57,0xf9,0xae},{  0xb9,0xb9,0xd0,0x69}, 
-{ 0x86,0x86,0x91,0x17},{  0xc1,0xc1,0x58,0x99},{  0x1d,0x1d,0x27,0x3a},{  0x9e,0x9e,0xb9,0x27}, 
-{ 0xe1,0xe1,0x38,0xd9},{  0xf8,0xf8,0x13,0xeb},{  0x98,0x98,0xb3,0x2b},{  0x11,0x11,0x33,0x22}, 
-{ 0x69,0x69,0xbb,0xd2},{  0xd9,0xd9,0x70,0xa9},{  0x8e,0x8e,0x89,0x07},{  0x94,0x94,0xa7,0x33}, 
-{ 0x9b,0x9b,0xb6,0x2d},{  0x1e,0x1e,0x22,0x3c},{  0x87,0x87,0x92,0x15},{  0xe9,0xe9,0x20,0xc9}, 
-{ 0xce,0xce,0x49,0x87},{  0x55,0x55,0xff,0xaa},{  0x28,0x28,0x78,0x50},{  0xdf,0xdf,0x7a,0xa5}, 
-{ 0x8c,0x8c,0x8f,0x03},{  0xa1,0xa1,0xf8,0x59},{  0x89,0x89,0x80,0x09},{  0x0d,0x0d,0x17,0x1a}, 
-{ 0xbf,0xbf,0xda,0x65},{  0xe6,0xe6,0x31,0xd7},{  0x42,0x42,0xc6,0x84},{  0x68,0x68,0xb8,0xd0}, 
-{ 0x41,0x41,0xc3,0x82},{  0x99,0x99,0xb0,0x29},{  0x2d,0x2d,0x77,0x5a},{  0x0f,0x0f,0x11,0x1e}, 
-{ 0xb0,0xb0,0xcb,0x7b},{  0x54,0x54,0xfc,0xa8},{  0xbb,0xbb,0xd6,0x6d},{  0x16,0x16,0x3a,0x2c } 
-};
-
-word8 T5[256][4] = {
-{ 0x51,0xf4,0xa7,0x50},{  0x7e,0x41,0x65,0x53},{  0x1a,0x17,0xa4,0xc3},{  0x3a,0x27,0x5e,0x96}, 
-{ 0x3b,0xab,0x6b,0xcb},{  0x1f,0x9d,0x45,0xf1},{  0xac,0xfa,0x58,0xab},{  0x4b,0xe3,0x03,0x93}, 
-{ 0x20,0x30,0xfa,0x55},{  0xad,0x76,0x6d,0xf6},{  0x88,0xcc,0x76,0x91},{  0xf5,0x02,0x4c,0x25}, 
-{ 0x4f,0xe5,0xd7,0xfc},{  0xc5,0x2a,0xcb,0xd7},{  0x26,0x35,0x44,0x80},{  0xb5,0x62,0xa3,0x8f}, 
-{ 0xde,0xb1,0x5a,0x49},{  0x25,0xba,0x1b,0x67},{  0x45,0xea,0x0e,0x98},{  0x5d,0xfe,0xc0,0xe1}, 
-{ 0xc3,0x2f,0x75,0x02},{  0x81,0x4c,0xf0,0x12},{  0x8d,0x46,0x97,0xa3},{  0x6b,0xd3,0xf9,0xc6}, 
-{ 0x03,0x8f,0x5f,0xe7},{  0x15,0x92,0x9c,0x95},{  0xbf,0x6d,0x7a,0xeb},{  0x95,0x52,0x59,0xda}, 
-{ 0xd4,0xbe,0x83,0x2d},{  0x58,0x74,0x21,0xd3},{  0x49,0xe0,0x69,0x29},{  0x8e,0xc9,0xc8,0x44}, 
-{ 0x75,0xc2,0x89,0x6a},{  0xf4,0x8e,0x79,0x78},{  0x99,0x58,0x3e,0x6b},{  0x27,0xb9,0x71,0xdd}, 
-{ 0xbe,0xe1,0x4f,0xb6},{  0xf0,0x88,0xad,0x17},{  0xc9,0x20,0xac,0x66},{  0x7d,0xce,0x3a,0xb4}, 
-{ 0x63,0xdf,0x4a,0x18},{  0xe5,0x1a,0x31,0x82},{  0x97,0x51,0x33,0x60},{  0x62,0x53,0x7f,0x45}, 
-{ 0xb1,0x64,0x77,0xe0},{  0xbb,0x6b,0xae,0x84},{  0xfe,0x81,0xa0,0x1c},{  0xf9,0x08,0x2b,0x94}, 
-{ 0x70,0x48,0x68,0x58},{  0x8f,0x45,0xfd,0x19},{  0x94,0xde,0x6c,0x87},{  0x52,0x7b,0xf8,0xb7}, 
-{ 0xab,0x73,0xd3,0x23},{  0x72,0x4b,0x02,0xe2},{  0xe3,0x1f,0x8f,0x57},{  0x66,0x55,0xab,0x2a}, 
-{ 0xb2,0xeb,0x28,0x07},{  0x2f,0xb5,0xc2,0x03},{  0x86,0xc5,0x7b,0x9a},{  0xd3,0x37,0x08,0xa5}, 
-{ 0x30,0x28,0x87,0xf2},{  0x23,0xbf,0xa5,0xb2},{  0x02,0x03,0x6a,0xba},{  0xed,0x16,0x82,0x5c}, 
-{ 0x8a,0xcf,0x1c,0x2b},{  0xa7,0x79,0xb4,0x92},{  0xf3,0x07,0xf2,0xf0},{  0x4e,0x69,0xe2,0xa1}, 
-{ 0x65,0xda,0xf4,0xcd},{  0x06,0x05,0xbe,0xd5},{  0xd1,0x34,0x62,0x1f},{  0xc4,0xa6,0xfe,0x8a}, 
-{ 0x34,0x2e,0x53,0x9d},{  0xa2,0xf3,0x55,0xa0},{  0x05,0x8a,0xe1,0x32},{  0xa4,0xf6,0xeb,0x75}, 
-{ 0x0b,0x83,0xec,0x39},{  0x40,0x60,0xef,0xaa},{  0x5e,0x71,0x9f,0x06},{  0xbd,0x6e,0x10,0x51}, 
-{ 0x3e,0x21,0x8a,0xf9},{  0x96,0xdd,0x06,0x3d},{  0xdd,0x3e,0x05,0xae},{  0x4d,0xe6,0xbd,0x46}, 
-{ 0x91,0x54,0x8d,0xb5},{  0x71,0xc4,0x5d,0x05},{  0x04,0x06,0xd4,0x6f},{  0x60,0x50,0x15,0xff}, 
-{ 0x19,0x98,0xfb,0x24},{  0xd6,0xbd,0xe9,0x97},{  0x89,0x40,0x43,0xcc},{  0x67,0xd9,0x9e,0x77}, 
-{ 0xb0,0xe8,0x42,0xbd},{  0x07,0x89,0x8b,0x88},{  0xe7,0x19,0x5b,0x38},{  0x79,0xc8,0xee,0xdb}, 
-{ 0xa1,0x7c,0x0a,0x47},{  0x7c,0x42,0x0f,0xe9},{  0xf8,0x84,0x1e,0xc9},{  0x00,0x00,0x00,0x00}, 
-{ 0x09,0x80,0x86,0x83},{  0x32,0x2b,0xed,0x48},{  0x1e,0x11,0x70,0xac},{  0x6c,0x5a,0x72,0x4e}, 
-{ 0xfd,0x0e,0xff,0xfb},{  0x0f,0x85,0x38,0x56},{  0x3d,0xae,0xd5,0x1e},{  0x36,0x2d,0x39,0x27}, 
-{ 0x0a,0x0f,0xd9,0x64},{  0x68,0x5c,0xa6,0x21},{  0x9b,0x5b,0x54,0xd1},{  0x24,0x36,0x2e,0x3a}, 
-{ 0x0c,0x0a,0x67,0xb1},{  0x93,0x57,0xe7,0x0f},{  0xb4,0xee,0x96,0xd2},{  0x1b,0x9b,0x91,0x9e}, 
-{ 0x80,0xc0,0xc5,0x4f},{  0x61,0xdc,0x20,0xa2},{  0x5a,0x77,0x4b,0x69},{  0x1c,0x12,0x1a,0x16}, 
-{ 0xe2,0x93,0xba,0x0a},{  0xc0,0xa0,0x2a,0xe5},{  0x3c,0x22,0xe0,0x43},{  0x12,0x1b,0x17,0x1d}, 
-{ 0x0e,0x09,0x0d,0x0b},{  0xf2,0x8b,0xc7,0xad},{  0x2d,0xb6,0xa8,0xb9},{  0x14,0x1e,0xa9,0xc8}, 
-{ 0x57,0xf1,0x19,0x85},{  0xaf,0x75,0x07,0x4c},{  0xee,0x99,0xdd,0xbb},{  0xa3,0x7f,0x60,0xfd}, 
-{ 0xf7,0x01,0x26,0x9f},{  0x5c,0x72,0xf5,0xbc},{  0x44,0x66,0x3b,0xc5},{  0x5b,0xfb,0x7e,0x34}, 
-{ 0x8b,0x43,0x29,0x76},{  0xcb,0x23,0xc6,0xdc},{  0xb6,0xed,0xfc,0x68},{  0xb8,0xe4,0xf1,0x63}, 
-{ 0xd7,0x31,0xdc,0xca},{  0x42,0x63,0x85,0x10},{  0x13,0x97,0x22,0x40},{  0x84,0xc6,0x11,0x20}, 
-{ 0x85,0x4a,0x24,0x7d},{  0xd2,0xbb,0x3d,0xf8},{  0xae,0xf9,0x32,0x11},{  0xc7,0x29,0xa1,0x6d}, 
-{ 0x1d,0x9e,0x2f,0x4b},{  0xdc,0xb2,0x30,0xf3},{  0x0d,0x86,0x52,0xec},{  0x77,0xc1,0xe3,0xd0}, 
-{ 0x2b,0xb3,0x16,0x6c},{  0xa9,0x70,0xb9,0x99},{  0x11,0x94,0x48,0xfa},{  0x47,0xe9,0x64,0x22}, 
-{ 0xa8,0xfc,0x8c,0xc4},{  0xa0,0xf0,0x3f,0x1a},{  0x56,0x7d,0x2c,0xd8},{  0x22,0x33,0x90,0xef}, 
-{ 0x87,0x49,0x4e,0xc7},{  0xd9,0x38,0xd1,0xc1},{  0x8c,0xca,0xa2,0xfe},{  0x98,0xd4,0x0b,0x36}, 
-{ 0xa6,0xf5,0x81,0xcf},{  0xa5,0x7a,0xde,0x28},{  0xda,0xb7,0x8e,0x26},{  0x3f,0xad,0xbf,0xa4}, 
-{ 0x2c,0x3a,0x9d,0xe4},{  0x50,0x78,0x92,0x0d},{  0x6a,0x5f,0xcc,0x9b},{  0x54,0x7e,0x46,0x62}, 
-{ 0xf6,0x8d,0x13,0xc2},{  0x90,0xd8,0xb8,0xe8},{  0x2e,0x39,0xf7,0x5e},{  0x82,0xc3,0xaf,0xf5}, 
-{ 0x9f,0x5d,0x80,0xbe},{  0x69,0xd0,0x93,0x7c},{  0x6f,0xd5,0x2d,0xa9},{  0xcf,0x25,0x12,0xb3}, 
-{ 0xc8,0xac,0x99,0x3b},{  0x10,0x18,0x7d,0xa7},{  0xe8,0x9c,0x63,0x6e},{  0xdb,0x3b,0xbb,0x7b}, 
-{ 0xcd,0x26,0x78,0x09},{  0x6e,0x59,0x18,0xf4},{  0xec,0x9a,0xb7,0x01},{  0x83,0x4f,0x9a,0xa8}, 
-{ 0xe6,0x95,0x6e,0x65},{  0xaa,0xff,0xe6,0x7e},{  0x21,0xbc,0xcf,0x08},{  0xef,0x15,0xe8,0xe6}, 
-{ 0xba,0xe7,0x9b,0xd9},{  0x4a,0x6f,0x36,0xce},{  0xea,0x9f,0x09,0xd4},{  0x29,0xb0,0x7c,0xd6}, 
-{ 0x31,0xa4,0xb2,0xaf},{  0x2a,0x3f,0x23,0x31},{  0xc6,0xa5,0x94,0x30},{  0x35,0xa2,0x66,0xc0}, 
-{ 0x74,0x4e,0xbc,0x37},{  0xfc,0x82,0xca,0xa6},{  0xe0,0x90,0xd0,0xb0},{  0x33,0xa7,0xd8,0x15}, 
-{ 0xf1,0x04,0x98,0x4a},{  0x41,0xec,0xda,0xf7},{  0x7f,0xcd,0x50,0x0e},{  0x17,0x91,0xf6,0x2f}, 
-{ 0x76,0x4d,0xd6,0x8d},{  0x43,0xef,0xb0,0x4d},{  0xcc,0xaa,0x4d,0x54},{  0xe4,0x96,0x04,0xdf}, 
-{ 0x9e,0xd1,0xb5,0xe3},{  0x4c,0x6a,0x88,0x1b},{  0xc1,0x2c,0x1f,0xb8},{  0x46,0x65,0x51,0x7f}, 
-{ 0x9d,0x5e,0xea,0x04},{  0x01,0x8c,0x35,0x5d},{  0xfa,0x87,0x74,0x73},{  0xfb,0x0b,0x41,0x2e}, 
-{ 0xb3,0x67,0x1d,0x5a},{  0x92,0xdb,0xd2,0x52},{  0xe9,0x10,0x56,0x33},{  0x6d,0xd6,0x47,0x13}, 
-{ 0x9a,0xd7,0x61,0x8c},{  0x37,0xa1,0x0c,0x7a},{  0x59,0xf8,0x14,0x8e},{  0xeb,0x13,0x3c,0x89}, 
-{ 0xce,0xa9,0x27,0xee},{  0xb7,0x61,0xc9,0x35},{  0xe1,0x1c,0xe5,0xed},{  0x7a,0x47,0xb1,0x3c}, 
-{ 0x9c,0xd2,0xdf,0x59},{  0x55,0xf2,0x73,0x3f},{  0x18,0x14,0xce,0x79},{  0x73,0xc7,0x37,0xbf}, 
-{ 0x53,0xf7,0xcd,0xea},{  0x5f,0xfd,0xaa,0x5b},{  0xdf,0x3d,0x6f,0x14},{  0x78,0x44,0xdb,0x86}, 
-{ 0xca,0xaf,0xf3,0x81},{  0xb9,0x68,0xc4,0x3e},{  0x38,0x24,0x34,0x2c},{  0xc2,0xa3,0x40,0x5f}, 
-{ 0x16,0x1d,0xc3,0x72},{  0xbc,0xe2,0x25,0x0c},{  0x28,0x3c,0x49,0x8b},{  0xff,0x0d,0x95,0x41}, 
-{ 0x39,0xa8,0x01,0x71},{  0x08,0x0c,0xb3,0xde},{  0xd8,0xb4,0xe4,0x9c},{  0x64,0x56,0xc1,0x90}, 
-{ 0x7b,0xcb,0x84,0x61},{  0xd5,0x32,0xb6,0x70},{  0x48,0x6c,0x5c,0x74},{  0xd0,0xb8,0x57,0x42 } 
-};
-
-word8 T6[256][4] = {
-{ 0x50,0x51,0xf4,0xa7},{  0x53,0x7e,0x41,0x65},{  0xc3,0x1a,0x17,0xa4},{  0x96,0x3a,0x27,0x5e}, 
-{ 0xcb,0x3b,0xab,0x6b},{  0xf1,0x1f,0x9d,0x45},{  0xab,0xac,0xfa,0x58},{  0x93,0x4b,0xe3,0x03}, 
-{ 0x55,0x20,0x30,0xfa},{  0xf6,0xad,0x76,0x6d},{  0x91,0x88,0xcc,0x76},{  0x25,0xf5,0x02,0x4c}, 
-{ 0xfc,0x4f,0xe5,0xd7},{  0xd7,0xc5,0x2a,0xcb},{  0x80,0x26,0x35,0x44},{  0x8f,0xb5,0x62,0xa3}, 
-{ 0x49,0xde,0xb1,0x5a},{  0x67,0x25,0xba,0x1b},{  0x98,0x45,0xea,0x0e},{  0xe1,0x5d,0xfe,0xc0}, 
-{ 0x02,0xc3,0x2f,0x75},{  0x12,0x81,0x4c,0xf0},{  0xa3,0x8d,0x46,0x97},{  0xc6,0x6b,0xd3,0xf9}, 
-{ 0xe7,0x03,0x8f,0x5f},{  0x95,0x15,0x92,0x9c},{  0xeb,0xbf,0x6d,0x7a},{  0xda,0x95,0x52,0x59}, 
-{ 0x2d,0xd4,0xbe,0x83},{  0xd3,0x58,0x74,0x21},{  0x29,0x49,0xe0,0x69},{  0x44,0x8e,0xc9,0xc8}, 
-{ 0x6a,0x75,0xc2,0x89},{  0x78,0xf4,0x8e,0x79},{  0x6b,0x99,0x58,0x3e},{  0xdd,0x27,0xb9,0x71}, 
-{ 0xb6,0xbe,0xe1,0x4f},{  0x17,0xf0,0x88,0xad},{  0x66,0xc9,0x20,0xac},{  0xb4,0x7d,0xce,0x3a}, 
-{ 0x18,0x63,0xdf,0x4a},{  0x82,0xe5,0x1a,0x31},{  0x60,0x97,0x51,0x33},{  0x45,0x62,0x53,0x7f}, 
-{ 0xe0,0xb1,0x64,0x77},{  0x84,0xbb,0x6b,0xae},{  0x1c,0xfe,0x81,0xa0},{  0x94,0xf9,0x08,0x2b}, 
-{ 0x58,0x70,0x48,0x68},{  0x19,0x8f,0x45,0xfd},{  0x87,0x94,0xde,0x6c},{  0xb7,0x52,0x7b,0xf8}, 
-{ 0x23,0xab,0x73,0xd3},{  0xe2,0x72,0x4b,0x02},{  0x57,0xe3,0x1f,0x8f},{  0x2a,0x66,0x55,0xab}, 
-{ 0x07,0xb2,0xeb,0x28},{  0x03,0x2f,0xb5,0xc2},{  0x9a,0x86,0xc5,0x7b},{  0xa5,0xd3,0x37,0x08}, 
-{ 0xf2,0x30,0x28,0x87},{  0xb2,0x23,0xbf,0xa5},{  0xba,0x02,0x03,0x6a},{  0x5c,0xed,0x16,0x82}, 
-{ 0x2b,0x8a,0xcf,0x1c},{  0x92,0xa7,0x79,0xb4},{  0xf0,0xf3,0x07,0xf2},{  0xa1,0x4e,0x69,0xe2}, 
-{ 0xcd,0x65,0xda,0xf4},{  0xd5,0x06,0x05,0xbe},{  0x1f,0xd1,0x34,0x62},{  0x8a,0xc4,0xa6,0xfe}, 
-{ 0x9d,0x34,0x2e,0x53},{  0xa0,0xa2,0xf3,0x55},{  0x32,0x05,0x8a,0xe1},{  0x75,0xa4,0xf6,0xeb}, 
-{ 0x39,0x0b,0x83,0xec},{  0xaa,0x40,0x60,0xef},{  0x06,0x5e,0x71,0x9f},{  0x51,0xbd,0x6e,0x10}, 
-{ 0xf9,0x3e,0x21,0x8a},{  0x3d,0x96,0xdd,0x06},{  0xae,0xdd,0x3e,0x05},{  0x46,0x4d,0xe6,0xbd}, 
-{ 0xb5,0x91,0x54,0x8d},{  0x05,0x71,0xc4,0x5d},{  0x6f,0x04,0x06,0xd4},{  0xff,0x60,0x50,0x15}, 
-{ 0x24,0x19,0x98,0xfb},{  0x97,0xd6,0xbd,0xe9},{  0xcc,0x89,0x40,0x43},{  0x77,0x67,0xd9,0x9e}, 
-{ 0xbd,0xb0,0xe8,0x42},{  0x88,0x07,0x89,0x8b},{  0x38,0xe7,0x19,0x5b},{  0xdb,0x79,0xc8,0xee}, 
-{ 0x47,0xa1,0x7c,0x0a},{  0xe9,0x7c,0x42,0x0f},{  0xc9,0xf8,0x84,0x1e},{  0x00,0x00,0x00,0x00}, 
-{ 0x83,0x09,0x80,0x86},{  0x48,0x32,0x2b,0xed},{  0xac,0x1e,0x11,0x70},{  0x4e,0x6c,0x5a,0x72}, 
-{ 0xfb,0xfd,0x0e,0xff},{  0x56,0x0f,0x85,0x38},{  0x1e,0x3d,0xae,0xd5},{  0x27,0x36,0x2d,0x39}, 
-{ 0x64,0x0a,0x0f,0xd9},{  0x21,0x68,0x5c,0xa6},{  0xd1,0x9b,0x5b,0x54},{  0x3a,0x24,0x36,0x2e}, 
-{ 0xb1,0x0c,0x0a,0x67},{  0x0f,0x93,0x57,0xe7},{  0xd2,0xb4,0xee,0x96},{  0x9e,0x1b,0x9b,0x91}, 
-{ 0x4f,0x80,0xc0,0xc5},{  0xa2,0x61,0xdc,0x20},{  0x69,0x5a,0x77,0x4b},{  0x16,0x1c,0x12,0x1a}, 
-{ 0x0a,0xe2,0x93,0xba},{  0xe5,0xc0,0xa0,0x2a},{  0x43,0x3c,0x22,0xe0},{  0x1d,0x12,0x1b,0x17}, 
-{ 0x0b,0x0e,0x09,0x0d},{  0xad,0xf2,0x8b,0xc7},{  0xb9,0x2d,0xb6,0xa8},{  0xc8,0x14,0x1e,0xa9}, 
-{ 0x85,0x57,0xf1,0x19},{  0x4c,0xaf,0x75,0x07},{  0xbb,0xee,0x99,0xdd},{  0xfd,0xa3,0x7f,0x60}, 
-{ 0x9f,0xf7,0x01,0x26},{  0xbc,0x5c,0x72,0xf5},{  0xc5,0x44,0x66,0x3b},{  0x34,0x5b,0xfb,0x7e}, 
-{ 0x76,0x8b,0x43,0x29},{  0xdc,0xcb,0x23,0xc6},{  0x68,0xb6,0xed,0xfc},{  0x63,0xb8,0xe4,0xf1}, 
-{ 0xca,0xd7,0x31,0xdc},{  0x10,0x42,0x63,0x85},{  0x40,0x13,0x97,0x22},{  0x20,0x84,0xc6,0x11}, 
-{ 0x7d,0x85,0x4a,0x24},{  0xf8,0xd2,0xbb,0x3d},{  0x11,0xae,0xf9,0x32},{  0x6d,0xc7,0x29,0xa1}, 
-{ 0x4b,0x1d,0x9e,0x2f},{  0xf3,0xdc,0xb2,0x30},{  0xec,0x0d,0x86,0x52},{  0xd0,0x77,0xc1,0xe3}, 
-{ 0x6c,0x2b,0xb3,0x16},{  0x99,0xa9,0x70,0xb9},{  0xfa,0x11,0x94,0x48},{  0x22,0x47,0xe9,0x64}, 
-{ 0xc4,0xa8,0xfc,0x8c},{  0x1a,0xa0,0xf0,0x3f},{  0xd8,0x56,0x7d,0x2c},{  0xef,0x22,0x33,0x90}, 
-{ 0xc7,0x87,0x49,0x4e},{  0xc1,0xd9,0x38,0xd1},{  0xfe,0x8c,0xca,0xa2},{  0x36,0x98,0xd4,0x0b}, 
-{ 0xcf,0xa6,0xf5,0x81},{  0x28,0xa5,0x7a,0xde},{  0x26,0xda,0xb7,0x8e},{  0xa4,0x3f,0xad,0xbf}, 
-{ 0xe4,0x2c,0x3a,0x9d},{  0x0d,0x50,0x78,0x92},{  0x9b,0x6a,0x5f,0xcc},{  0x62,0x54,0x7e,0x46}, 
-{ 0xc2,0xf6,0x8d,0x13},{  0xe8,0x90,0xd8,0xb8},{  0x5e,0x2e,0x39,0xf7},{  0xf5,0x82,0xc3,0xaf}, 
-{ 0xbe,0x9f,0x5d,0x80},{  0x7c,0x69,0xd0,0x93},{  0xa9,0x6f,0xd5,0x2d},{  0xb3,0xcf,0x25,0x12}, 
-{ 0x3b,0xc8,0xac,0x99},{  0xa7,0x10,0x18,0x7d},{  0x6e,0xe8,0x9c,0x63},{  0x7b,0xdb,0x3b,0xbb}, 
-{ 0x09,0xcd,0x26,0x78},{  0xf4,0x6e,0x59,0x18},{  0x01,0xec,0x9a,0xb7},{  0xa8,0x83,0x4f,0x9a}, 
-{ 0x65,0xe6,0x95,0x6e},{  0x7e,0xaa,0xff,0xe6},{  0x08,0x21,0xbc,0xcf},{  0xe6,0xef,0x15,0xe8}, 
-{ 0xd9,0xba,0xe7,0x9b},{  0xce,0x4a,0x6f,0x36},{  0xd4,0xea,0x9f,0x09},{  0xd6,0x29,0xb0,0x7c}, 
-{ 0xaf,0x31,0xa4,0xb2},{  0x31,0x2a,0x3f,0x23},{  0x30,0xc6,0xa5,0x94},{  0xc0,0x35,0xa2,0x66}, 
-{ 0x37,0x74,0x4e,0xbc},{  0xa6,0xfc,0x82,0xca},{  0xb0,0xe0,0x90,0xd0},{  0x15,0x33,0xa7,0xd8}, 
-{ 0x4a,0xf1,0x04,0x98},{  0xf7,0x41,0xec,0xda},{  0x0e,0x7f,0xcd,0x50},{  0x2f,0x17,0x91,0xf6}, 
-{ 0x8d,0x76,0x4d,0xd6},{  0x4d,0x43,0xef,0xb0},{  0x54,0xcc,0xaa,0x4d},{  0xdf,0xe4,0x96,0x04}, 
-{ 0xe3,0x9e,0xd1,0xb5},{  0x1b,0x4c,0x6a,0x88},{  0xb8,0xc1,0x2c,0x1f},{  0x7f,0x46,0x65,0x51}, 
-{ 0x04,0x9d,0x5e,0xea},{  0x5d,0x01,0x8c,0x35},{  0x73,0xfa,0x87,0x74},{  0x2e,0xfb,0x0b,0x41}, 
-{ 0x5a,0xb3,0x67,0x1d},{  0x52,0x92,0xdb,0xd2},{  0x33,0xe9,0x10,0x56},{  0x13,0x6d,0xd6,0x47}, 
-{ 0x8c,0x9a,0xd7,0x61},{  0x7a,0x37,0xa1,0x0c},{  0x8e,0x59,0xf8,0x14},{  0x89,0xeb,0x13,0x3c}, 
-{ 0xee,0xce,0xa9,0x27},{  0x35,0xb7,0x61,0xc9},{  0xed,0xe1,0x1c,0xe5},{  0x3c,0x7a,0x47,0xb1}, 
-{ 0x59,0x9c,0xd2,0xdf},{  0x3f,0x55,0xf2,0x73},{  0x79,0x18,0x14,0xce},{  0xbf,0x73,0xc7,0x37}, 
-{ 0xea,0x53,0xf7,0xcd},{  0x5b,0x5f,0xfd,0xaa},{  0x14,0xdf,0x3d,0x6f},{  0x86,0x78,0x44,0xdb}, 
-{ 0x81,0xca,0xaf,0xf3},{  0x3e,0xb9,0x68,0xc4},{  0x2c,0x38,0x24,0x34},{  0x5f,0xc2,0xa3,0x40}, 
-{ 0x72,0x16,0x1d,0xc3},{  0x0c,0xbc,0xe2,0x25},{  0x8b,0x28,0x3c,0x49},{  0x41,0xff,0x0d,0x95}, 
-{ 0x71,0x39,0xa8,0x01},{  0xde,0x08,0x0c,0xb3},{  0x9c,0xd8,0xb4,0xe4},{  0x90,0x64,0x56,0xc1}, 
-{ 0x61,0x7b,0xcb,0x84},{  0x70,0xd5,0x32,0xb6},{  0x74,0x48,0x6c,0x5c},{  0x42,0xd0,0xb8,0x57 } 
-};
-
-word8 T7[256][4] = {
-{ 0xa7,0x50,0x51,0xf4},{  0x65,0x53,0x7e,0x41},{  0xa4,0xc3,0x1a,0x17},{  0x5e,0x96,0x3a,0x27}, 
-{ 0x6b,0xcb,0x3b,0xab},{  0x45,0xf1,0x1f,0x9d},{  0x58,0xab,0xac,0xfa},{  0x03,0x93,0x4b,0xe3}, 
-{ 0xfa,0x55,0x20,0x30},{  0x6d,0xf6,0xad,0x76},{  0x76,0x91,0x88,0xcc},{  0x4c,0x25,0xf5,0x02}, 
-{ 0xd7,0xfc,0x4f,0xe5},{  0xcb,0xd7,0xc5,0x2a},{  0x44,0x80,0x26,0x35},{  0xa3,0x8f,0xb5,0x62}, 
-{ 0x5a,0x49,0xde,0xb1},{  0x1b,0x67,0x25,0xba},{  0x0e,0x98,0x45,0xea},{  0xc0,0xe1,0x5d,0xfe}, 
-{ 0x75,0x02,0xc3,0x2f},{  0xf0,0x12,0x81,0x4c},{  0x97,0xa3,0x8d,0x46},{  0xf9,0xc6,0x6b,0xd3}, 
-{ 0x5f,0xe7,0x03,0x8f},{  0x9c,0x95,0x15,0x92},{  0x7a,0xeb,0xbf,0x6d},{  0x59,0xda,0x95,0x52}, 
-{ 0x83,0x2d,0xd4,0xbe},{  0x21,0xd3,0x58,0x74},{  0x69,0x29,0x49,0xe0},{  0xc8,0x44,0x8e,0xc9}, 
-{ 0x89,0x6a,0x75,0xc2},{  0x79,0x78,0xf4,0x8e},{  0x3e,0x6b,0x99,0x58},{  0x71,0xdd,0x27,0xb9}, 
-{ 0x4f,0xb6,0xbe,0xe1},{  0xad,0x17,0xf0,0x88},{  0xac,0x66,0xc9,0x20},{  0x3a,0xb4,0x7d,0xce}, 
-{ 0x4a,0x18,0x63,0xdf},{  0x31,0x82,0xe5,0x1a},{  0x33,0x60,0x97,0x51},{  0x7f,0x45,0x62,0x53}, 
-{ 0x77,0xe0,0xb1,0x64},{  0xae,0x84,0xbb,0x6b},{  0xa0,0x1c,0xfe,0x81},{  0x2b,0x94,0xf9,0x08}, 
-{ 0x68,0x58,0x70,0x48},{  0xfd,0x19,0x8f,0x45},{  0x6c,0x87,0x94,0xde},{  0xf8,0xb7,0x52,0x7b}, 
-{ 0xd3,0x23,0xab,0x73},{  0x02,0xe2,0x72,0x4b},{  0x8f,0x57,0xe3,0x1f},{  0xab,0x2a,0x66,0x55}, 
-{ 0x28,0x07,0xb2,0xeb},{  0xc2,0x03,0x2f,0xb5},{  0x7b,0x9a,0x86,0xc5},{  0x08,0xa5,0xd3,0x37}, 
-{ 0x87,0xf2,0x30,0x28},{  0xa5,0xb2,0x23,0xbf},{  0x6a,0xba,0x02,0x03},{  0x82,0x5c,0xed,0x16}, 
-{ 0x1c,0x2b,0x8a,0xcf},{  0xb4,0x92,0xa7,0x79},{  0xf2,0xf0,0xf3,0x07},{  0xe2,0xa1,0x4e,0x69}, 
-{ 0xf4,0xcd,0x65,0xda},{  0xbe,0xd5,0x06,0x05},{  0x62,0x1f,0xd1,0x34},{  0xfe,0x8a,0xc4,0xa6}, 
-{ 0x53,0x9d,0x34,0x2e},{  0x55,0xa0,0xa2,0xf3},{  0xe1,0x32,0x05,0x8a},{  0xeb,0x75,0xa4,0xf6}, 
-{ 0xec,0x39,0x0b,0x83},{  0xef,0xaa,0x40,0x60},{  0x9f,0x06,0x5e,0x71},{  0x10,0x51,0xbd,0x6e}, 
-{ 0x8a,0xf9,0x3e,0x21},{  0x06,0x3d,0x96,0xdd},{  0x05,0xae,0xdd,0x3e},{  0xbd,0x46,0x4d,0xe6}, 
-{ 0x8d,0xb5,0x91,0x54},{  0x5d,0x05,0x71,0xc4},{  0xd4,0x6f,0x04,0x06},{  0x15,0xff,0x60,0x50}, 
-{ 0xfb,0x24,0x19,0x98},{  0xe9,0x97,0xd6,0xbd},{  0x43,0xcc,0x89,0x40},{  0x9e,0x77,0x67,0xd9}, 
-{ 0x42,0xbd,0xb0,0xe8},{  0x8b,0x88,0x07,0x89},{  0x5b,0x38,0xe7,0x19},{  0xee,0xdb,0x79,0xc8}, 
-{ 0x0a,0x47,0xa1,0x7c},{  0x0f,0xe9,0x7c,0x42},{  0x1e,0xc9,0xf8,0x84},{  0x00,0x00,0x00,0x00}, 
-{ 0x86,0x83,0x09,0x80},{  0xed,0x48,0x32,0x2b},{  0x70,0xac,0x1e,0x11},{  0x72,0x4e,0x6c,0x5a}, 
-{ 0xff,0xfb,0xfd,0x0e},{  0x38,0x56,0x0f,0x85},{  0xd5,0x1e,0x3d,0xae},{  0x39,0x27,0x36,0x2d}, 
-{ 0xd9,0x64,0x0a,0x0f},{  0xa6,0x21,0x68,0x5c},{  0x54,0xd1,0x9b,0x5b},{  0x2e,0x3a,0x24,0x36}, 
-{ 0x67,0xb1,0x0c,0x0a},{  0xe7,0x0f,0x93,0x57},{  0x96,0xd2,0xb4,0xee},{  0x91,0x9e,0x1b,0x9b}, 
-{ 0xc5,0x4f,0x80,0xc0},{  0x20,0xa2,0x61,0xdc},{  0x4b,0x69,0x5a,0x77},{  0x1a,0x16,0x1c,0x12}, 
-{ 0xba,0x0a,0xe2,0x93},{  0x2a,0xe5,0xc0,0xa0},{  0xe0,0x43,0x3c,0x22},{  0x17,0x1d,0x12,0x1b}, 
-{ 0x0d,0x0b,0x0e,0x09},{  0xc7,0xad,0xf2,0x8b},{  0xa8,0xb9,0x2d,0xb6},{  0xa9,0xc8,0x14,0x1e}, 
-{ 0x19,0x85,0x57,0xf1},{  0x07,0x4c,0xaf,0x75},{  0xdd,0xbb,0xee,0x99},{  0x60,0xfd,0xa3,0x7f}, 
-{ 0x26,0x9f,0xf7,0x01},{  0xf5,0xbc,0x5c,0x72},{  0x3b,0xc5,0x44,0x66},{  0x7e,0x34,0x5b,0xfb}, 
-{ 0x29,0x76,0x8b,0x43},{  0xc6,0xdc,0xcb,0x23},{  0xfc,0x68,0xb6,0xed},{  0xf1,0x63,0xb8,0xe4}, 
-{ 0xdc,0xca,0xd7,0x31},{  0x85,0x10,0x42,0x63},{  0x22,0x40,0x13,0x97},{  0x11,0x20,0x84,0xc6}, 
-{ 0x24,0x7d,0x85,0x4a},{  0x3d,0xf8,0xd2,0xbb},{  0x32,0x11,0xae,0xf9},{  0xa1,0x6d,0xc7,0x29}, 
-{ 0x2f,0x4b,0x1d,0x9e},{  0x30,0xf3,0xdc,0xb2},{  0x52,0xec,0x0d,0x86},{  0xe3,0xd0,0x77,0xc1}, 
-{ 0x16,0x6c,0x2b,0xb3},{  0xb9,0x99,0xa9,0x70},{  0x48,0xfa,0x11,0x94},{  0x64,0x22,0x47,0xe9}, 
-{ 0x8c,0xc4,0xa8,0xfc},{  0x3f,0x1a,0xa0,0xf0},{  0x2c,0xd8,0x56,0x7d},{  0x90,0xef,0x22,0x33}, 
-{ 0x4e,0xc7,0x87,0x49},{  0xd1,0xc1,0xd9,0x38},{  0xa2,0xfe,0x8c,0xca},{  0x0b,0x36,0x98,0xd4}, 
-{ 0x81,0xcf,0xa6,0xf5},{  0xde,0x28,0xa5,0x7a},{  0x8e,0x26,0xda,0xb7},{  0xbf,0xa4,0x3f,0xad}, 
-{ 0x9d,0xe4,0x2c,0x3a},{  0x92,0x0d,0x50,0x78},{  0xcc,0x9b,0x6a,0x5f},{  0x46,0x62,0x54,0x7e}, 
-{ 0x13,0xc2,0xf6,0x8d},{  0xb8,0xe8,0x90,0xd8},{  0xf7,0x5e,0x2e,0x39},{  0xaf,0xf5,0x82,0xc3}, 
-{ 0x80,0xbe,0x9f,0x5d},{  0x93,0x7c,0x69,0xd0},{  0x2d,0xa9,0x6f,0xd5},{  0x12,0xb3,0xcf,0x25}, 
-{ 0x99,0x3b,0xc8,0xac},{  0x7d,0xa7,0x10,0x18},{  0x63,0x6e,0xe8,0x9c},{  0xbb,0x7b,0xdb,0x3b}, 
-{ 0x78,0x09,0xcd,0x26},{  0x18,0xf4,0x6e,0x59},{  0xb7,0x01,0xec,0x9a},{  0x9a,0xa8,0x83,0x4f}, 
-{ 0x6e,0x65,0xe6,0x95},{  0xe6,0x7e,0xaa,0xff},{  0xcf,0x08,0x21,0xbc},{  0xe8,0xe6,0xef,0x15}, 
-{ 0x9b,0xd9,0xba,0xe7},{  0x36,0xce,0x4a,0x6f},{  0x09,0xd4,0xea,0x9f},{  0x7c,0xd6,0x29,0xb0}, 
-{ 0xb2,0xaf,0x31,0xa4},{  0x23,0x31,0x2a,0x3f},{  0x94,0x30,0xc6,0xa5},{  0x66,0xc0,0x35,0xa2}, 
-{ 0xbc,0x37,0x74,0x4e},{  0xca,0xa6,0xfc,0x82},{  0xd0,0xb0,0xe0,0x90},{  0xd8,0x15,0x33,0xa7}, 
-{ 0x98,0x4a,0xf1,0x04},{  0xda,0xf7,0x41,0xec},{  0x50,0x0e,0x7f,0xcd},{  0xf6,0x2f,0x17,0x91}, 
-{ 0xd6,0x8d,0x76,0x4d},{  0xb0,0x4d,0x43,0xef},{  0x4d,0x54,0xcc,0xaa},{  0x04,0xdf,0xe4,0x96}, 
-{ 0xb5,0xe3,0x9e,0xd1},{  0x88,0x1b,0x4c,0x6a},{  0x1f,0xb8,0xc1,0x2c},{  0x51,0x7f,0x46,0x65}, 
-{ 0xea,0x04,0x9d,0x5e},{  0x35,0x5d,0x01,0x8c},{  0x74,0x73,0xfa,0x87},{  0x41,0x2e,0xfb,0x0b}, 
-{ 0x1d,0x5a,0xb3,0x67},{  0xd2,0x52,0x92,0xdb},{  0x56,0x33,0xe9,0x10},{  0x47,0x13,0x6d,0xd6}, 
-{ 0x61,0x8c,0x9a,0xd7},{  0x0c,0x7a,0x37,0xa1},{  0x14,0x8e,0x59,0xf8},{  0x3c,0x89,0xeb,0x13}, 
-{ 0x27,0xee,0xce,0xa9},{  0xc9,0x35,0xb7,0x61},{  0xe5,0xed,0xe1,0x1c},{  0xb1,0x3c,0x7a,0x47}, 
-{ 0xdf,0x59,0x9c,0xd2},{  0x73,0x3f,0x55,0xf2},{  0xce,0x79,0x18,0x14},{  0x37,0xbf,0x73,0xc7}, 
-{ 0xcd,0xea,0x53,0xf7},{  0xaa,0x5b,0x5f,0xfd},{  0x6f,0x14,0xdf,0x3d},{  0xdb,0x86,0x78,0x44}, 
-{ 0xf3,0x81,0xca,0xaf},{  0xc4,0x3e,0xb9,0x68},{  0x34,0x2c,0x38,0x24},{  0x40,0x5f,0xc2,0xa3}, 
-{ 0xc3,0x72,0x16,0x1d},{  0x25,0x0c,0xbc,0xe2},{  0x49,0x8b,0x28,0x3c},{  0x95,0x41,0xff,0x0d}, 
-{ 0x01,0x71,0x39,0xa8},{  0xb3,0xde,0x08,0x0c},{  0xe4,0x9c,0xd8,0xb4},{  0xc1,0x90,0x64,0x56}, 
-{ 0x84,0x61,0x7b,0xcb},{  0xb6,0x70,0xd5,0x32},{  0x5c,0x74,0x48,0x6c},{  0x57,0x42,0xd0,0xb8 } 
-};
-
-word8 T8[256][4] = {
-{ 0xf4,0xa7,0x50,0x51},{  0x41,0x65,0x53,0x7e},{  0x17,0xa4,0xc3,0x1a},{  0x27,0x5e,0x96,0x3a}, 
-{ 0xab,0x6b,0xcb,0x3b},{  0x9d,0x45,0xf1,0x1f},{  0xfa,0x58,0xab,0xac},{  0xe3,0x03,0x93,0x4b}, 
-{ 0x30,0xfa,0x55,0x20},{  0x76,0x6d,0xf6,0xad},{  0xcc,0x76,0x91,0x88},{  0x02,0x4c,0x25,0xf5}, 
-{ 0xe5,0xd7,0xfc,0x4f},{  0x2a,0xcb,0xd7,0xc5},{  0x35,0x44,0x80,0x26},{  0x62,0xa3,0x8f,0xb5}, 
-{ 0xb1,0x5a,0x49,0xde},{  0xba,0x1b,0x67,0x25},{  0xea,0x0e,0x98,0x45},{  0xfe,0xc0,0xe1,0x5d}, 
-{ 0x2f,0x75,0x02,0xc3},{  0x4c,0xf0,0x12,0x81},{  0x46,0x97,0xa3,0x8d},{  0xd3,0xf9,0xc6,0x6b}, 
-{ 0x8f,0x5f,0xe7,0x03},{  0x92,0x9c,0x95,0x15},{  0x6d,0x7a,0xeb,0xbf},{  0x52,0x59,0xda,0x95}, 
-{ 0xbe,0x83,0x2d,0xd4},{  0x74,0x21,0xd3,0x58},{  0xe0,0x69,0x29,0x49},{  0xc9,0xc8,0x44,0x8e}, 
-{ 0xc2,0x89,0x6a,0x75},{  0x8e,0x79,0x78,0xf4},{  0x58,0x3e,0x6b,0x99},{  0xb9,0x71,0xdd,0x27}, 
-{ 0xe1,0x4f,0xb6,0xbe},{  0x88,0xad,0x17,0xf0},{  0x20,0xac,0x66,0xc9},{  0xce,0x3a,0xb4,0x7d}, 
-{ 0xdf,0x4a,0x18,0x63},{  0x1a,0x31,0x82,0xe5},{  0x51,0x33,0x60,0x97},{  0x53,0x7f,0x45,0x62}, 
-{ 0x64,0x77,0xe0,0xb1},{  0x6b,0xae,0x84,0xbb},{  0x81,0xa0,0x1c,0xfe},{  0x08,0x2b,0x94,0xf9}, 
-{ 0x48,0x68,0x58,0x70},{  0x45,0xfd,0x19,0x8f},{  0xde,0x6c,0x87,0x94},{  0x7b,0xf8,0xb7,0x52}, 
-{ 0x73,0xd3,0x23,0xab},{  0x4b,0x02,0xe2,0x72},{  0x1f,0x8f,0x57,0xe3},{  0x55,0xab,0x2a,0x66}, 
-{ 0xeb,0x28,0x07,0xb2},{  0xb5,0xc2,0x03,0x2f},{  0xc5,0x7b,0x9a,0x86},{  0x37,0x08,0xa5,0xd3}, 
-{ 0x28,0x87,0xf2,0x30},{  0xbf,0xa5,0xb2,0x23},{  0x03,0x6a,0xba,0x02},{  0x16,0x82,0x5c,0xed}, 
-{ 0xcf,0x1c,0x2b,0x8a},{  0x79,0xb4,0x92,0xa7},{  0x07,0xf2,0xf0,0xf3},{  0x69,0xe2,0xa1,0x4e}, 
-{ 0xda,0xf4,0xcd,0x65},{  0x05,0xbe,0xd5,0x06},{  0x34,0x62,0x1f,0xd1},{  0xa6,0xfe,0x8a,0xc4}, 
-{ 0x2e,0x53,0x9d,0x34},{  0xf3,0x55,0xa0,0xa2},{  0x8a,0xe1,0x32,0x05},{  0xf6,0xeb,0x75,0xa4}, 
-{ 0x83,0xec,0x39,0x0b},{  0x60,0xef,0xaa,0x40},{  0x71,0x9f,0x06,0x5e},{  0x6e,0x10,0x51,0xbd}, 
-{ 0x21,0x8a,0xf9,0x3e},{  0xdd,0x06,0x3d,0x96},{  0x3e,0x05,0xae,0xdd},{  0xe6,0xbd,0x46,0x4d}, 
-{ 0x54,0x8d,0xb5,0x91},{  0xc4,0x5d,0x05,0x71},{  0x06,0xd4,0x6f,0x04},{  0x50,0x15,0xff,0x60}, 
-{ 0x98,0xfb,0x24,0x19},{  0xbd,0xe9,0x97,0xd6},{  0x40,0x43,0xcc,0x89},{  0xd9,0x9e,0x77,0x67}, 
-{ 0xe8,0x42,0xbd,0xb0},{  0x89,0x8b,0x88,0x07},{  0x19,0x5b,0x38,0xe7},{  0xc8,0xee,0xdb,0x79}, 
-{ 0x7c,0x0a,0x47,0xa1},{  0x42,0x0f,0xe9,0x7c},{  0x84,0x1e,0xc9,0xf8},{  0x00,0x00,0x00,0x00}, 
-{ 0x80,0x86,0x83,0x09},{  0x2b,0xed,0x48,0x32},{  0x11,0x70,0xac,0x1e},{  0x5a,0x72,0x4e,0x6c}, 
-{ 0x0e,0xff,0xfb,0xfd},{  0x85,0x38,0x56,0x0f},{  0xae,0xd5,0x1e,0x3d},{  0x2d,0x39,0x27,0x36}, 
-{ 0x0f,0xd9,0x64,0x0a},{  0x5c,0xa6,0x21,0x68},{  0x5b,0x54,0xd1,0x9b},{  0x36,0x2e,0x3a,0x24}, 
-{ 0x0a,0x67,0xb1,0x0c},{  0x57,0xe7,0x0f,0x93},{  0xee,0x96,0xd2,0xb4},{  0x9b,0x91,0x9e,0x1b}, 
-{ 0xc0,0xc5,0x4f,0x80},{  0xdc,0x20,0xa2,0x61},{  0x77,0x4b,0x69,0x5a},{  0x12,0x1a,0x16,0x1c}, 
-{ 0x93,0xba,0x0a,0xe2},{  0xa0,0x2a,0xe5,0xc0},{  0x22,0xe0,0x43,0x3c},{  0x1b,0x17,0x1d,0x12}, 
-{ 0x09,0x0d,0x0b,0x0e},{  0x8b,0xc7,0xad,0xf2},{  0xb6,0xa8,0xb9,0x2d},{  0x1e,0xa9,0xc8,0x14}, 
-{ 0xf1,0x19,0x85,0x57},{  0x75,0x07,0x4c,0xaf},{  0x99,0xdd,0xbb,0xee},{  0x7f,0x60,0xfd,0xa3}, 
-{ 0x01,0x26,0x9f,0xf7},{  0x72,0xf5,0xbc,0x5c},{  0x66,0x3b,0xc5,0x44},{  0xfb,0x7e,0x34,0x5b}, 
-{ 0x43,0x29,0x76,0x8b},{  0x23,0xc6,0xdc,0xcb},{  0xed,0xfc,0x68,0xb6},{  0xe4,0xf1,0x63,0xb8}, 
-{ 0x31,0xdc,0xca,0xd7},{  0x63,0x85,0x10,0x42},{  0x97,0x22,0x40,0x13},{  0xc6,0x11,0x20,0x84}, 
-{ 0x4a,0x24,0x7d,0x85},{  0xbb,0x3d,0xf8,0xd2},{  0xf9,0x32,0x11,0xae},{  0x29,0xa1,0x6d,0xc7}, 
-{ 0x9e,0x2f,0x4b,0x1d},{  0xb2,0x30,0xf3,0xdc},{  0x86,0x52,0xec,0x0d},{  0xc1,0xe3,0xd0,0x77}, 
-{ 0xb3,0x16,0x6c,0x2b},{  0x70,0xb9,0x99,0xa9},{  0x94,0x48,0xfa,0x11},{  0xe9,0x64,0x22,0x47}, 
-{ 0xfc,0x8c,0xc4,0xa8},{  0xf0,0x3f,0x1a,0xa0},{  0x7d,0x2c,0xd8,0x56},{  0x33,0x90,0xef,0x22}, 
-{ 0x49,0x4e,0xc7,0x87},{  0x38,0xd1,0xc1,0xd9},{  0xca,0xa2,0xfe,0x8c},{  0xd4,0x0b,0x36,0x98}, 
-{ 0xf5,0x81,0xcf,0xa6},{  0x7a,0xde,0x28,0xa5},{  0xb7,0x8e,0x26,0xda},{  0xad,0xbf,0xa4,0x3f}, 
-{ 0x3a,0x9d,0xe4,0x2c},{  0x78,0x92,0x0d,0x50},{  0x5f,0xcc,0x9b,0x6a},{  0x7e,0x46,0x62,0x54}, 
-{ 0x8d,0x13,0xc2,0xf6},{  0xd8,0xb8,0xe8,0x90},{  0x39,0xf7,0x5e,0x2e},{  0xc3,0xaf,0xf5,0x82}, 
-{ 0x5d,0x80,0xbe,0x9f},{  0xd0,0x93,0x7c,0x69},{  0xd5,0x2d,0xa9,0x6f},{  0x25,0x12,0xb3,0xcf}, 
-{ 0xac,0x99,0x3b,0xc8},{  0x18,0x7d,0xa7,0x10},{  0x9c,0x63,0x6e,0xe8},{  0x3b,0xbb,0x7b,0xdb}, 
-{ 0x26,0x78,0x09,0xcd},{  0x59,0x18,0xf4,0x6e},{  0x9a,0xb7,0x01,0xec},{  0x4f,0x9a,0xa8,0x83}, 
-{ 0x95,0x6e,0x65,0xe6},{  0xff,0xe6,0x7e,0xaa},{  0xbc,0xcf,0x08,0x21},{  0x15,0xe8,0xe6,0xef}, 
-{ 0xe7,0x9b,0xd9,0xba},{  0x6f,0x36,0xce,0x4a},{  0x9f,0x09,0xd4,0xea},{  0xb0,0x7c,0xd6,0x29}, 
-{ 0xa4,0xb2,0xaf,0x31},{  0x3f,0x23,0x31,0x2a},{  0xa5,0x94,0x30,0xc6},{  0xa2,0x66,0xc0,0x35}, 
-{ 0x4e,0xbc,0x37,0x74},{  0x82,0xca,0xa6,0xfc},{  0x90,0xd0,0xb0,0xe0},{  0xa7,0xd8,0x15,0x33}, 
-{ 0x04,0x98,0x4a,0xf1},{  0xec,0xda,0xf7,0x41},{  0xcd,0x50,0x0e,0x7f},{  0x91,0xf6,0x2f,0x17}, 
-{ 0x4d,0xd6,0x8d,0x76},{  0xef,0xb0,0x4d,0x43},{  0xaa,0x4d,0x54,0xcc},{  0x96,0x04,0xdf,0xe4}, 
-{ 0xd1,0xb5,0xe3,0x9e},{  0x6a,0x88,0x1b,0x4c},{  0x2c,0x1f,0xb8,0xc1},{  0x65,0x51,0x7f,0x46}, 
-{ 0x5e,0xea,0x04,0x9d},{  0x8c,0x35,0x5d,0x01},{  0x87,0x74,0x73,0xfa},{  0x0b,0x41,0x2e,0xfb}, 
-{ 0x67,0x1d,0x5a,0xb3},{  0xdb,0xd2,0x52,0x92},{  0x10,0x56,0x33,0xe9},{  0xd6,0x47,0x13,0x6d}, 
-{ 0xd7,0x61,0x8c,0x9a},{  0xa1,0x0c,0x7a,0x37},{  0xf8,0x14,0x8e,0x59},{  0x13,0x3c,0x89,0xeb}, 
-{ 0xa9,0x27,0xee,0xce},{  0x61,0xc9,0x35,0xb7},{  0x1c,0xe5,0xed,0xe1},{  0x47,0xb1,0x3c,0x7a}, 
-{ 0xd2,0xdf,0x59,0x9c},{  0xf2,0x73,0x3f,0x55},{  0x14,0xce,0x79,0x18},{  0xc7,0x37,0xbf,0x73}, 
-{ 0xf7,0xcd,0xea,0x53},{  0xfd,0xaa,0x5b,0x5f},{  0x3d,0x6f,0x14,0xdf},{  0x44,0xdb,0x86,0x78}, 
-{ 0xaf,0xf3,0x81,0xca},{  0x68,0xc4,0x3e,0xb9},{  0x24,0x34,0x2c,0x38},{  0xa3,0x40,0x5f,0xc2}, 
-{ 0x1d,0xc3,0x72,0x16},{  0xe2,0x25,0x0c,0xbc},{  0x3c,0x49,0x8b,0x28},{  0x0d,0x95,0x41,0xff}, 
-{ 0xa8,0x01,0x71,0x39},{  0x0c,0xb3,0xde,0x08},{  0xb4,0xe4,0x9c,0xd8},{  0x56,0xc1,0x90,0x64}, 
-{ 0xcb,0x84,0x61,0x7b},{  0x32,0xb6,0x70,0xd5},{  0x6c,0x5c,0x74,0x48},{  0xb8,0x57,0x42,0xd0 } 
-};
-
-word8 S5[256] = {
-0x52,0x09,0x6a,0xd5,
-0x30,0x36,0xa5,0x38,
-0xbf,0x40,0xa3,0x9e,
-0x81,0xf3,0xd7,0xfb,
-0x7c,0xe3,0x39,0x82,
-0x9b,0x2f,0xff,0x87,
-0x34,0x8e,0x43,0x44,
-0xc4,0xde,0xe9,0xcb,
-0x54,0x7b,0x94,0x32,
-0xa6,0xc2,0x23,0x3d,
-0xee,0x4c,0x95,0x0b,
-0x42,0xfa,0xc3,0x4e,
-0x08,0x2e,0xa1,0x66,
-0x28,0xd9,0x24,0xb2,
-0x76,0x5b,0xa2,0x49,
-0x6d,0x8b,0xd1,0x25,
-0x72,0xf8,0xf6,0x64,
-0x86,0x68,0x98,0x16,
-0xd4,0xa4,0x5c,0xcc,
-0x5d,0x65,0xb6,0x92,
-0x6c,0x70,0x48,0x50,
-0xfd,0xed,0xb9,0xda,
-0x5e,0x15,0x46,0x57,
-0xa7,0x8d,0x9d,0x84,
-0x90,0xd8,0xab,0x00,
-0x8c,0xbc,0xd3,0x0a,
-0xf7,0xe4,0x58,0x05,
-0xb8,0xb3,0x45,0x06,
-0xd0,0x2c,0x1e,0x8f,
-0xca,0x3f,0x0f,0x02,
-0xc1,0xaf,0xbd,0x03,
-0x01,0x13,0x8a,0x6b,
-0x3a,0x91,0x11,0x41,
-0x4f,0x67,0xdc,0xea,
-0x97,0xf2,0xcf,0xce,
-0xf0,0xb4,0xe6,0x73,
-0x96,0xac,0x74,0x22,
-0xe7,0xad,0x35,0x85,
-0xe2,0xf9,0x37,0xe8,
-0x1c,0x75,0xdf,0x6e,
-0x47,0xf1,0x1a,0x71,
-0x1d,0x29,0xc5,0x89,
-0x6f,0xb7,0x62,0x0e,
-0xaa,0x18,0xbe,0x1b,
-0xfc,0x56,0x3e,0x4b,
-0xc6,0xd2,0x79,0x20,
-0x9a,0xdb,0xc0,0xfe,
-0x78,0xcd,0x5a,0xf4,
-0x1f,0xdd,0xa8,0x33,
-0x88,0x07,0xc7,0x31,
-0xb1,0x12,0x10,0x59,
-0x27,0x80,0xec,0x5f,
-0x60,0x51,0x7f,0xa9,
-0x19,0xb5,0x4a,0x0d,
-0x2d,0xe5,0x7a,0x9f,
-0x93,0xc9,0x9c,0xef,
-0xa0,0xe0,0x3b,0x4d,
-0xae,0x2a,0xf5,0xb0,
-0xc8,0xeb,0xbb,0x3c,
-0x83,0x53,0x99,0x61,
-0x17,0x2b,0x04,0x7e,
-0xba,0x77,0xd6,0x26,
-0xe1,0x69,0x14,0x63,
-0x55,0x21,0x0c,0x7d
-};
-
-word8 U1[256][4] = {
-{ 0x00,0x00,0x00,0x00},{  0x0e,0x09,0x0d,0x0b},{  0x1c,0x12,0x1a,0x16},{  0x12,0x1b,0x17,0x1d}, 
-{ 0x38,0x24,0x34,0x2c},{  0x36,0x2d,0x39,0x27},{  0x24,0x36,0x2e,0x3a},{  0x2a,0x3f,0x23,0x31}, 
-{ 0x70,0x48,0x68,0x58},{  0x7e,0x41,0x65,0x53},{  0x6c,0x5a,0x72,0x4e},{  0x62,0x53,0x7f,0x45}, 
-{ 0x48,0x6c,0x5c,0x74},{  0x46,0x65,0x51,0x7f},{  0x54,0x7e,0x46,0x62},{  0x5a,0x77,0x4b,0x69}, 
-{ 0xe0,0x90,0xd0,0xb0},{  0xee,0x99,0xdd,0xbb},{  0xfc,0x82,0xca,0xa6},{  0xf2,0x8b,0xc7,0xad}, 
-{ 0xd8,0xb4,0xe4,0x9c},{  0xd6,0xbd,0xe9,0x97},{  0xc4,0xa6,0xfe,0x8a},{  0xca,0xaf,0xf3,0x81}, 
-{ 0x90,0xd8,0xb8,0xe8},{  0x9e,0xd1,0xb5,0xe3},{  0x8c,0xca,0xa2,0xfe},{  0x82,0xc3,0xaf,0xf5}, 
-{ 0xa8,0xfc,0x8c,0xc4},{  0xa6,0xf5,0x81,0xcf},{  0xb4,0xee,0x96,0xd2},{  0xba,0xe7,0x9b,0xd9}, 
-{ 0xdb,0x3b,0xbb,0x7b},{  0xd5,0x32,0xb6,0x70},{  0xc7,0x29,0xa1,0x6d},{  0xc9,0x20,0xac,0x66}, 
-{ 0xe3,0x1f,0x8f,0x57},{  0xed,0x16,0x82,0x5c},{  0xff,0x0d,0x95,0x41},{  0xf1,0x04,0x98,0x4a}, 
-{ 0xab,0x73,0xd3,0x23},{  0xa5,0x7a,0xde,0x28},{  0xb7,0x61,0xc9,0x35},{  0xb9,0x68,0xc4,0x3e}, 
-{ 0x93,0x57,0xe7,0x0f},{  0x9d,0x5e,0xea,0x04},{  0x8f,0x45,0xfd,0x19},{  0x81,0x4c,0xf0,0x12}, 
-{ 0x3b,0xab,0x6b,0xcb},{  0x35,0xa2,0x66,0xc0},{  0x27,0xb9,0x71,0xdd},{  0x29,0xb0,0x7c,0xd6}, 
-{ 0x03,0x8f,0x5f,0xe7},{  0x0d,0x86,0x52,0xec},{  0x1f,0x9d,0x45,0xf1},{  0x11,0x94,0x48,0xfa}, 
-{ 0x4b,0xe3,0x03,0x93},{  0x45,0xea,0x0e,0x98},{  0x57,0xf1,0x19,0x85},{  0x59,0xf8,0x14,0x8e}, 
-{ 0x73,0xc7,0x37,0xbf},{  0x7d,0xce,0x3a,0xb4},{  0x6f,0xd5,0x2d,0xa9},{  0x61,0xdc,0x20,0xa2}, 
-{ 0xad,0x76,0x6d,0xf6},{  0xa3,0x7f,0x60,0xfd},{  0xb1,0x64,0x77,0xe0},{  0xbf,0x6d,0x7a,0xeb}, 
-{ 0x95,0x52,0x59,0xda},{  0x9b,0x5b,0x54,0xd1},{  0x89,0x40,0x43,0xcc},{  0x87,0x49,0x4e,0xc7}, 
-{ 0xdd,0x3e,0x05,0xae},{  0xd3,0x37,0x08,0xa5},{  0xc1,0x2c,0x1f,0xb8},{  0xcf,0x25,0x12,0xb3}, 
-{ 0xe5,0x1a,0x31,0x82},{  0xeb,0x13,0x3c,0x89},{  0xf9,0x08,0x2b,0x94},{  0xf7,0x01,0x26,0x9f}, 
-{ 0x4d,0xe6,0xbd,0x46},{  0x43,0xef,0xb0,0x4d},{  0x51,0xf4,0xa7,0x50},{  0x5f,0xfd,0xaa,0x5b}, 
-{ 0x75,0xc2,0x89,0x6a},{  0x7b,0xcb,0x84,0x61},{  0x69,0xd0,0x93,0x7c},{  0x67,0xd9,0x9e,0x77}, 
-{ 0x3d,0xae,0xd5,0x1e},{  0x33,0xa7,0xd8,0x15},{  0x21,0xbc,0xcf,0x08},{  0x2f,0xb5,0xc2,0x03}, 
-{ 0x05,0x8a,0xe1,0x32},{  0x0b,0x83,0xec,0x39},{  0x19,0x98,0xfb,0x24},{  0x17,0x91,0xf6,0x2f}, 
-{ 0x76,0x4d,0xd6,0x8d},{  0x78,0x44,0xdb,0x86},{  0x6a,0x5f,0xcc,0x9b},{  0x64,0x56,0xc1,0x90}, 
-{ 0x4e,0x69,0xe2,0xa1},{  0x40,0x60,0xef,0xaa},{  0x52,0x7b,0xf8,0xb7},{  0x5c,0x72,0xf5,0xbc}, 
-{ 0x06,0x05,0xbe,0xd5},{  0x08,0x0c,0xb3,0xde},{  0x1a,0x17,0xa4,0xc3},{  0x14,0x1e,0xa9,0xc8}, 
-{ 0x3e,0x21,0x8a,0xf9},{  0x30,0x28,0x87,0xf2},{  0x22,0x33,0x90,0xef},{  0x2c,0x3a,0x9d,0xe4}, 
-{ 0x96,0xdd,0x06,0x3d},{  0x98,0xd4,0x0b,0x36},{  0x8a,0xcf,0x1c,0x2b},{  0x84,0xc6,0x11,0x20}, 
-{ 0xae,0xf9,0x32,0x11},{  0xa0,0xf0,0x3f,0x1a},{  0xb2,0xeb,0x28,0x07},{  0xbc,0xe2,0x25,0x0c}, 
-{ 0xe6,0x95,0x6e,0x65},{  0xe8,0x9c,0x63,0x6e},{  0xfa,0x87,0x74,0x73},{  0xf4,0x8e,0x79,0x78}, 
-{ 0xde,0xb1,0x5a,0x49},{  0xd0,0xb8,0x57,0x42},{  0xc2,0xa3,0x40,0x5f},{  0xcc,0xaa,0x4d,0x54}, 
-{ 0x41,0xec,0xda,0xf7},{  0x4f,0xe5,0xd7,0xfc},{  0x5d,0xfe,0xc0,0xe1},{  0x53,0xf7,0xcd,0xea}, 
-{ 0x79,0xc8,0xee,0xdb},{  0x77,0xc1,0xe3,0xd0},{  0x65,0xda,0xf4,0xcd},{  0x6b,0xd3,0xf9,0xc6}, 
-{ 0x31,0xa4,0xb2,0xaf},{  0x3f,0xad,0xbf,0xa4},{  0x2d,0xb6,0xa8,0xb9},{  0x23,0xbf,0xa5,0xb2}, 
-{ 0x09,0x80,0x86,0x83},{  0x07,0x89,0x8b,0x88},{  0x15,0x92,0x9c,0x95},{  0x1b,0x9b,0x91,0x9e}, 
-{ 0xa1,0x7c,0x0a,0x47},{  0xaf,0x75,0x07,0x4c},{  0xbd,0x6e,0x10,0x51},{  0xb3,0x67,0x1d,0x5a}, 
-{ 0x99,0x58,0x3e,0x6b},{  0x97,0x51,0x33,0x60},{  0x85,0x4a,0x24,0x7d},{  0x8b,0x43,0x29,0x76}, 
-{ 0xd1,0x34,0x62,0x1f},{  0xdf,0x3d,0x6f,0x14},{  0xcd,0x26,0x78,0x09},{  0xc3,0x2f,0x75,0x02}, 
-{ 0xe9,0x10,0x56,0x33},{  0xe7,0x19,0x5b,0x38},{  0xf5,0x02,0x4c,0x25},{  0xfb,0x0b,0x41,0x2e}, 
-{ 0x9a,0xd7,0x61,0x8c},{  0x94,0xde,0x6c,0x87},{  0x86,0xc5,0x7b,0x9a},{  0x88,0xcc,0x76,0x91}, 
-{ 0xa2,0xf3,0x55,0xa0},{  0xac,0xfa,0x58,0xab},{  0xbe,0xe1,0x4f,0xb6},{  0xb0,0xe8,0x42,0xbd}, 
-{ 0xea,0x9f,0x09,0xd4},{  0xe4,0x96,0x04,0xdf},{  0xf6,0x8d,0x13,0xc2},{  0xf8,0x84,0x1e,0xc9}, 
-{ 0xd2,0xbb,0x3d,0xf8},{  0xdc,0xb2,0x30,0xf3},{  0xce,0xa9,0x27,0xee},{  0xc0,0xa0,0x2a,0xe5}, 
-{ 0x7a,0x47,0xb1,0x3c},{  0x74,0x4e,0xbc,0x37},{  0x66,0x55,0xab,0x2a},{  0x68,0x5c,0xa6,0x21}, 
-{ 0x42,0x63,0x85,0x10},{  0x4c,0x6a,0x88,0x1b},{  0x5e,0x71,0x9f,0x06},{  0x50,0x78,0x92,0x0d}, 
-{ 0x0a,0x0f,0xd9,0x64},{  0x04,0x06,0xd4,0x6f},{  0x16,0x1d,0xc3,0x72},{  0x18,0x14,0xce,0x79}, 
-{ 0x32,0x2b,0xed,0x48},{  0x3c,0x22,0xe0,0x43},{  0x2e,0x39,0xf7,0x5e},{  0x20,0x30,0xfa,0x55}, 
-{ 0xec,0x9a,0xb7,0x01},{  0xe2,0x93,0xba,0x0a},{  0xf0,0x88,0xad,0x17},{  0xfe,0x81,0xa0,0x1c}, 
-{ 0xd4,0xbe,0x83,0x2d},{  0xda,0xb7,0x8e,0x26},{  0xc8,0xac,0x99,0x3b},{  0xc6,0xa5,0x94,0x30}, 
-{ 0x9c,0xd2,0xdf,0x59},{  0x92,0xdb,0xd2,0x52},{  0x80,0xc0,0xc5,0x4f},{  0x8e,0xc9,0xc8,0x44}, 
-{ 0xa4,0xf6,0xeb,0x75},{  0xaa,0xff,0xe6,0x7e},{  0xb8,0xe4,0xf1,0x63},{  0xb6,0xed,0xfc,0x68}, 
-{ 0x0c,0x0a,0x67,0xb1},{  0x02,0x03,0x6a,0xba},{  0x10,0x18,0x7d,0xa7},{  0x1e,0x11,0x70,0xac}, 
-{ 0x34,0x2e,0x53,0x9d},{  0x3a,0x27,0x5e,0x96},{  0x28,0x3c,0x49,0x8b},{  0x26,0x35,0x44,0x80}, 
-{ 0x7c,0x42,0x0f,0xe9},{  0x72,0x4b,0x02,0xe2},{  0x60,0x50,0x15,0xff},{  0x6e,0x59,0x18,0xf4}, 
-{ 0x44,0x66,0x3b,0xc5},{  0x4a,0x6f,0x36,0xce},{  0x58,0x74,0x21,0xd3},{  0x56,0x7d,0x2c,0xd8}, 
-{ 0x37,0xa1,0x0c,0x7a},{  0x39,0xa8,0x01,0x71},{  0x2b,0xb3,0x16,0x6c},{  0x25,0xba,0x1b,0x67}, 
-{ 0x0f,0x85,0x38,0x56},{  0x01,0x8c,0x35,0x5d},{  0x13,0x97,0x22,0x40},{  0x1d,0x9e,0x2f,0x4b}, 
-{ 0x47,0xe9,0x64,0x22},{  0x49,0xe0,0x69,0x29},{  0x5b,0xfb,0x7e,0x34},{  0x55,0xf2,0x73,0x3f}, 
-{ 0x7f,0xcd,0x50,0x0e},{  0x71,0xc4,0x5d,0x05},{  0x63,0xdf,0x4a,0x18},{  0x6d,0xd6,0x47,0x13}, 
-{ 0xd7,0x31,0xdc,0xca},{  0xd9,0x38,0xd1,0xc1},{  0xcb,0x23,0xc6,0xdc},{  0xc5,0x2a,0xcb,0xd7}, 
-{ 0xef,0x15,0xe8,0xe6},{  0xe1,0x1c,0xe5,0xed},{  0xf3,0x07,0xf2,0xf0},{  0xfd,0x0e,0xff,0xfb}, 
-{ 0xa7,0x79,0xb4,0x92},{  0xa9,0x70,0xb9,0x99},{  0xbb,0x6b,0xae,0x84},{  0xb5,0x62,0xa3,0x8f}, 
-{ 0x9f,0x5d,0x80,0xbe},{  0x91,0x54,0x8d,0xb5},{  0x83,0x4f,0x9a,0xa8},{  0x8d,0x46,0x97,0xa3 } 
-};
-
-word8 U2[256][4] = {
-{ 0x00,0x00,0x00,0x00},{  0x0b,0x0e,0x09,0x0d},{  0x16,0x1c,0x12,0x1a},{  0x1d,0x12,0x1b,0x17}, 
-{ 0x2c,0x38,0x24,0x34},{  0x27,0x36,0x2d,0x39},{  0x3a,0x24,0x36,0x2e},{  0x31,0x2a,0x3f,0x23}, 
-{ 0x58,0x70,0x48,0x68},{  0x53,0x7e,0x41,0x65},{  0x4e,0x6c,0x5a,0x72},{  0x45,0x62,0x53,0x7f}, 
-{ 0x74,0x48,0x6c,0x5c},{  0x7f,0x46,0x65,0x51},{  0x62,0x54,0x7e,0x46},{  0x69,0x5a,0x77,0x4b}, 
-{ 0xb0,0xe0,0x90,0xd0},{  0xbb,0xee,0x99,0xdd},{  0xa6,0xfc,0x82,0xca},{  0xad,0xf2,0x8b,0xc7}, 
-{ 0x9c,0xd8,0xb4,0xe4},{  0x97,0xd6,0xbd,0xe9},{  0x8a,0xc4,0xa6,0xfe},{  0x81,0xca,0xaf,0xf3}, 
-{ 0xe8,0x90,0xd8,0xb8},{  0xe3,0x9e,0xd1,0xb5},{  0xfe,0x8c,0xca,0xa2},{  0xf5,0x82,0xc3,0xaf}, 
-{ 0xc4,0xa8,0xfc,0x8c},{  0xcf,0xa6,0xf5,0x81},{  0xd2,0xb4,0xee,0x96},{  0xd9,0xba,0xe7,0x9b}, 
-{ 0x7b,0xdb,0x3b,0xbb},{  0x70,0xd5,0x32,0xb6},{  0x6d,0xc7,0x29,0xa1},{  0x66,0xc9,0x20,0xac}, 
-{ 0x57,0xe3,0x1f,0x8f},{  0x5c,0xed,0x16,0x82},{  0x41,0xff,0x0d,0x95},{  0x4a,0xf1,0x04,0x98}, 
-{ 0x23,0xab,0x73,0xd3},{  0x28,0xa5,0x7a,0xde},{  0x35,0xb7,0x61,0xc9},{  0x3e,0xb9,0x68,0xc4}, 
-{ 0x0f,0x93,0x57,0xe7},{  0x04,0x9d,0x5e,0xea},{  0x19,0x8f,0x45,0xfd},{  0x12,0x81,0x4c,0xf0}, 
-{ 0xcb,0x3b,0xab,0x6b},{  0xc0,0x35,0xa2,0x66},{  0xdd,0x27,0xb9,0x71},{  0xd6,0x29,0xb0,0x7c}, 
-{ 0xe7,0x03,0x8f,0x5f},{  0xec,0x0d,0x86,0x52},{  0xf1,0x1f,0x9d,0x45},{  0xfa,0x11,0x94,0x48}, 
-{ 0x93,0x4b,0xe3,0x03},{  0x98,0x45,0xea,0x0e},{  0x85,0x57,0xf1,0x19},{  0x8e,0x59,0xf8,0x14}, 
-{ 0xbf,0x73,0xc7,0x37},{  0xb4,0x7d,0xce,0x3a},{  0xa9,0x6f,0xd5,0x2d},{  0xa2,0x61,0xdc,0x20}, 
-{ 0xf6,0xad,0x76,0x6d},{  0xfd,0xa3,0x7f,0x60},{  0xe0,0xb1,0x64,0x77},{  0xeb,0xbf,0x6d,0x7a}, 
-{ 0xda,0x95,0x52,0x59},{  0xd1,0x9b,0x5b,0x54},{  0xcc,0x89,0x40,0x43},{  0xc7,0x87,0x49,0x4e}, 
-{ 0xae,0xdd,0x3e,0x05},{  0xa5,0xd3,0x37,0x08},{  0xb8,0xc1,0x2c,0x1f},{  0xb3,0xcf,0x25,0x12}, 
-{ 0x82,0xe5,0x1a,0x31},{  0x89,0xeb,0x13,0x3c},{  0x94,0xf9,0x08,0x2b},{  0x9f,0xf7,0x01,0x26}, 
-{ 0x46,0x4d,0xe6,0xbd},{  0x4d,0x43,0xef,0xb0},{  0x50,0x51,0xf4,0xa7},{  0x5b,0x5f,0xfd,0xaa}, 
-{ 0x6a,0x75,0xc2,0x89},{  0x61,0x7b,0xcb,0x84},{  0x7c,0x69,0xd0,0x93},{  0x77,0x67,0xd9,0x9e}, 
-{ 0x1e,0x3d,0xae,0xd5},{  0x15,0x33,0xa7,0xd8},{  0x08,0x21,0xbc,0xcf},{  0x03,0x2f,0xb5,0xc2}, 
-{ 0x32,0x05,0x8a,0xe1},{  0x39,0x0b,0x83,0xec},{  0x24,0x19,0x98,0xfb},{  0x2f,0x17,0x91,0xf6}, 
-{ 0x8d,0x76,0x4d,0xd6},{  0x86,0x78,0x44,0xdb},{  0x9b,0x6a,0x5f,0xcc},{  0x90,0x64,0x56,0xc1}, 
-{ 0xa1,0x4e,0x69,0xe2},{  0xaa,0x40,0x60,0xef},{  0xb7,0x52,0x7b,0xf8},{  0xbc,0x5c,0x72,0xf5}, 
-{ 0xd5,0x06,0x05,0xbe},{  0xde,0x08,0x0c,0xb3},{  0xc3,0x1a,0x17,0xa4},{  0xc8,0x14,0x1e,0xa9}, 
-{ 0xf9,0x3e,0x21,0x8a},{  0xf2,0x30,0x28,0x87},{  0xef,0x22,0x33,0x90},{  0xe4,0x2c,0x3a,0x9d}, 
-{ 0x3d,0x96,0xdd,0x06},{  0x36,0x98,0xd4,0x0b},{  0x2b,0x8a,0xcf,0x1c},{  0x20,0x84,0xc6,0x11}, 
-{ 0x11,0xae,0xf9,0x32},{  0x1a,0xa0,0xf0,0x3f},{  0x07,0xb2,0xeb,0x28},{  0x0c,0xbc,0xe2,0x25}, 
-{ 0x65,0xe6,0x95,0x6e},{  0x6e,0xe8,0x9c,0x63},{  0x73,0xfa,0x87,0x74},{  0x78,0xf4,0x8e,0x79}, 
-{ 0x49,0xde,0xb1,0x5a},{  0x42,0xd0,0xb8,0x57},{  0x5f,0xc2,0xa3,0x40},{  0x54,0xcc,0xaa,0x4d}, 
-{ 0xf7,0x41,0xec,0xda},{  0xfc,0x4f,0xe5,0xd7},{  0xe1,0x5d,0xfe,0xc0},{  0xea,0x53,0xf7,0xcd}, 
-{ 0xdb,0x79,0xc8,0xee},{  0xd0,0x77,0xc1,0xe3},{  0xcd,0x65,0xda,0xf4},{  0xc6,0x6b,0xd3,0xf9}, 
-{ 0xaf,0x31,0xa4,0xb2},{  0xa4,0x3f,0xad,0xbf},{  0xb9,0x2d,0xb6,0xa8},{  0xb2,0x23,0xbf,0xa5}, 
-{ 0x83,0x09,0x80,0x86},{  0x88,0x07,0x89,0x8b},{  0x95,0x15,0x92,0x9c},{  0x9e,0x1b,0x9b,0x91}, 
-{ 0x47,0xa1,0x7c,0x0a},{  0x4c,0xaf,0x75,0x07},{  0x51,0xbd,0x6e,0x10},{  0x5a,0xb3,0x67,0x1d}, 
-{ 0x6b,0x99,0x58,0x3e},{  0x60,0x97,0x51,0x33},{  0x7d,0x85,0x4a,0x24},{  0x76,0x8b,0x43,0x29}, 
-{ 0x1f,0xd1,0x34,0x62},{  0x14,0xdf,0x3d,0x6f},{  0x09,0xcd,0x26,0x78},{  0x02,0xc3,0x2f,0x75}, 
-{ 0x33,0xe9,0x10,0x56},{  0x38,0xe7,0x19,0x5b},{  0x25,0xf5,0x02,0x4c},{  0x2e,0xfb,0x0b,0x41}, 
-{ 0x8c,0x9a,0xd7,0x61},{  0x87,0x94,0xde,0x6c},{  0x9a,0x86,0xc5,0x7b},{  0x91,0x88,0xcc,0x76}, 
-{ 0xa0,0xa2,0xf3,0x55},{  0xab,0xac,0xfa,0x58},{  0xb6,0xbe,0xe1,0x4f},{  0xbd,0xb0,0xe8,0x42}, 
-{ 0xd4,0xea,0x9f,0x09},{  0xdf,0xe4,0x96,0x04},{  0xc2,0xf6,0x8d,0x13},{  0xc9,0xf8,0x84,0x1e}, 
-{ 0xf8,0xd2,0xbb,0x3d},{  0xf3,0xdc,0xb2,0x30},{  0xee,0xce,0xa9,0x27},{  0xe5,0xc0,0xa0,0x2a}, 
-{ 0x3c,0x7a,0x47,0xb1},{  0x37,0x74,0x4e,0xbc},{  0x2a,0x66,0x55,0xab},{  0x21,0x68,0x5c,0xa6}, 
-{ 0x10,0x42,0x63,0x85},{  0x1b,0x4c,0x6a,0x88},{  0x06,0x5e,0x71,0x9f},{  0x0d,0x50,0x78,0x92}, 
-{ 0x64,0x0a,0x0f,0xd9},{  0x6f,0x04,0x06,0xd4},{  0x72,0x16,0x1d,0xc3},{  0x79,0x18,0x14,0xce}, 
-{ 0x48,0x32,0x2b,0xed},{  0x43,0x3c,0x22,0xe0},{  0x5e,0x2e,0x39,0xf7},{  0x55,0x20,0x30,0xfa}, 
-{ 0x01,0xec,0x9a,0xb7},{  0x0a,0xe2,0x93,0xba},{  0x17,0xf0,0x88,0xad},{  0x1c,0xfe,0x81,0xa0}, 
-{ 0x2d,0xd4,0xbe,0x83},{  0x26,0xda,0xb7,0x8e},{  0x3b,0xc8,0xac,0x99},{  0x30,0xc6,0xa5,0x94}, 
-{ 0x59,0x9c,0xd2,0xdf},{  0x52,0x92,0xdb,0xd2},{  0x4f,0x80,0xc0,0xc5},{  0x44,0x8e,0xc9,0xc8}, 
-{ 0x75,0xa4,0xf6,0xeb},{  0x7e,0xaa,0xff,0xe6},{  0x63,0xb8,0xe4,0xf1},{  0x68,0xb6,0xed,0xfc}, 
-{ 0xb1,0x0c,0x0a,0x67},{  0xba,0x02,0x03,0x6a},{  0xa7,0x10,0x18,0x7d},{  0xac,0x1e,0x11,0x70}, 
-{ 0x9d,0x34,0x2e,0x53},{  0x96,0x3a,0x27,0x5e},{  0x8b,0x28,0x3c,0x49},{  0x80,0x26,0x35,0x44}, 
-{ 0xe9,0x7c,0x42,0x0f},{  0xe2,0x72,0x4b,0x02},{  0xff,0x60,0x50,0x15},{  0xf4,0x6e,0x59,0x18}, 
-{ 0xc5,0x44,0x66,0x3b},{  0xce,0x4a,0x6f,0x36},{  0xd3,0x58,0x74,0x21},{  0xd8,0x56,0x7d,0x2c}, 
-{ 0x7a,0x37,0xa1,0x0c},{  0x71,0x39,0xa8,0x01},{  0x6c,0x2b,0xb3,0x16},{  0x67,0x25,0xba,0x1b}, 
-{ 0x56,0x0f,0x85,0x38},{  0x5d,0x01,0x8c,0x35},{  0x40,0x13,0x97,0x22},{  0x4b,0x1d,0x9e,0x2f}, 
-{ 0x22,0x47,0xe9,0x64},{  0x29,0x49,0xe0,0x69},{  0x34,0x5b,0xfb,0x7e},{  0x3f,0x55,0xf2,0x73}, 
-{ 0x0e,0x7f,0xcd,0x50},{  0x05,0x71,0xc4,0x5d},{  0x18,0x63,0xdf,0x4a},{  0x13,0x6d,0xd6,0x47}, 
-{ 0xca,0xd7,0x31,0xdc},{  0xc1,0xd9,0x38,0xd1},{  0xdc,0xcb,0x23,0xc6},{  0xd7,0xc5,0x2a,0xcb}, 
-{ 0xe6,0xef,0x15,0xe8},{  0xed,0xe1,0x1c,0xe5},{  0xf0,0xf3,0x07,0xf2},{  0xfb,0xfd,0x0e,0xff}, 
-{ 0x92,0xa7,0x79,0xb4},{  0x99,0xa9,0x70,0xb9},{  0x84,0xbb,0x6b,0xae},{  0x8f,0xb5,0x62,0xa3}, 
-{ 0xbe,0x9f,0x5d,0x80},{  0xb5,0x91,0x54,0x8d},{  0xa8,0x83,0x4f,0x9a},{  0xa3,0x8d,0x46,0x97 } 
-};
-
-word8 U3[256][4] = {
-{ 0x00,0x00,0x00,0x00},{  0x0d,0x0b,0x0e,0x09},{  0x1a,0x16,0x1c,0x12},{  0x17,0x1d,0x12,0x1b}, 
-{ 0x34,0x2c,0x38,0x24},{  0x39,0x27,0x36,0x2d},{  0x2e,0x3a,0x24,0x36},{  0x23,0x31,0x2a,0x3f}, 
-{ 0x68,0x58,0x70,0x48},{  0x65,0x53,0x7e,0x41},{  0x72,0x4e,0x6c,0x5a},{  0x7f,0x45,0x62,0x53}, 
-{ 0x5c,0x74,0x48,0x6c},{  0x51,0x7f,0x46,0x65},{  0x46,0x62,0x54,0x7e},{  0x4b,0x69,0x5a,0x77}, 
-{ 0xd0,0xb0,0xe0,0x90},{  0xdd,0xbb,0xee,0x99},{  0xca,0xa6,0xfc,0x82},{  0xc7,0xad,0xf2,0x8b}, 
-{ 0xe4,0x9c,0xd8,0xb4},{  0xe9,0x97,0xd6,0xbd},{  0xfe,0x8a,0xc4,0xa6},{  0xf3,0x81,0xca,0xaf}, 
-{ 0xb8,0xe8,0x90,0xd8},{  0xb5,0xe3,0x9e,0xd1},{  0xa2,0xfe,0x8c,0xca},{  0xaf,0xf5,0x82,0xc3}, 
-{ 0x8c,0xc4,0xa8,0xfc},{  0x81,0xcf,0xa6,0xf5},{  0x96,0xd2,0xb4,0xee},{  0x9b,0xd9,0xba,0xe7}, 
-{ 0xbb,0x7b,0xdb,0x3b},{  0xb6,0x70,0xd5,0x32},{  0xa1,0x6d,0xc7,0x29},{  0xac,0x66,0xc9,0x20}, 
-{ 0x8f,0x57,0xe3,0x1f},{  0x82,0x5c,0xed,0x16},{  0x95,0x41,0xff,0x0d},{  0x98,0x4a,0xf1,0x04}, 
-{ 0xd3,0x23,0xab,0x73},{  0xde,0x28,0xa5,0x7a},{  0xc9,0x35,0xb7,0x61},{  0xc4,0x3e,0xb9,0x68}, 
-{ 0xe7,0x0f,0x93,0x57},{  0xea,0x04,0x9d,0x5e},{  0xfd,0x19,0x8f,0x45},{  0xf0,0x12,0x81,0x4c}, 
-{ 0x6b,0xcb,0x3b,0xab},{  0x66,0xc0,0x35,0xa2},{  0x71,0xdd,0x27,0xb9},{  0x7c,0xd6,0x29,0xb0}, 
-{ 0x5f,0xe7,0x03,0x8f},{  0x52,0xec,0x0d,0x86},{  0x45,0xf1,0x1f,0x9d},{  0x48,0xfa,0x11,0x94}, 
-{ 0x03,0x93,0x4b,0xe3},{  0x0e,0x98,0x45,0xea},{  0x19,0x85,0x57,0xf1},{  0x14,0x8e,0x59,0xf8}, 
-{ 0x37,0xbf,0x73,0xc7},{  0x3a,0xb4,0x7d,0xce},{  0x2d,0xa9,0x6f,0xd5},{  0x20,0xa2,0x61,0xdc}, 
-{ 0x6d,0xf6,0xad,0x76},{  0x60,0xfd,0xa3,0x7f},{  0x77,0xe0,0xb1,0x64},{  0x7a,0xeb,0xbf,0x6d}, 
-{ 0x59,0xda,0x95,0x52},{  0x54,0xd1,0x9b,0x5b},{  0x43,0xcc,0x89,0x40},{  0x4e,0xc7,0x87,0x49}, 
-{ 0x05,0xae,0xdd,0x3e},{  0x08,0xa5,0xd3,0x37},{  0x1f,0xb8,0xc1,0x2c},{  0x12,0xb3,0xcf,0x25}, 
-{ 0x31,0x82,0xe5,0x1a},{  0x3c,0x89,0xeb,0x13},{  0x2b,0x94,0xf9,0x08},{  0x26,0x9f,0xf7,0x01}, 
-{ 0xbd,0x46,0x4d,0xe6},{  0xb0,0x4d,0x43,0xef},{  0xa7,0x50,0x51,0xf4},{  0xaa,0x5b,0x5f,0xfd}, 
-{ 0x89,0x6a,0x75,0xc2},{  0x84,0x61,0x7b,0xcb},{  0x93,0x7c,0x69,0xd0},{  0x9e,0x77,0x67,0xd9}, 
-{ 0xd5,0x1e,0x3d,0xae},{  0xd8,0x15,0x33,0xa7},{  0xcf,0x08,0x21,0xbc},{  0xc2,0x03,0x2f,0xb5}, 
-{ 0xe1,0x32,0x05,0x8a},{  0xec,0x39,0x0b,0x83},{  0xfb,0x24,0x19,0x98},{  0xf6,0x2f,0x17,0x91}, 
-{ 0xd6,0x8d,0x76,0x4d},{  0xdb,0x86,0x78,0x44},{  0xcc,0x9b,0x6a,0x5f},{  0xc1,0x90,0x64,0x56}, 
-{ 0xe2,0xa1,0x4e,0x69},{  0xef,0xaa,0x40,0x60},{  0xf8,0xb7,0x52,0x7b},{  0xf5,0xbc,0x5c,0x72}, 
-{ 0xbe,0xd5,0x06,0x05},{  0xb3,0xde,0x08,0x0c},{  0xa4,0xc3,0x1a,0x17},{  0xa9,0xc8,0x14,0x1e}, 
-{ 0x8a,0xf9,0x3e,0x21},{  0x87,0xf2,0x30,0x28},{  0x90,0xef,0x22,0x33},{  0x9d,0xe4,0x2c,0x3a}, 
-{ 0x06,0x3d,0x96,0xdd},{  0x0b,0x36,0x98,0xd4},{  0x1c,0x2b,0x8a,0xcf},{  0x11,0x20,0x84,0xc6}, 
-{ 0x32,0x11,0xae,0xf9},{  0x3f,0x1a,0xa0,0xf0},{  0x28,0x07,0xb2,0xeb},{  0x25,0x0c,0xbc,0xe2}, 
-{ 0x6e,0x65,0xe6,0x95},{  0x63,0x6e,0xe8,0x9c},{  0x74,0x73,0xfa,0x87},{  0x79,0x78,0xf4,0x8e}, 
-{ 0x5a,0x49,0xde,0xb1},{  0x57,0x42,0xd0,0xb8},{  0x40,0x5f,0xc2,0xa3},{  0x4d,0x54,0xcc,0xaa}, 
-{ 0xda,0xf7,0x41,0xec},{  0xd7,0xfc,0x4f,0xe5},{  0xc0,0xe1,0x5d,0xfe},{  0xcd,0xea,0x53,0xf7}, 
-{ 0xee,0xdb,0x79,0xc8},{  0xe3,0xd0,0x77,0xc1},{  0xf4,0xcd,0x65,0xda},{  0xf9,0xc6,0x6b,0xd3}, 
-{ 0xb2,0xaf,0x31,0xa4},{  0xbf,0xa4,0x3f,0xad},{  0xa8,0xb9,0x2d,0xb6},{  0xa5,0xb2,0x23,0xbf}, 
-{ 0x86,0x83,0x09,0x80},{  0x8b,0x88,0x07,0x89},{  0x9c,0x95,0x15,0x92},{  0x91,0x9e,0x1b,0x9b}, 
-{ 0x0a,0x47,0xa1,0x7c},{  0x07,0x4c,0xaf,0x75},{  0x10,0x51,0xbd,0x6e},{  0x1d,0x5a,0xb3,0x67}, 
-{ 0x3e,0x6b,0x99,0x58},{  0x33,0x60,0x97,0x51},{  0x24,0x7d,0x85,0x4a},{  0x29,0x76,0x8b,0x43}, 
-{ 0x62,0x1f,0xd1,0x34},{  0x6f,0x14,0xdf,0x3d},{  0x78,0x09,0xcd,0x26},{  0x75,0x02,0xc3,0x2f}, 
-{ 0x56,0x33,0xe9,0x10},{  0x5b,0x38,0xe7,0x19},{  0x4c,0x25,0xf5,0x02},{  0x41,0x2e,0xfb,0x0b}, 
-{ 0x61,0x8c,0x9a,0xd7},{  0x6c,0x87,0x94,0xde},{  0x7b,0x9a,0x86,0xc5},{  0x76,0x91,0x88,0xcc}, 
-{ 0x55,0xa0,0xa2,0xf3},{  0x58,0xab,0xac,0xfa},{  0x4f,0xb6,0xbe,0xe1},{  0x42,0xbd,0xb0,0xe8}, 
-{ 0x09,0xd4,0xea,0x9f},{  0x04,0xdf,0xe4,0x96},{  0x13,0xc2,0xf6,0x8d},{  0x1e,0xc9,0xf8,0x84}, 
-{ 0x3d,0xf8,0xd2,0xbb},{  0x30,0xf3,0xdc,0xb2},{  0x27,0xee,0xce,0xa9},{  0x2a,0xe5,0xc0,0xa0}, 
-{ 0xb1,0x3c,0x7a,0x47},{  0xbc,0x37,0x74,0x4e},{  0xab,0x2a,0x66,0x55},{  0xa6,0x21,0x68,0x5c}, 
-{ 0x85,0x10,0x42,0x63},{  0x88,0x1b,0x4c,0x6a},{  0x9f,0x06,0x5e,0x71},{  0x92,0x0d,0x50,0x78}, 
-{ 0xd9,0x64,0x0a,0x0f},{  0xd4,0x6f,0x04,0x06},{  0xc3,0x72,0x16,0x1d},{  0xce,0x79,0x18,0x14}, 
-{ 0xed,0x48,0x32,0x2b},{  0xe0,0x43,0x3c,0x22},{  0xf7,0x5e,0x2e,0x39},{  0xfa,0x55,0x20,0x30}, 
-{ 0xb7,0x01,0xec,0x9a},{  0xba,0x0a,0xe2,0x93},{  0xad,0x17,0xf0,0x88},{  0xa0,0x1c,0xfe,0x81}, 
-{ 0x83,0x2d,0xd4,0xbe},{  0x8e,0x26,0xda,0xb7},{  0x99,0x3b,0xc8,0xac},{  0x94,0x30,0xc6,0xa5}, 
-{ 0xdf,0x59,0x9c,0xd2},{  0xd2,0x52,0x92,0xdb},{  0xc5,0x4f,0x80,0xc0},{  0xc8,0x44,0x8e,0xc9}, 
-{ 0xeb,0x75,0xa4,0xf6},{  0xe6,0x7e,0xaa,0xff},{  0xf1,0x63,0xb8,0xe4},{  0xfc,0x68,0xb6,0xed}, 
-{ 0x67,0xb1,0x0c,0x0a},{  0x6a,0xba,0x02,0x03},{  0x7d,0xa7,0x10,0x18},{  0x70,0xac,0x1e,0x11}, 
-{ 0x53,0x9d,0x34,0x2e},{  0x5e,0x96,0x3a,0x27},{  0x49,0x8b,0x28,0x3c},{  0x44,0x80,0x26,0x35}, 
-{ 0x0f,0xe9,0x7c,0x42},{  0x02,0xe2,0x72,0x4b},{  0x15,0xff,0x60,0x50},{  0x18,0xf4,0x6e,0x59}, 
-{ 0x3b,0xc5,0x44,0x66},{  0x36,0xce,0x4a,0x6f},{  0x21,0xd3,0x58,0x74},{  0x2c,0xd8,0x56,0x7d}, 
-{ 0x0c,0x7a,0x37,0xa1},{  0x01,0x71,0x39,0xa8},{  0x16,0x6c,0x2b,0xb3},{  0x1b,0x67,0x25,0xba}, 
-{ 0x38,0x56,0x0f,0x85},{  0x35,0x5d,0x01,0x8c},{  0x22,0x40,0x13,0x97},{  0x2f,0x4b,0x1d,0x9e}, 
-{ 0x64,0x22,0x47,0xe9},{  0x69,0x29,0x49,0xe0},{  0x7e,0x34,0x5b,0xfb},{  0x73,0x3f,0x55,0xf2}, 
-{ 0x50,0x0e,0x7f,0xcd},{  0x5d,0x05,0x71,0xc4},{  0x4a,0x18,0x63,0xdf},{  0x47,0x13,0x6d,0xd6}, 
-{ 0xdc,0xca,0xd7,0x31},{  0xd1,0xc1,0xd9,0x38},{  0xc6,0xdc,0xcb,0x23},{  0xcb,0xd7,0xc5,0x2a}, 
-{ 0xe8,0xe6,0xef,0x15},{  0xe5,0xed,0xe1,0x1c},{  0xf2,0xf0,0xf3,0x07},{  0xff,0xfb,0xfd,0x0e}, 
-{ 0xb4,0x92,0xa7,0x79},{  0xb9,0x99,0xa9,0x70},{  0xae,0x84,0xbb,0x6b},{  0xa3,0x8f,0xb5,0x62}, 
-{ 0x80,0xbe,0x9f,0x5d},{  0x8d,0xb5,0x91,0x54},{  0x9a,0xa8,0x83,0x4f},{  0x97,0xa3,0x8d,0x46 } 
-};
-
-word8 U4[256][4] = {
-{ 0x00,0x00,0x00,0x00},{  0x09,0x0d,0x0b,0x0e},{  0x12,0x1a,0x16,0x1c},{  0x1b,0x17,0x1d,0x12}, 
-{ 0x24,0x34,0x2c,0x38},{  0x2d,0x39,0x27,0x36},{  0x36,0x2e,0x3a,0x24},{  0x3f,0x23,0x31,0x2a}, 
-{ 0x48,0x68,0x58,0x70},{  0x41,0x65,0x53,0x7e},{  0x5a,0x72,0x4e,0x6c},{  0x53,0x7f,0x45,0x62}, 
-{ 0x6c,0x5c,0x74,0x48},{  0x65,0x51,0x7f,0x46},{  0x7e,0x46,0x62,0x54},{  0x77,0x4b,0x69,0x5a}, 
-{ 0x90,0xd0,0xb0,0xe0},{  0x99,0xdd,0xbb,0xee},{  0x82,0xca,0xa6,0xfc},{  0x8b,0xc7,0xad,0xf2}, 
-{ 0xb4,0xe4,0x9c,0xd8},{  0xbd,0xe9,0x97,0xd6},{  0xa6,0xfe,0x8a,0xc4},{  0xaf,0xf3,0x81,0xca}, 
-{ 0xd8,0xb8,0xe8,0x90},{  0xd1,0xb5,0xe3,0x9e},{  0xca,0xa2,0xfe,0x8c},{  0xc3,0xaf,0xf5,0x82}, 
-{ 0xfc,0x8c,0xc4,0xa8},{  0xf5,0x81,0xcf,0xa6},{  0xee,0x96,0xd2,0xb4},{  0xe7,0x9b,0xd9,0xba}, 
-{ 0x3b,0xbb,0x7b,0xdb},{  0x32,0xb6,0x70,0xd5},{  0x29,0xa1,0x6d,0xc7},{  0x20,0xac,0x66,0xc9}, 
-{ 0x1f,0x8f,0x57,0xe3},{  0x16,0x82,0x5c,0xed},{  0x0d,0x95,0x41,0xff},{  0x04,0x98,0x4a,0xf1}, 
-{ 0x73,0xd3,0x23,0xab},{  0x7a,0xde,0x28,0xa5},{  0x61,0xc9,0x35,0xb7},{  0x68,0xc4,0x3e,0xb9}, 
-{ 0x57,0xe7,0x0f,0x93},{  0x5e,0xea,0x04,0x9d},{  0x45,0xfd,0x19,0x8f},{  0x4c,0xf0,0x12,0x81}, 
-{ 0xab,0x6b,0xcb,0x3b},{  0xa2,0x66,0xc0,0x35},{  0xb9,0x71,0xdd,0x27},{  0xb0,0x7c,0xd6,0x29}, 
-{ 0x8f,0x5f,0xe7,0x03},{  0x86,0x52,0xec,0x0d},{  0x9d,0x45,0xf1,0x1f},{  0x94,0x48,0xfa,0x11}, 
-{ 0xe3,0x03,0x93,0x4b},{  0xea,0x0e,0x98,0x45},{  0xf1,0x19,0x85,0x57},{  0xf8,0x14,0x8e,0x59}, 
-{ 0xc7,0x37,0xbf,0x73},{  0xce,0x3a,0xb4,0x7d},{  0xd5,0x2d,0xa9,0x6f},{  0xdc,0x20,0xa2,0x61}, 
-{ 0x76,0x6d,0xf6,0xad},{  0x7f,0x60,0xfd,0xa3},{  0x64,0x77,0xe0,0xb1},{  0x6d,0x7a,0xeb,0xbf}, 
-{ 0x52,0x59,0xda,0x95},{  0x5b,0x54,0xd1,0x9b},{  0x40,0x43,0xcc,0x89},{  0x49,0x4e,0xc7,0x87}, 
-{ 0x3e,0x05,0xae,0xdd},{  0x37,0x08,0xa5,0xd3},{  0x2c,0x1f,0xb8,0xc1},{  0x25,0x12,0xb3,0xcf}, 
-{ 0x1a,0x31,0x82,0xe5},{  0x13,0x3c,0x89,0xeb},{  0x08,0x2b,0x94,0xf9},{  0x01,0x26,0x9f,0xf7}, 
-{ 0xe6,0xbd,0x46,0x4d},{  0xef,0xb0,0x4d,0x43},{  0xf4,0xa7,0x50,0x51},{  0xfd,0xaa,0x5b,0x5f}, 
-{ 0xc2,0x89,0x6a,0x75},{  0xcb,0x84,0x61,0x7b},{  0xd0,0x93,0x7c,0x69},{  0xd9,0x9e,0x77,0x67}, 
-{ 0xae,0xd5,0x1e,0x3d},{  0xa7,0xd8,0x15,0x33},{  0xbc,0xcf,0x08,0x21},{  0xb5,0xc2,0x03,0x2f}, 
-{ 0x8a,0xe1,0x32,0x05},{  0x83,0xec,0x39,0x0b},{  0x98,0xfb,0x24,0x19},{  0x91,0xf6,0x2f,0x17}, 
-{ 0x4d,0xd6,0x8d,0x76},{  0x44,0xdb,0x86,0x78},{  0x5f,0xcc,0x9b,0x6a},{  0x56,0xc1,0x90,0x64}, 
-{ 0x69,0xe2,0xa1,0x4e},{  0x60,0xef,0xaa,0x40},{  0x7b,0xf8,0xb7,0x52},{  0x72,0xf5,0xbc,0x5c}, 
-{ 0x05,0xbe,0xd5,0x06},{  0x0c,0xb3,0xde,0x08},{  0x17,0xa4,0xc3,0x1a},{  0x1e,0xa9,0xc8,0x14}, 
-{ 0x21,0x8a,0xf9,0x3e},{  0x28,0x87,0xf2,0x30},{  0x33,0x90,0xef,0x22},{  0x3a,0x9d,0xe4,0x2c}, 
-{ 0xdd,0x06,0x3d,0x96},{  0xd4,0x0b,0x36,0x98},{  0xcf,0x1c,0x2b,0x8a},{  0xc6,0x11,0x20,0x84}, 
-{ 0xf9,0x32,0x11,0xae},{  0xf0,0x3f,0x1a,0xa0},{  0xeb,0x28,0x07,0xb2},{  0xe2,0x25,0x0c,0xbc}, 
-{ 0x95,0x6e,0x65,0xe6},{  0x9c,0x63,0x6e,0xe8},{  0x87,0x74,0x73,0xfa},{  0x8e,0x79,0x78,0xf4}, 
-{ 0xb1,0x5a,0x49,0xde},{  0xb8,0x57,0x42,0xd0},{  0xa3,0x40,0x5f,0xc2},{  0xaa,0x4d,0x54,0xcc}, 
-{ 0xec,0xda,0xf7,0x41},{  0xe5,0xd7,0xfc,0x4f},{  0xfe,0xc0,0xe1,0x5d},{  0xf7,0xcd,0xea,0x53}, 
-{ 0xc8,0xee,0xdb,0x79},{  0xc1,0xe3,0xd0,0x77},{  0xda,0xf4,0xcd,0x65},{  0xd3,0xf9,0xc6,0x6b}, 
-{ 0xa4,0xb2,0xaf,0x31},{  0xad,0xbf,0xa4,0x3f},{  0xb6,0xa8,0xb9,0x2d},{  0xbf,0xa5,0xb2,0x23}, 
-{ 0x80,0x86,0x83,0x09},{  0x89,0x8b,0x88,0x07},{  0x92,0x9c,0x95,0x15},{  0x9b,0x91,0x9e,0x1b}, 
-{ 0x7c,0x0a,0x47,0xa1},{  0x75,0x07,0x4c,0xaf},{  0x6e,0x10,0x51,0xbd},{  0x67,0x1d,0x5a,0xb3}, 
-{ 0x58,0x3e,0x6b,0x99},{  0x51,0x33,0x60,0x97},{  0x4a,0x24,0x7d,0x85},{  0x43,0x29,0x76,0x8b}, 
-{ 0x34,0x62,0x1f,0xd1},{  0x3d,0x6f,0x14,0xdf},{  0x26,0x78,0x09,0xcd},{  0x2f,0x75,0x02,0xc3}, 
-{ 0x10,0x56,0x33,0xe9},{  0x19,0x5b,0x38,0xe7},{  0x02,0x4c,0x25,0xf5},{  0x0b,0x41,0x2e,0xfb}, 
-{ 0xd7,0x61,0x8c,0x9a},{  0xde,0x6c,0x87,0x94},{  0xc5,0x7b,0x9a,0x86},{  0xcc,0x76,0x91,0x88}, 
-{ 0xf3,0x55,0xa0,0xa2},{  0xfa,0x58,0xab,0xac},{  0xe1,0x4f,0xb6,0xbe},{  0xe8,0x42,0xbd,0xb0}, 
-{ 0x9f,0x09,0xd4,0xea},{  0x96,0x04,0xdf,0xe4},{  0x8d,0x13,0xc2,0xf6},{  0x84,0x1e,0xc9,0xf8}, 
-{ 0xbb,0x3d,0xf8,0xd2},{  0xb2,0x30,0xf3,0xdc},{  0xa9,0x27,0xee,0xce},{  0xa0,0x2a,0xe5,0xc0}, 
-{ 0x47,0xb1,0x3c,0x7a},{  0x4e,0xbc,0x37,0x74},{  0x55,0xab,0x2a,0x66},{  0x5c,0xa6,0x21,0x68}, 
-{ 0x63,0x85,0x10,0x42},{  0x6a,0x88,0x1b,0x4c},{  0x71,0x9f,0x06,0x5e},{  0x78,0x92,0x0d,0x50}, 
-{ 0x0f,0xd9,0x64,0x0a},{  0x06,0xd4,0x6f,0x04},{  0x1d,0xc3,0x72,0x16},{  0x14,0xce,0x79,0x18}, 
-{ 0x2b,0xed,0x48,0x32},{  0x22,0xe0,0x43,0x3c},{  0x39,0xf7,0x5e,0x2e},{  0x30,0xfa,0x55,0x20}, 
-{ 0x9a,0xb7,0x01,0xec},{  0x93,0xba,0x0a,0xe2},{  0x88,0xad,0x17,0xf0},{  0x81,0xa0,0x1c,0xfe}, 
-{ 0xbe,0x83,0x2d,0xd4},{  0xb7,0x8e,0x26,0xda},{  0xac,0x99,0x3b,0xc8},{  0xa5,0x94,0x30,0xc6}, 
-{ 0xd2,0xdf,0x59,0x9c},{  0xdb,0xd2,0x52,0x92},{  0xc0,0xc5,0x4f,0x80},{  0xc9,0xc8,0x44,0x8e}, 
-{ 0xf6,0xeb,0x75,0xa4},{  0xff,0xe6,0x7e,0xaa},{  0xe4,0xf1,0x63,0xb8},{  0xed,0xfc,0x68,0xb6}, 
-{ 0x0a,0x67,0xb1,0x0c},{  0x03,0x6a,0xba,0x02},{  0x18,0x7d,0xa7,0x10},{  0x11,0x70,0xac,0x1e}, 
-{ 0x2e,0x53,0x9d,0x34},{  0x27,0x5e,0x96,0x3a},{  0x3c,0x49,0x8b,0x28},{  0x35,0x44,0x80,0x26}, 
-{ 0x42,0x0f,0xe9,0x7c},{  0x4b,0x02,0xe2,0x72},{  0x50,0x15,0xff,0x60},{  0x59,0x18,0xf4,0x6e}, 
-{ 0x66,0x3b,0xc5,0x44},{  0x6f,0x36,0xce,0x4a},{  0x74,0x21,0xd3,0x58},{  0x7d,0x2c,0xd8,0x56}, 
-{ 0xa1,0x0c,0x7a,0x37},{  0xa8,0x01,0x71,0x39},{  0xb3,0x16,0x6c,0x2b},{  0xba,0x1b,0x67,0x25}, 
-{ 0x85,0x38,0x56,0x0f},{  0x8c,0x35,0x5d,0x01},{  0x97,0x22,0x40,0x13},{  0x9e,0x2f,0x4b,0x1d}, 
-{ 0xe9,0x64,0x22,0x47},{  0xe0,0x69,0x29,0x49},{  0xfb,0x7e,0x34,0x5b},{  0xf2,0x73,0x3f,0x55}, 
-{ 0xcd,0x50,0x0e,0x7f},{  0xc4,0x5d,0x05,0x71},{  0xdf,0x4a,0x18,0x63},{  0xd6,0x47,0x13,0x6d}, 
-{ 0x31,0xdc,0xca,0xd7},{  0x38,0xd1,0xc1,0xd9},{  0x23,0xc6,0xdc,0xcb},{  0x2a,0xcb,0xd7,0xc5}, 
-{ 0x15,0xe8,0xe6,0xef},{  0x1c,0xe5,0xed,0xe1},{  0x07,0xf2,0xf0,0xf3},{  0x0e,0xff,0xfb,0xfd}, 
-{ 0x79,0xb4,0x92,0xa7},{  0x70,0xb9,0x99,0xa9},{  0x6b,0xae,0x84,0xbb},{  0x62,0xa3,0x8f,0xb5},  
-{ 0x5d,0x80,0xbe,0x9f},{  0x54,0x8d,0xb5,0x91},{  0x4f,0x9a,0xa8,0x83},{  0x46,0x97,0xa3,0x8d }
-};
-
-word32 rcon[30] = { 
-  0x01,0x02, 0x04, 0x08, 0x10, 0x20, 0x40, 0x80, 0x1b, 0x36, 0x6c, 0xd8, 0xab, 0x4d, 0x9a, 0x2f, 0x5e, 0xbc, 0x63, 0xc6, 0x97, 0x35, 0x6a, 0xd4, 0xb3, 0x7d, 0xfa, 0xef, 0xc5, 0x91
-};
Index: trunk/include/samhain.h
===================================================================
--- trunk/include/samhain.h	(revision 459)
+++ trunk/include/samhain.h	(revision 481)
@@ -28,4 +28,30 @@
 #endif
 
+#if defined(__GNUC__) && (__GNUC__ >= 4)
+#define SH_GNUC_SENTINEL __attribute__((__sentinel__))
+#else
+#define SH_GNUC_SENTINEL
+#endif
+
+#if defined(__GNUC__) && (__GNUC__ >= 3)
+#undef  SH_GNUC_PURE
+#define SH_GNUC_PURE     __attribute__((pure))
+#undef  SH_GNUC_CONST
+#define SH_GNUC_CONST	 __attribute__((const))
+#undef  SH_GNUC_NORETURN
+#define SH_GNUC_NORETURN __attribute__((noreturn))
+#undef  SH_GNUC_MALLOC
+#define SH_GNUC_MALLOC   __attribute__((malloc))
+#else
+#undef  SH_GNUC_PURE
+#define SH_GNUC_PURE
+#undef  SH_GNUC_CONST
+#define SH_GNUC_CONST
+#undef  SH_GNUC_NORETURN
+#define SH_GNUC_NORETURN
+#undef  SH_GNUC_MALLOC
+#define SH_GNUC_MALLOC
+#endif
+
 /**************************************************
  *
@@ -57,6 +83,4 @@
 
 /* end IPv6 */
-
-#define REPLACE_OLD
 
 /* Standard buffer sizes. 
@@ -101,16 +125,29 @@
 #define PW_LEN     8
 
-#undef  GOOD
-#define GOOD  1
-#undef  BAD
-#define BAD   0
-#undef  ON
-#define ON    1
-#undef  OFF
-#define OFF   0
 #undef  S_TRUE
 #define S_TRUE    1
 #undef  S_FALSE
 #define S_FALSE   0
+
+#undef  GOOD
+#define GOOD  S_TRUE
+#undef  BAD
+#define BAD   S_FALSE
+
+
+#ifdef HAVE_INTTYPES_H
+#include <inttypes.h>
+#endif
+#ifdef HAVE_STDINT_H
+#include <stdint.h>
+#endif
+
+#if !defined(HAVE_UINT16_T)
+#define UINT16 unsigned short
+#else
+#define UINT16 uint16_t
+#endif
+
+#if !defined(HAVE_UINT32_T)
 
 /* An unsigned integer guaranteed to be 32 bit.
@@ -129,15 +166,8 @@
 #endif
 
-#ifdef HAVE_INTTYPES_H
-#include <inttypes.h>
-#endif
-#ifdef HAVE_STDINT_H
-#include <stdint.h>
-#endif
-
-#if !defined(HAVE_UINT16_T)
-#define UINT16 unsigned short
-#else
-#define UINT16 uint16_t
+#else
+#define UINT32 uint32_t
+#define SINT32 int32_t
+
 #endif
 
@@ -305,8 +335,8 @@
   int    client_severity;          /* TRUE if client severity used    */
   int    client_class;             /* TRUE if client class used       */
+  int    hidefile;                 /* TRUE if file not shown in log   */
+  int    inotify;                  /* Flags for inotify               */
   int    audit;
   unsigned long aud_mask;
-  int    hidefile;                 /* TRUE if file not shown in log   */
-  int    inotify;                  /* Flags for inotify               */
 } sh_sh_flag;
 
@@ -347,8 +377,11 @@
   /*@null@*//*@out@*/ char   * timezone;
 
+  int delayload;
+
 #ifdef SCREW_IT_UP
   int sigtrap_max_duration;
 #endif
 
+  char * outpath;
 } sh_struct;
 
@@ -365,4 +398,5 @@
 extern volatile  int      sig_termfast;           /* SIGTERM */
 extern volatile  int      sig_force_check;        /* SIGTTOU */
+extern volatile  int      sh_load_delta_flag;
 
 extern long int eintr__result;
@@ -420,29 +454,4 @@
 #endif
 
-#if defined(__GNUC__) && (__GNUC__ >= 4)
-#define SH_GNUC_SENTINEL __attribute__((__sentinel__))
-#else
-#define SH_GNUC_SENTINEL
-#endif
-
-#if defined(__GNUC__) && (__GNUC__ >= 3)
-#undef  SH_GNUC_PURE
-#define SH_GNUC_PURE     __attribute__((pure))
-#undef  SH_GNUC_CONST
-#define SH_GNUC_CONST	 __attribute__((const))
-#undef  SH_GNUC_NORETURN
-#define SH_GNUC_NORETURN __attribute__((noreturn))
-#undef  SH_GNUC_MALLOC
-#define SH_GNUC_MALLOC   __attribute__((malloc))
-#else
-#undef  SH_GNUC_PURE
-#define SH_GNUC_PURE
-#undef  SH_GNUC_CONST
-#define SH_GNUC_CONST
-#undef  SH_GNUC_NORETURN
-#define SH_GNUC_NORETURN
-#undef  SH_GNUC_MALLOC
-#define SH_GNUC_MALLOC
-#endif
 
 
@@ -481,12 +490,12 @@
 #ifdef USE_SUID
 #define MLOCK(a, b) \
-      if ((skey != NULL) && skey->mlock_failed == SL_FALSE){ \
+      if ((skey != NULL) && skey->mlock_failed == S_FALSE){ \
         (void) sl_set_suid(); \
-	if (sh_unix_mlock(FIL__, __LINE__, a, b) < 0) skey->mlock_failed = SL_TRUE; \
+	if (sh_unix_mlock(FIL__, __LINE__, a, b) < 0) skey->mlock_failed = S_TRUE; \
         (void) sl_unset_suid(); }
 #else
 #define MLOCK(a, b) \
-      if ((skey != NULL) && skey->mlock_failed == SL_FALSE){ \
-        if (sh_unix_mlock(FIL__, __LINE__, a, b) < 0) skey->mlock_failed = SL_TRUE; }
+      if ((skey != NULL) && skey->mlock_failed == S_FALSE){ \
+        if (sh_unix_mlock(FIL__, __LINE__, a, b) < 0) skey->mlock_failed = S_TRUE; }
 #endif 
 #else
@@ -498,5 +507,5 @@
 #ifdef USE_SUID
 #define MUNLOCK(a, b) \
-      if ((skey != NULL) && skey->mlock_failed == SL_FALSE){ \
+      if ((skey != NULL) && skey->mlock_failed == S_FALSE){ \
         (void) sl_set_suid(); \
 	(void) sh_unix_munlock( a, b );\
@@ -504,5 +513,5 @@
 #else
 #define MUNLOCK(a, b) \
-      if ((skey != NULL) && skey->mlock_failed == SL_FALSE){ \
+      if ((skey != NULL) && skey->mlock_failed == S_FALSE){ \
         (void) sh_unix_munlock( a, b ); }
 #endif 
Index: trunk/include/sh_calls.h
===================================================================
--- trunk/include/sh_calls.h	(revision 459)
+++ trunk/include/sh_calls.h	(revision 481)
@@ -30,4 +30,14 @@
 
 /*@-fixedformalarray@*/
+
+#include "config_xor.h"
+#if defined(__GNUC__) && (__GNUC__ >= 3)
+#undef  SH_GNUC_NORETURN
+#define SH_GNUC_NORETURN __attribute__((noreturn))
+#else
+#undef  SH_GNUC_NORETURN
+#define SH_GNUC_NORETURN
+#endif
+
 
 /* Set aud functions
@@ -83,7 +93,7 @@
 			     int * o_noatime);
 /*@noreturn@*/
-void     aud_exit   (const char * file, int line, int fd);
+void     aud_exit   (const char * file, int line, int fd) SH_GNUC_NORETURN;
 /*@noreturn@*/
-void     aud__exit  (const char * file, int line, int fd);
+void     aud__exit  (const char * file, int line, int fd) SH_GNUC_NORETURN;
 pid_t    aud_fork   (const char * file, int line);
 int      aud_pipe   (const char * file, int line, int modus[2]);
Index: trunk/include/sh_cat.h
===================================================================
--- trunk/include/sh_cat.h	(revision 459)
+++ trunk/include/sh_cat.h	(revision 481)
@@ -75,4 +75,5 @@
  MSG_CHECK_0,     
  MSG_CHECK_1,     
+ MSG_CHECK_2,     
  MSG_STAMP,       
  		  
@@ -80,5 +81,6 @@
  MSG_D_DSTART,    
  MSG_D_FAIL,      
-
+ MSG_D_DELTAOK,
+ MSG_D_DELTAFAIL,
 
 #ifndef HAVE_URANDOM 
@@ -98,16 +100,4 @@
  MSG_SUID_QREPORT,
  MSG_SUID_ERROR,
-#endif
-
-#ifdef SH_USE_KERN
- /* FreeBSD */
- MSG_KERN_POLICY,    
- MSG_KERN_POL_CO,
-
- /* Linux */
- MSG_KERN_SYSCALL,
- MSG_KERN_PROC,
- MSG_KERN_IDT,
- MSG_KERN_GATE,
 #endif
 
Index: trunk/include/sh_dbCheck.h
===================================================================
--- trunk/include/sh_dbCheck.h	(revision 481)
+++ trunk/include/sh_dbCheck.h	(revision 481)
@@ -0,0 +1,26 @@
+/* SAMHAIN file system integrity testing                                   */
+/* Copyright (C) 2015 Rainer Wichmann                                      */
+/*                                                                         */
+/*  This program is free software; you can redistribute it                 */
+/*  and/or modify                                                          */
+/*  it under the terms of the GNU General Public License as                */
+/*  published by                                                           */
+/*  the Free Software Foundation; either version 2 of the License, or      */
+/*  (at your option) any later version.                                    */
+/*                                                                         */
+/*  This program is distributed in the hope that it will be useful,        */
+/*  but WITHOUT ANY WARRANTY; without even the implied warranty of         */
+/*  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the          */
+/*  GNU General Public License for more details.                           */
+/*                                                                         */
+/*  You should have received a copy of the GNU General Public License      */
+/*  along with this program; if not, write to the Free Software            */
+/*  Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.              */
+
+
+#ifndef SH_DBCHECK_H
+#define SH_DBCHECK_H
+
+int sh_dbCheck_verify (const char * db_file);
+
+#endif
Index: trunk/include/sh_dbCreate.h
===================================================================
--- trunk/include/sh_dbCreate.h	(revision 481)
+++ trunk/include/sh_dbCreate.h	(revision 481)
@@ -0,0 +1,26 @@
+/* SAMHAIN file system integrity testing                                   */
+/* Copyright (C) 2015 Rainer Wichmann                                      */
+/*                                                                         */
+/*  This program is free software; you can redistribute it                 */
+/*  and/or modify                                                          */
+/*  it under the terms of the GNU General Public License as                */
+/*  published by                                                           */
+/*  the Free Software Foundation; either version 2 of the License, or      */
+/*  (at your option) any later version.                                    */
+/*                                                                         */
+/*  This program is distributed in the hope that it will be useful,        */
+/*  but WITHOUT ANY WARRANTY; without even the implied warranty of         */
+/*  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the          */
+/*  GNU General Public License for more details.                           */
+/*                                                                         */
+/*  You should have received a copy of the GNU General Public License      */
+/*  along with this program; if not, write to the Free Software            */
+/*  Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.              */
+
+
+#ifndef SH_DBCREATE_H
+#define SH_DBCREATE_H
+
+int sh_dbCreate (const char * path);
+
+#endif
Index: trunk/include/sh_dbIO.h
===================================================================
--- trunk/include/sh_dbIO.h	(revision 481)
+++ trunk/include/sh_dbIO.h	(revision 481)
@@ -0,0 +1,61 @@
+/* SAMHAIN file system integrity testing                                   */
+/* Copyright (C) 2015 Rainer Wichmann                                      */
+/*                                                                         */
+/*  This program is free software; you can redistribute it                 */
+/*  and/or modify                                                          */
+/*  it under the terms of the GNU General Public License as                */
+/*  published by                                                           */
+/*  the Free Software Foundation; either version 2 of the License, or      */
+/*  (at your option) any later version.                                    */
+/*                                                                         */
+/*  This program is distributed in the hope that it will be useful,        */
+/*  but WITHOUT ANY WARRANTY; without even the implied warranty of         */
+/*  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the          */
+/*  GNU General Public License for more details.                           */
+/*                                                                         */
+/*  You should have received a copy of the GNU General Public License      */
+/*  along with this program; if not, write to the Free Software            */
+/*  Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.              */
+
+
+#ifndef SH_DBIO_H
+#define SH_DBIO_H
+
+
+
+/* Read one line, trim newline. Return char count, or -1 on error or eof.
+ */
+int sh_dbIO_getline (FILE * fd, char * line, const size_t sizeofline);
+
+/* Read given database file for listing
+ */
+int sh_dbIO_list_db (const char * db_file);
+
+/* Write single record to database
+ */
+void sh_dbIO_data_write (file_type * buf, char * fileHash);
+
+/* Write whole default database
+ */
+int sh_dbIO_writeout_update ();
+
+/* write database to given path
+ */
+int sh_dbIO_writeout_to_path(const char * path);
+
+/* write database to stdout
+ */
+int sh_dbIO_writeout_stdout (const char * str);
+
+/* version string for database
+ */
+int sh_dbIO_version_string(const char * str);
+
+/* Load a delta database
+ */
+int sh_dbIO_load_delta();
+
+int sh_dbIO_list_binary (const char * c);
+int sh_dbIO_list_filter (const char * c);
+
+#endif
Index: trunk/include/sh_dbIO_int.h
===================================================================
--- trunk/include/sh_dbIO_int.h	(revision 481)
+++ trunk/include/sh_dbIO_int.h	(revision 481)
@@ -0,0 +1,157 @@
+/* SAMHAIN file system integrity testing                                   */
+/* Copyright (C) 2015 Rainer Wichmann                                      */
+/*                                                                         */
+/*  This program is free software; you can redistribute it                 */
+/*  and/or modify                                                          */
+/*  it under the terms of the GNU General Public License as                */
+/*  published by                                                           */
+/*  the Free Software Foundation; either version 2 of the License, or      */
+/*  (at your option) any later version.                                    */
+/*                                                                         */
+/*  This program is distributed in the hope that it will be useful,        */
+/*  but WITHOUT ANY WARRANTY; without even the implied warranty of         */
+/*  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the          */
+/*  GNU General Public License for more details.                           */
+/*                                                                         */
+/*  You should have received a copy of the GNU General Public License      */
+/*  along with this program; if not, write to the Free Software            */
+/*  Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.              */
+
+
+#ifndef SH_DBIO_INT_H
+#define SH_DBIO_INT_H
+
+#define SH_DEADFILE 0x44454144
+
+typedef struct store_info_old {
+
+  UINT32           mode;
+  UINT32           linkmode;
+
+  UINT64           dev;
+  UINT64           rdev;
+
+  UINT32           hardlinks;
+  UINT32           ino;
+
+  UINT64           size;
+  UINT64           atime;
+  UINT64           mtime;
+  UINT64           ctime;
+
+  UINT32           owner;
+  UINT32           group;
+
+  UINT32           attributes;
+
+  char             c_attributes[ATTRBUF_SIZE]; /* 16 = 2*UINT64 */
+
+  unsigned short   mark;
+  char             c_owner[USER_MAX+2];
+  char             c_group[GROUP_MAX+2];
+  char             c_mode[CMODE_SIZE];
+  char             checksum[KEY_LEN+1];
+  
+} sh_filestore_old_t;
+
+typedef struct store_info {
+
+  UINT32           mode;
+  UINT32           linkmode;
+
+  UINT64           dev;
+  UINT64           rdev;
+
+  UINT32           hardlinks;
+  UINT32           ino;
+
+  UINT64           size;
+  UINT64           atime;
+  UINT64           mtime;
+  UINT64           ctime;
+
+  UINT32           owner;
+  UINT32           group;
+
+  UINT32           attributes;
+
+  char             c_attributes[ATTRBUF_SIZE]; /* 16 = 2*UINT64 */
+
+  unsigned short   mark;
+  char             c_owner[USER_MAX+2];
+  char             c_group[GROUP_MAX+2];
+  char             c_mode[CMODE_SIZE];
+  char             checksum[KEY_LEN+1];
+  
+  /* If 'checkflags' is elsewhere, the compiler would still use
+   * a 6-byte padding to align the whole struct to an 8-byte boundary.
+   * ipad, opad: make explicit what the compiler does on a 64-byte system.
+   */
+  char             ipad[2];
+  UINT32           checkflags;
+  char             opad[4];
+
+} sh_filestore_t;
+  
+typedef struct file_info {
+  sh_filestore_t   theFile;
+  char           * fullpath;
+  char           * linkpath;
+  char           * attr_string;
+  int              fflags;
+  unsigned long    modi_mask;
+  struct           file_info * next;
+} sh_file_t;
+
+//* must fit an int              */
+#define TABSIZE 65536
+
+/* must fit an unsigned short   */
+/* changed for V0.8, as the     */
+/* database format has changed  */
+/* changed again for V0.9       */
+/* #define REC_MAGIC 19         */
+/* changed again for V1.3       */
+/* #define REC_MAGIC 20         */
+/* changed again for V1.4       */
+/* #define REC_MAGIC 21         */
+#define OLD_REC_MAGIC 21 
+/* changed again for V3.2       */
+#define REC_MAGIC 22
+
+#define REC_FLAGS_ATTR (1<<8)
+#define REC_FLAGS_MASK 0xFF00
+
+/* Insert into database table
+ */
+void hashinsert (sh_file_t * tab[TABSIZE], sh_file_t * s); 
+
+/* Internal conversion function
+ */
+file_type * sh_hash_create_ft (const sh_file_t * p, char * fileHash);
+
+/* Print what's in the link path
+ */
+int sh_hash_printcontent(char * linkpath);
+
+/* List database entry
+ */
+void sh_hash_list_db_entry (sh_file_t * p);
+
+/* get the location of the default/main database table
+ */
+sh_file_t ** get_default_data_table();
+
+/* Write whole database
+ */
+int sh_dbIO_writeout(sh_file_t * mtab[TABSIZE], const char * outpath, int truncate);
+
+/* Load from the default source into hash table 'tab'
+ */
+int sh_dbIO_load_db(sh_file_t * tab[TABSIZE]);
+
+/* Load from the file 'filepath' into hash table 'tab'
+ */
+int sh_dbIO_load_db_file(sh_file_t * tab[TABSIZE], const char * filepath);
+
+#endif
Index: trunk/include/sh_error.h
===================================================================
--- trunk/include/sh_error.h	(revision 459)
+++ trunk/include/sh_error.h	(revision 481)
@@ -178,8 +178,4 @@
 int sh_error_setdebug (char * debug_s);
 
-/* error messages
- */
-/*@owned@*/char * sh_error_message (int tellme, char * str, size_t len);
-
 /* switch on/off log to file temporarily
  */
@@ -198,9 +194,9 @@
 void reset_count_dev_console(void);
 
+/* close the message queue [no-op if !defined(WITH_MESSAGE_QUEUE)]
+ */
+void close_ipc (void);
+
 #ifdef WITH_MESSAGE_QUEUE
-/* close the message queue
- */
-void close_ipc (void);
-
 /* enable message queue
  */
Index: trunk/include/sh_error_min.h
===================================================================
--- trunk/include/sh_error_min.h	(revision 459)
+++ trunk/include/sh_error_min.h	(revision 481)
@@ -35,3 +35,7 @@
 int sh_error_convert_level (const char * str_s);
 
+/* error messages
+ */
+char * sh_error_message (int tellme, char * str, size_t len);
+
 #endif
Index: trunk/include/sh_extern.h
===================================================================
--- trunk/include/sh_extern.h	(revision 459)
+++ trunk/include/sh_extern.h	(revision 481)
@@ -42,5 +42,5 @@
  *    executes shell command
  */
-int sh_ext_popen_init (sh_tas_t * task, char * command, char * argv0, ...) SH_GNUC_SENTINEL;
+int sh_ext_popen_init (sh_tas_t * task, const char * command, char * argv0, ...) SH_GNUC_SENTINEL;
 
 /*
@@ -52,5 +52,5 @@
  * -- Execute command, return first line of output
  */
-char * sh_ext_popen_str (char * command);
+char * sh_ext_popen_str (const char * command);
 
 /*
Index: trunk/include/sh_fifo.h
===================================================================
--- trunk/include/sh_fifo.h	(revision 459)
+++ trunk/include/sh_fifo.h	(revision 481)
@@ -33,4 +33,6 @@
 } SH_FIFO;
 
+#define SH_FIFO_INITIALIZER { NULL, NULL, 0 }
+
 /*****************************************************
  *
@@ -42,6 +44,6 @@
  *
  */
-#define fifo_init(fifo_p) { fifo_p->fifo_cts = 0; fifo_p->head_ptr = NULL; \
- fifo_p->tail_ptr = NULL; }
+#define fifo_init(fifo_p) { (fifo_p)->fifo_cts = 0; (fifo_p)->head_ptr = NULL; \
+    (fifo_p)->tail_ptr = NULL; }
 
 
@@ -50,5 +52,6 @@
  * Returns: -1 if the list is full, 0 on success 
  */
-int push_list (SH_FIFO * fifo, char * indat, int in_i, const char * in_str);
+int push_list (SH_FIFO * fifo, const char * indat, int in_i, const char * in_str);
+#define sh_fifo_push(a, b) push_list((a), (b), 0, NULL)
 
 /* Push an item on the tail of the list.
@@ -56,5 +59,6 @@
  * Returns: -1 if the list is full, 0 on success 
  */
-int push_tail_list (SH_FIFO * fifo, char * indat, int in_i, const char * in_str);
+int push_tail_list (SH_FIFO * fifo, const char * indat, int in_i, const char * in_str);
+#define sh_fifo_push_tail(a, b) push_tail_list((a), (b), 0, NULL)
 
 /* pop an item from the tail of the list
@@ -64,12 +68,27 @@
  */
 char * pop_list (SH_FIFO * fifo);
+#define sh_fifo_pop(a) pop_list((a))
 
+/* ----  Special functions -------------------------------------------------*/
 
+/* This is for eMail where different recipients may be eligible for         *
+ * different subsets of messages. We need to delete all that were sent      *
+ * to all intended recipients, and keep all with at least one failure.      */
+
+/* Iterate over list and check for each if it is valid for 'tag';
+ * i.e. (item->s_extra == tag). If yes, add to the returned string.
+ * If (okNull == False) then item->s_xtra must be defined
+ */
 sh_string * tag_list (SH_FIFO * fifo, char * tag,
 		      int(*check)(int, const char*, const char*, const void*),
 		      const void * info, int okNull);
+
+/* Flag all tagged as candidate to keep */
 void rollback_list (SH_FIFO * fifo);
+/* Flag all tagged as candidate to delete */
 void mark_list (SH_FIFO * fifo);
+/* Remove all flags */
 void reset_list (SH_FIFO * fifo);
+/* Delete all marked for delete that are not flagged for keep */
 int commit_list (SH_FIFO * fifo);
 
Index: trunk/include/sh_files.h
===================================================================
--- trunk/include/sh_files.h	(revision 459)
+++ trunk/include/sh_files.h	(revision 481)
@@ -31,4 +31,12 @@
 };
 
+/* Fix the check flags
+ */
+void sh_files_fixup_mask (int class, unsigned long * check_flags);
+
+/* Dequote a filename in the config file
+ */
+char * sh_files_parse_input(const char * str_s, size_t * len);
+
 /* Check whether a file is in the config 
  */
@@ -233,5 +241,5 @@
 int sh_files_redef_allignore(const char * str);
 
-ShFileType sh_files_filecheck (int class, unsigned long check_mask,
+ShFileType sh_files_filecheck (int class, unsigned long check_flags,
 			       const char * dirName, 
 			       const char * infileName,
@@ -239,12 +247,12 @@
 			       int rsrcflag);
 
-int sh_files_checkdir (int iclass, unsigned long check_mask, 
+int sh_files_checkdir (int iclass, unsigned long check_flags, 
 		       int idepth, char * iname, 
 		       char * relativeName);
 
 int sh_files_search_file(char * name, int * class, 
-			 unsigned long *check_mask, int * reported);
+			 unsigned long *check_flags, int * reported);
 int sh_files_search_dir(char * name, int * class, 
-			unsigned long *check_mask, int *reported,
+			unsigned long *check_flags, int *reported,
 			int * rdepth);
 void sh_files_set_file_reported(const char * name);
Index: trunk/include/sh_forward.h
===================================================================
--- trunk/include/sh_forward.h	(revision 459)
+++ 	(revision )
@@ -1,125 +1,0 @@
-/* SAMHAIN file system integrity testing                                   */
-/* Copyright (C) 1999 Rainer Wichmann                                      */
-/*                                                                         */
-/*  This program is free software; you can redistribute it                 */
-/*  and/or modify                                                          */
-/*  it under the terms of the GNU General Public License as                */
-/*  published by                                                           */
-/*  the Free Software Foundation; either version 2 of the License, or      */
-/*  (at your option) any later version.                                    */
-/*                                                                         */
-/*  This program is distributed in the hope that it will be useful,        */
-/*  but WITHOUT ANY WARRANTY; without even the implied warranty of         */
-/*  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the          */
-/*  GNU General Public License for more details.                           */
-/*                                                                         */
-/*  You should have received a copy of the GNU General Public License      */
-/*  along with this program; if not, write to the Free Software            */
-/*  Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.              */
-
-#ifndef SH_FORWARD_H
-#define SH_FORWARD_H
-
-#ifndef SH_STANDALONE
-int sh_forward_set_strip (const char * str);
-
-#endif
-
-/* generate a random password
- */
-int sh_forward_create_password (const char * dummy);
-
-/* set timeout for active client connections
- */
-int sh_forward_set_timeout (const char * c);
-
-/* set time limit after which client is reported dead 
- */
-int sh_forward_set_time_limit(const char * str);
-
-/* error level for lookup failure
- */
-int sh_forward_lookup_level (const char * c);
-
-/* create client entry for given password
- */
-int sh_forward_make_client (const char * str);
-
-/* set port to which we connect
- */
-int sh_forward_server_port (const char * str);
-
-#ifdef SH_WITH_SERVER
-
-#ifdef INET_SYSLOG
-int set_syslog_active(const char * c);
-#endif
-
-/* create socket and start listening
- */
-void create_server_tcp_socket (void);
-
-/* whether to use client address as known to the communication layer
- * and set by accept()
- */
-int set_socket_peer (const char * c);
-
-/* whether to use client severity
- */
-int sh_forward_use_clt_sev (const char * c);
-
-/* whether to use client class
- */
-int sh_forward_use_clt_class (const char * c);
-
-/* server port
- */
-int sh_forward_set_port(const char * c);
-
-/* server interface
- */
-int sh_forward_set_interface(const char * c);
-
-/* a wrapper function
- */
-void sh_forward_html_write(void);
-
-/* register a client
- */
-int sh_forward_register_client (const char * str);
-
-/* start server
- */
-void sh_receive(void);
-
-/* free() everything
- */
-void sh_forward_free_all (void);
-
-#endif
-
-#if defined(SH_WITH_CLIENT) || defined(SH_WITH_SERVER)
-/* talk to server
- */
-long  sh_forward (char * errmsg);
-
-/* set log server
- */
-int sh_forward_setlogserver (const char * address);
-void reset_count_dev_server(void);
-#endif
-
-#ifdef SH_WITH_CLIENT
-
-/* Throttle file download
- */
-int sh_forward_set_throttle_delay (const char * c);
-
-/* request file from server. file may be "CONF" or "DATA".
- */
-long sh_forward_req_file (char * file);
-
-#endif
-
-#endif
-
Index: trunk/include/sh_gpg.h
===================================================================
--- trunk/include/sh_gpg.h	(revision 459)
+++ trunk/include/sh_gpg.h	(revision 481)
@@ -23,4 +23,7 @@
 #define SH_GPG_H
 
+#define SIG_CONF 1
+#define SIG_DATA 2
+
 /* Top level function to verify file.
  */
@@ -30,5 +33,5 @@
  * and/or database cannot be verified; otherwise returns 0
  */
-int sh_gpg_check_sign (long file_1, long file_2, int what);
+int sh_gpg_check_sign (long file, int what);
 
 /* log successful startup
Index: trunk/include/sh_guid.h
===================================================================
--- trunk/include/sh_guid.h	(revision 481)
+++ trunk/include/sh_guid.h	(revision 481)
@@ -0,0 +1,34 @@
+/* SAMHAIN file system integrity testing                                   */
+/* Copyright (C) 2015 Rainer Wichmann                                      */
+/*                                                                         */
+/*  This program is free software; you can redistribute it                 */
+/*  and/or modify                                                          */
+/*  it under the terms of the GNU General Public License as                */
+/*  published by                                                           */
+/*  the Free Software Foundation; either version 2 of the License, or      */
+/*  (at your option) any later version.                                    */
+/*                                                                         */
+/*  This program is distributed in the hope that it will be useful,        */
+/*  but WITHOUT ANY WARRANTY; without even the implied warranty of         */
+/*  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the          */
+/*  GNU General Public License for more details.                           */
+/*                                                                         */
+/*  You should have received a copy of the GNU General Public License      */
+/*  along with this program; if not, write to the Free Software            */
+/*  Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.              */
+
+
+#ifndef SH_GUID_H
+#define SH_GUID_H
+
+
+#define SH_UUID_BUF 37
+
+char * sh_uuid_generate_random(char * out, size_t len);
+
+/* return 0 if it looks like a uuid
+ */
+int sh_uuid_check(const char * in);
+
+#endif
+
Index: trunk/include/sh_hash.h
===================================================================
--- trunk/include/sh_hash.h	(revision 459)
+++ trunk/include/sh_hash.h	(revision 481)
@@ -28,4 +28,12 @@
 #include "sh_error.h"
 
+/* the report_checkflags flag
+ */
+int get_report_checkflags();
+
+/* whether to report checkflags
+ */
+int set_report_checkflags(const char * c);
+
 /* convert to policy string
  */
@@ -40,15 +48,21 @@
 int hashreport_missing( char *fullpath, int level);
 
+/* remove internal db record for a file (checks for some flags).
+ */
+void sh_hash_remove (const char * path);
+
 /* remove internal db record for a file
  */
-void sh_hash_remove (const char * path);
-
-/* write database to stdout
- */
-int sh_hash_pushdata_stdout (const char * str);
-
-/* version string for database
- */
-int sh_hash_version_string(const char * str);
+void sh_hash_remove_unconditional (const char * path);
+
+/* Insert a "null" record in-memory (representing a missing file).
+ */
+void sh_hash_insert_null(char * str);
+
+#ifdef SH_DBIO_INT_H
+/* Check for "null" record
+ */
+int sh_hash_is_null_record(sh_filestore_t * theFile);
+#endif
 
 /* Dont report on ctm/mtm change for directories
@@ -56,12 +70,12 @@
 int sh_hash_loosedircheck(const char * str);
 
-/* List database content
- */
-int sh_hash_list_db (const char * db_file);
-
 /* List database content for a single file
  */
 int set_list_file (const char * c);
 
+/* Set the path of that file
+ */
+char * get_list_file();
+
 /* List database content with full detail
  */
@@ -75,4 +89,16 @@
  */
 void sh_hash_init (void);
+
+/* Check init status
+ */
+int sh_hash_get_initialized();
+
+/* Read the database from disk and fill sh.data.hash with checksum.
+ */
+void sh_hash_init_and_checksum();
+
+/* Set status to 'database is read in'.
+ */
+void sh_hash_set_initialized();
 
 /* Check whether a file is present in the database.
Index: trunk/include/sh_html.h
===================================================================
--- trunk/include/sh_html.h	(revision 459)
+++ trunk/include/sh_html.h	(revision 481)
@@ -53,4 +53,5 @@
   int                     encf_flag;
   int                     ency_flag;
+  int                     ivst_flag;
   int                     status_now;
   int                     status_arr[CLT_MAX];
Index: trunk/include/sh_inotify.h
===================================================================
--- trunk/include/sh_inotify.h	(revision 459)
+++ trunk/include/sh_inotify.h	(revision 481)
@@ -32,13 +32,13 @@
 
 int sh_inotify_add_watch(char * filename, sh_watches * watches, int  * errnum,
-			 int class, unsigned long check_mask, int type, int rdepth);
+			 int class, unsigned long check_flags, int type, int rdepth);
 
 int sh_inotify_add_watch_later(const char * filename, sh_watches * watches, 
 			       int  * errnum,
-			       int class, unsigned long check_mask, 
+			       int class, unsigned long check_flags, 
 			       int type, int rdepth);
 
 char * sh_inotify_pop_dormant(sh_watches * watches, int * class, 
-			      unsigned long * check_mask, int * type, int * rdepth);
+			      unsigned long * check_flags, int * type, int * rdepth);
 
 void sh_inotify_purge_dormant(sh_watches * watches);
@@ -47,5 +47,5 @@
 
 char * sh_inotify_search_item(sh_watches * watches, int watch, 
-			      int * class, unsigned long * check_mask, 
+			      int * class, unsigned long * check_flags, 
 			      int * type, int * rdepth);
 ssize_t sh_inotify_read(char * buffer, size_t count);
Index: trunk/include/sh_kern.h
===================================================================
--- trunk/include/sh_kern.h	(revision 459)
+++ 	(revision )
@@ -1,30 +1,0 @@
-
-#ifndef SH_KERN_H
-#define SH_KERN_H
-
-#include "sh_modules.h"
-
-#ifdef SH_USE_KERN
-int sh_kern_init  (struct mod_type * arg);
-int sh_kern_timer (time_t tcurrent);
-int sh_kern_check (void);
-int sh_kern_end   (void);
-int sh_kern_null  (void);
-
-int sh_kern_set_activate (const char * c);
-int sh_kern_set_severity (const char * c);
-int sh_kern_set_timer    (const char * c);
-int sh_kern_set_idt      (const char * c);
-int sh_kern_set_pci      (const char * c);
-int sh_kern_set_proc     (const char * c);
-int sh_kern_set_sct_addr (const char * c);
-int sh_kern_set_sc_addr  (const char * c);
-int sh_kern_set_proc_root (const char * c);
-int sh_kern_set_proc_root_lookup (const char * c);
-int sh_kern_set_proc_root_iops (const char * c);
-
-extern sh_rconf sh_kern_table[];
-#endif
-
-/* #ifndef SH_UTMP_H */
-#endif
Index: trunk/include/sh_prelink.h
===================================================================
--- trunk/include/sh_prelink.h	(revision 459)
+++ trunk/include/sh_prelink.h	(revision 481)
@@ -6,5 +6,5 @@
  * alert_timeout: timeout for read
  */
-int sh_prelink_run (char * path, char * file_hash, int alert_timeout);
+int sh_prelink_run (char * path, char * file_hash, int alert_timeout, unsigned long mask);
 
 /* return S_TRUE if ELF file, S_FALSE otherwise
Index: trunk/include/sh_sem.h
===================================================================
--- trunk/include/sh_sem.h	(revision 481)
+++ trunk/include/sh_sem.h	(revision 481)
@@ -0,0 +1,14 @@
+#ifndef SH_SEM_H
+#define SH_SEM_H
+
+#define SH_SEM_LOCK       -1
+#define SH_SEM_UNLOCK      1
+
+void sh_sem_open();
+void sh_sem_trylock();
+void sh_sem_lock();
+void sh_sem_unlock(long val);
+void sh_sem_close();
+
+int  sh_sem_wait(const char * wait);
+#endif
Index: trunk/include/sh_socket.h
===================================================================
--- trunk/include/sh_socket.h	(revision 459)
+++ trunk/include/sh_socket.h	(revision 481)
@@ -8,5 +8,10 @@
 
 #if defined (SH_WITH_CLIENT)
-void sh_socket_server_cmd(const char * srvcmd);
+char * sh_socket_get_uuid(int * errflag, unsigned int * count, time_t * last);
+int    sh_socket_store_uuid(const char * cmd);
+int    sh_socket_return_uuid(const char * uuid, unsigned int count, time_t last);
+void   sh_socket_server_cmd(const char * srvcmd);
+int    set_delta_retry_interval(const char * str);
+int    set_delta_retry_count(const char * str);
 #endif
 
Index: trunk/include/sh_tiger.h
===================================================================
--- trunk/include/sh_tiger.h	(revision 459)
+++ trunk/include/sh_tiger.h	(revision 481)
@@ -44,4 +44,13 @@
 int sh_tiger_get_hashtype (void);
 
+/* set the hash fuction in use in the mask
+ */
+void sh_tiger_get_mask_hashtype(unsigned long * mask);
+
+
+/* reset the hash function to the one in the mask
+ */
+void sh_tiger_set_hashtype_mask(unsigned long mask);
+
 /* GnuPG-like format, returns allocated memory
  */
Index: trunk/include/sh_tools.h
===================================================================
--- trunk/include/sh_tools.h	(revision 459)
+++ trunk/include/sh_tools.h	(revision 481)
@@ -8,9 +8,11 @@
  */
 #define SH_PROTO_SRP (1 << 0)
+#define SH_PROTO_IVA (1 << 1)
 #define SH_PROTO_MSG (1 << 2)
 #define SH_PROTO_BIG (1 << 3)
 #define SH_PROTO_END (1 << 4)
-#define SH_PROTO_ENC (1 << 5)
+#define SH_PROTO_EN1 (1 << 5)
 #define SH_PROTO_EN2 (1 << 6)
+#define SH_PROTO_ENC (SH_PROTO_EN1|SH_PROTO_EN2)
 #define SH_MASK_ENC (SH_PROTO_ENC|SH_PROTO_EN2)
 
@@ -44,7 +46,9 @@
 #if defined (SH_WITH_SERVER)
 
+unsigned char sh_tools_probe_store(unsigned char protocol, int * probe_flag);
+
 int get_open_max (void);
 
-void put_header (/*@out@*/unsigned char * head, int protocol, 
+void put_header (/*@out@*/unsigned char * head, const int protocol, 
 		 unsigned long * length, char * u);
 
@@ -59,11 +63,15 @@
 /* returns allocated buffer
  */
-char * get_client_conf_file (char * peer, unsigned long * length);
+char * get_client_conf_file (const char * peer, unsigned long * length);
 
 /* returns allocated buffer
  */
-char * get_client_data_file (char * peer, unsigned long * length);
+char * get_client_data_file (const char * peer, unsigned long * length);
 
+/* returns allocated buffer
+ */
+char * get_client_uuid_file (const char * peer, unsigned long * length, const char * uuid);
 #endif
+
 
 unsigned long read_port (int sockfd, char *buf, unsigned long nbytes, 
@@ -72,4 +80,6 @@
 
 #if defined (SH_WITH_CLIENT) || defined(SH_WITH_SERVER)
+
+void sh_tools_probe_reset();
 
 unsigned long write_port (int sockfd, char *buf, unsigned long nbytes, 
Index: trunk/include/sh_trace.h
===================================================================
--- trunk/include/sh_trace.h	(revision 459)
+++ trunk/include/sh_trace.h	(revision 481)
@@ -9,7 +9,10 @@
 #define ASSERT(expr, expr1) \
       if (!(expr)) \
-         fprintf(stderr, \
+	{ \
+         fprintf(stderr,	    \
 		 SDG_AERRO, \
-		 FIL__, __LINE__, expr1 );
+		 FIL__, __LINE__, expr1 ); \
+          abort(); \
+	}
 
 
Index: trunk/include/sh_unix.h
===================================================================
--- trunk/include/sh_unix.h	(revision 459)
+++ trunk/include/sh_unix.h	(revision 481)
@@ -68,4 +68,5 @@
 /* inode        */
 #define MODI_INO (1 << 2)
+
 /* user         */
 #define MODI_USR (1 << 3)
@@ -74,4 +75,5 @@
 /* mtime        */
 #define MODI_MTM (1 << 5)
+
 /* ctime        */
 #define MODI_CTM (1 << 6)
@@ -80,4 +82,5 @@
 /* size         */
 #define MODI_SIZ (1 << 8)
+
 /* file mode    */
 #define MODI_MOD (1 << 9)
@@ -86,9 +89,9 @@
 /* device type   */
 #define MODI_RDEV (1 << 11)
+
 /* size may grow   */
 #define MODI_SGROW (1 << 12)
 /* use prelink     */
 #define MODI_PREL (1 << 13)
-
 /* get content     */
 #define MODI_TXT ((1 << 14)|MODI_CHK)
@@ -98,7 +101,21 @@
 #define MODI_AUDIT (1 << 15)
 #define MODI_AUDIT_ENABLED(a) (((a)&(1 << 15))!=0)
-
-#define MODI_INIT 0xDA000000UL
-#define MODI_INITIALIZED(a) (((a) & 0xFF000000UL) == MODI_INIT)
+/* do not check  */
+#define MODI_NOCHECK (1 << 16)
+/* do not check  */
+#define MODI_ALLIGNORE (1 << 17)
+
+#define MODI_TIGER192  0x01000000UL
+#define MODI_SHA1      0x02000000UL
+#define MODI_MD5       0x03000000UL
+#define MODI_SHA256    0x04000000UL
+#define MODI_HASHTYPE  0x0F000000UL
+
+#define MODI_INIT 0xD0000000UL
+#define MODI_INITIALIZED(a) (((a) & 0xF0000000UL) == MODI_INIT)
+
+#define MODI_SET(a, b) ((a) |= (b))
+#define MODI_CLEAR(a, b) ((a) &= ~(b))
+#define MODI_ISSET(a, b) (((a) & (b)) != 0)
 
 #define SH_TXT_MAX 9200
@@ -128,5 +145,5 @@
 
 typedef struct file_struct {
-  unsigned long    check_mask;
+  unsigned long    check_flags;
   int              file_reported;
   char             fullpath[PATH_MAX];
@@ -314,5 +331,5 @@
  */
 int sh_check_rotated_log (const char * path,  
-			  UINT64 old_size, UINT64 old_inode, const char * old_hash);
+			  UINT64 old_size, UINT64 old_inode, const char * old_hash, unsigned long mask);
 
 /* obtain file info
Index: trunk/include/sh_xfer.h
===================================================================
--- trunk/include/sh_xfer.h	(revision 481)
+++ trunk/include/sh_xfer.h	(revision 481)
@@ -0,0 +1,124 @@
+/* SAMHAIN file system integrity testing                                   */
+/* Copyright (C) 1999, 2015 Rainer Wichmann                                */
+/*                                                                         */
+/*  This program is free software; you can redistribute it                 */
+/*  and/or modify                                                          */
+/*  it under the terms of the GNU General Public License as                */
+/*  published by                                                           */
+/*  the Free Software Foundation; either version 2 of the License, or      */
+/*  (at your option) any later version.                                    */
+/*                                                                         */
+/*  This program is distributed in the hope that it will be useful,        */
+/*  but WITHOUT ANY WARRANTY; without even the implied warranty of         */
+/*  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the          */
+/*  GNU General Public License for more details.                           */
+/*                                                                         */
+/*  You should have received a copy of the GNU General Public License      */
+/*  along with this program; if not, write to the Free Software            */
+/*  Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.              */
+
+#ifndef SH_XFER_H
+#define SH_XFER_H
+
+#ifndef SH_STANDALONE
+int sh_xfer_set_strip (const char * str);
+#endif
+
+/* generate a random password
+ */
+int sh_xfer_create_password (const char * dummy);
+
+/* set timeout for active client connections
+ */
+int sh_xfer_set_timeout (const char * c);
+
+/* set time limit after which client is reported dead 
+ */
+int sh_xfer_set_time_limit(const char * str);
+
+/* error level for lookup failure
+ */
+int sh_xfer_lookup_level (const char * c);
+
+/* create client entry for given password
+ */
+int sh_xfer_make_client (const char * str);
+
+/* set port to which we connect
+ */
+int sh_xfer_server_port (const char * str);
+
+#ifdef SH_WITH_SERVER
+
+#ifdef INET_SYSLOG
+int set_syslog_active(const char * c);
+#endif
+
+/* create socket and start listening
+ */
+void create_server_tcp_socket (void);
+
+/* whether to use client address as known to the communication layer
+ * and set by accept()
+ */
+int set_socket_peer (const char * c);
+
+/* whether to use client severity
+ */
+int sh_xfer_use_clt_sev (const char * c);
+
+/* whether to use client class
+ */
+int sh_xfer_use_clt_class (const char * c);
+
+/* server port
+ */
+int sh_xfer_set_port(const char * c);
+
+/* server interface
+ */
+int sh_xfer_set_interface(const char * c);
+
+/* a wrapper function
+ */
+void sh_xfer_html_write(void);
+
+/* register a client
+ */
+int sh_xfer_register_client (const char * str);
+
+/* start server
+ */
+void sh_xfer_start_server(void);
+
+/* free() everything
+ */
+void sh_xfer_free_all (void);
+
+#endif
+
+#if defined(SH_WITH_CLIENT) || defined(SH_WITH_SERVER)
+/* talk to server
+ */
+long  sh_xfer_report (char * errmsg);
+
+/* set log server
+ */
+int sh_xfer_set_logserver (const char * address);
+void reset_count_dev_server(void);
+#endif
+
+#ifdef SH_WITH_CLIENT
+
+/* Throttle file download
+ */
+int sh_xfer_set_throttle_delay (const char * c);
+
+/* request file from server. file may be "CONF" or "DATA" or a UUID.
+ */
+long sh_xfer_request_file (const char * file);
+
+#endif
+
+#endif
+
Index: trunk/include/slib.h
===================================================================
--- trunk/include/slib.h	(revision 459)
+++ trunk/include/slib.h	(revision 481)
@@ -60,6 +60,8 @@
  * TRUE, FALSE
  */
-#define SL_TRUE  1
-#define SL_FALSE 0
+#if !defined(S_TRUE)
+#define S_TRUE  1
+#define S_FALSE 0
+#endif
 
 #define SH_GRBUF_SIZE   4096
