Reconstruction of des.exe/undes.exe

This commit is contained in:
2026-09-09 23:28:46 +02:00
parent b90136f137
commit 5aa37bf374
64 changed files with 13344 additions and 2 deletions
+37
View File
@@ -0,0 +1,37 @@
#ifndef DES_COMMON_H
#define DES_COMMON_H
#include <stdio.h>
#include "crypt.h"
/*
* Types which have the same width as Turbo C 2.x int/long when this source
* is inspected or built on a modern compiler.
*/
#ifdef __TURBOC__
typedef int DES_INT16;
typedef unsigned int DES_UINT16;
typedef long DES_INT32;
#else
#include <stdint.h>
typedef int16_t DES_INT16;
typedef uint16_t DES_UINT16;
typedef int32_t DES_INT32;
#endif
#define DES_BUFFER_SIZE 0x4000
#define DES_PREFIX_SIZE 8
#define DES_PAYLOAD_SIZE ( DES_BUFFER_SIZE - DES_PREFIX_SIZE )
#define DES_FILE_VERSION ((DES_INT32) 0x2775L)
extern DES_INT32 desKnownVersions[];
extern const char *desProgramVersion;
extern const char *desCopyrightText;
void checkRead( int result );
void checkWrite( FILE *stream );
void checkOpen( FILE *stream, const char *name );
void checkVersion( DES_INT32 version );
DES_INT32 negativeMarker( const unsigned char *p );
#endif