New upstream version 6.0.24.42
This commit is contained in:
parent
766bbe358d
commit
6dfe32758e
12
ARDOP.c
12
ARDOP.c
|
@ -880,6 +880,17 @@ static size_t ExtProc(int fn, int port, PDATAMESSAGE buff)
|
|||
}
|
||||
}
|
||||
|
||||
// Check ATTACH time limit
|
||||
|
||||
if (STREAM->Attached)
|
||||
{
|
||||
if (STREAM->AttachTime && TNC->AttachTimeLimit && time(NULL) > (TNC->AttachTimeLimit + STREAM->AttachTime))
|
||||
{
|
||||
STREAM->ReportDISC = 1;
|
||||
STREAM->AttachTime = 0;
|
||||
}
|
||||
}
|
||||
|
||||
if (TNC->ARDOPCommsMode != 'T') // S I or E
|
||||
{
|
||||
ARDOPSCSCheckRX(TNC);
|
||||
|
@ -1190,6 +1201,7 @@ static size_t ExtProc(int fn, int port, PDATAMESSAGE buff)
|
|||
Debugprintf("ARDOP New Attach Stream %d DEDStream %d", Stream, STREAM->DEDStream);
|
||||
|
||||
STREAM->Attached = TRUE;
|
||||
STREAM->AttachTime = time(NULL);
|
||||
|
||||
calllen = ConvFromAX25(TNC->PortRecord->ATTACHEDSESSIONS[Stream]->L4USER, TNC->Streams[Stream].MyCall);
|
||||
TNC->Streams[Stream].MyCall[calllen] = 0;
|
||||
|
|
456
BBSUtilities.c
456
BBSUtilities.c
|
@ -11762,300 +11762,258 @@ BOOL CheckforMIME(SocketConn * sockptr, char * Msg, char ** Body, int * MsgLen);
|
|||
#include <sys/wait.h>
|
||||
#include <signal.h>
|
||||
|
||||
typedef struct _POPENRET
|
||||
{
|
||||
FILE * fp;
|
||||
pid_t pid;
|
||||
} POPENRET;
|
||||
// G8BPQ Version of Steve G7TAJ's code
|
||||
|
||||
/*
|
||||
* Check if the PG is still running after 5 sec
|
||||
* if so, kill it
|
||||
int pgret = 9999;
|
||||
int pindex = 0;
|
||||
|
||||
void sigchild_handler(int sig , siginfo_t * siginfo, void * ucontext)
|
||||
{
|
||||
/* • SIGCHLD fills in si_pid, si_uid, si_status, si_utime, and
|
||||
si_stime, providing information about the child. The si_pid
|
||||
field is the process ID of the child; si_uid is the child's
|
||||
real user ID. The si_status field contains the exit status of
|
||||
the child (if si_code is CLD_EXITED), or the signal number
|
||||
that caused the process to change state.
|
||||
*/
|
||||
void run_pgTimeoutThread( pid_t process )
|
||||
{
|
||||
// printf("watchdog thread: PID of subprocess: %d\n", process);
|
||||
// fflush(stdout);
|
||||
Sleep(5000);
|
||||
// if still running PID (?) then kill.
|
||||
if ( getpgid(process) >= 0 )
|
||||
{
|
||||
Debugprintf("watchdog thread: Still running, so killing %d ... ", process);
|
||||
if ( kill( -process, SIGKILL ) == 0 )
|
||||
Debugprintf("Killed PG watchdog Process %d", process);
|
||||
else
|
||||
Debugprintf("Failed to kill PG watchdog Process %d", process);
|
||||
}
|
||||
|
||||
// Debugprintf("watchdog thread: PID=%d Exit", process);
|
||||
// fflush(stdout);
|
||||
// printf("SIGCHLD PID %d Code %d status %d\n", siginfo->si_pid, siginfo->si_code, siginfo->si_status);
|
||||
pgret = siginfo->si_status;
|
||||
}
|
||||
|
||||
|
||||
//https://sources.debian.org/src/cron/3.0pl1-45/popen.c/
|
||||
|
||||
POPENRET my_popen(char *program, char *type, CIRCUIT *conn)
|
||||
void run_pg(CIRCUIT * conn, struct UserInfo * user)
|
||||
{
|
||||
register char *cp;
|
||||
FILE *iop;
|
||||
int argc, pdes[2];
|
||||
pid_t pid;
|
||||
POPENRET PRET;
|
||||
|
||||
if (*type != 'r' && *type != 'w' || type[1])
|
||||
return(PRET);
|
||||
if (pipe(pdes) < 0)
|
||||
return(PRET);
|
||||
pgret = 9999;
|
||||
|
||||
int index = user->Temp->PG_INDEX;
|
||||
|
||||
iop = NULL;
|
||||
switch(pid = fork()) {
|
||||
|
||||
conn->InputBuffer[conn->InputLen] = 0;
|
||||
strlop(conn->InputBuffer, 13);
|
||||
conn->InputLen = 0;
|
||||
|
||||
if (!user->Temp->RUNPGPARAMS)
|
||||
user->Temp->RUNPGPARAMS = (RUNPGARGS_PTR) zalloc(sizeof(RUNPGARGS));
|
||||
|
||||
user->Temp->RUNPGPARAMS->user = user;
|
||||
user->Temp->RUNPGPARAMS->conn = conn;
|
||||
strncpy(user->Temp->RUNPGPARAMS->InputBuffer, conn->InputBuffer, 80); // needs to be length of actual input!
|
||||
user->Temp->RUNPGPARAMS->Len = conn->InputLen;
|
||||
|
||||
if (conn == 0 || user == 0)
|
||||
{
|
||||
Debugprintf("run_pg conn or user null");
|
||||
return;
|
||||
}
|
||||
|
||||
// Build command line. Parmas are:
|
||||
|
||||
// - Callsign (format as F6FBB-8).
|
||||
// - Level number (0 is the first time, up to 99).
|
||||
// - Flags of the user (binary number as user`s mask of INIT.SRV).
|
||||
// - Record number of the user in INF.SYS.
|
||||
// - Received data (each word is a new argument).
|
||||
|
||||
// BPQ doesn't support params 3 and 4 (but may supply copy of user record later)
|
||||
|
||||
char cmd[20];
|
||||
char *ptr = cmd;
|
||||
char pg_dir[MAX_PATH];
|
||||
char log_file[50] = "pg.log";
|
||||
char call[10];
|
||||
char data[80];
|
||||
char line[80];
|
||||
size_t bufsize = 80;
|
||||
|
||||
strcpy(pg_dir, BaseDir);
|
||||
strcat(pg_dir, "/PG/");
|
||||
sprintf(cmd, "./%s", SERVERLIST[user->Temp->PG_SERVER][1] );
|
||||
|
||||
sprintf(line, "%s%s", pg_dir, SERVERLIST[user->Temp->PG_SERVER][1]);
|
||||
// printf("PG Prog %s%s\n", pg_dir, SERVERLIST[user->Temp->PG_SERVER][1]);
|
||||
|
||||
// check file exists and is executable
|
||||
|
||||
if (access(line, F_OK) == -1 || access(line, X_OK) == -1)
|
||||
{
|
||||
Debugprintf("%s FileNotFound || not executable", line);
|
||||
BBSputs(conn, "Error running PG Server\r");
|
||||
conn->InputMode=0;
|
||||
SendPrompt(conn, user);
|
||||
return;
|
||||
}
|
||||
|
||||
strcpy(call, conn->UserPointer->Call);
|
||||
index = user->Temp->PG_INDEX;
|
||||
|
||||
// remove ';' from input for security reasons
|
||||
|
||||
ptr = strchr(user->Temp->RUNPGPARAMS->InputBuffer, ';');
|
||||
if (ptr)
|
||||
*ptr = '\0';
|
||||
|
||||
sprintf(data, "%s %d 0 0 %s", call, index, user->Temp->RUNPGPARAMS->InputBuffer);
|
||||
// printf("PG Params %s\n", data);
|
||||
|
||||
conn->InputBufferLen = 0;
|
||||
|
||||
char buf[256];
|
||||
|
||||
sprintf (buf, "%s %s", line, data); // buf is command to exec
|
||||
// printf ("PG exec cmd %s\n", buf);
|
||||
|
||||
// Create pipe for reading PG program STDOUT
|
||||
|
||||
if (pipe(pdes) < 0)
|
||||
{
|
||||
Debugprintf("run_pg pipe failed");
|
||||
BBSputs(conn, "Error running PG Server (pipe() failed)\r");
|
||||
conn->InputMode=0;
|
||||
SendPrompt(conn, user);
|
||||
return;
|
||||
}
|
||||
|
||||
// We will just fork and execute program. For now don't create a new thread
|
||||
|
||||
// Trap sigchild so we can tell when it exits and get return code
|
||||
|
||||
struct sigaction act;
|
||||
memset(&act, 0, sizeof(struct sigaction));
|
||||
act.sa_flags = SA_RESETHAND | SA_SIGINFO; // Restore default handler when called
|
||||
act.sa_sigaction = sigchild_handler;
|
||||
sigaction(SIGCHLD, &act, NULL);
|
||||
|
||||
switch(pid = fork())
|
||||
{
|
||||
case -1: /* error */
|
||||
(void)close(pdes[0]);
|
||||
(void)close(pdes[1]);
|
||||
return PRET;
|
||||
Debugprintf("run_pg fork failed");
|
||||
BBSputs(conn, "Error running PG Server (fork() failed)\r");
|
||||
conn->InputMode=0;
|
||||
SendPrompt(conn, user);
|
||||
|
||||
return;
|
||||
|
||||
case 0: /* child */
|
||||
if (*type == 'r') {
|
||||
if (pdes[1] != 1) {
|
||||
dup2(pdes[1], 1);
|
||||
dup2(pdes[1], 2);
|
||||
(void)close(pdes[1]);
|
||||
}
|
||||
(void)close(pdes[0]);
|
||||
} else {
|
||||
if (pdes[0] != 0) {
|
||||
dup2(pdes[0], 0);
|
||||
(void)close(pdes[0]);
|
||||
}
|
||||
|
||||
if (pdes[1] != 1)
|
||||
{
|
||||
dup2(pdes[1], 1);
|
||||
dup2(pdes[1], 2);
|
||||
(void)close(pdes[1]);
|
||||
}
|
||||
setpgid(-pid,pid);
|
||||
char *args[] = {"sh", "-c", program, NULL};
|
||||
execve("/bin/sh", args, NULL);
|
||||
(void)close(pdes[0]);
|
||||
|
||||
setpgid(0, pid);
|
||||
|
||||
char *args[] = {"sh", "-c", buf, NULL};
|
||||
execve("/bin/sh", args, NULL);
|
||||
|
||||
_exit(1);
|
||||
}
|
||||
|
||||
/* parent */
|
||||
|
||||
_beginthread((void (*)(void *))run_pgTimeoutThread, 0, (VOID *) pid );
|
||||
// printf("child PID %d\n", pid);
|
||||
|
||||
if (*type == 'r') {
|
||||
iop = fdopen(pdes[0], type);
|
||||
(void)close(pdes[1]);
|
||||
} else {
|
||||
iop = fdopen(pdes[1], type);
|
||||
(void)close(pdes[0]);
|
||||
struct timespec duration;
|
||||
duration.tv_sec = 5;
|
||||
duration.tv_nsec = 0;
|
||||
|
||||
nanosleep(&duration, &duration); // Will be interrupted by SIGCHLD
|
||||
|
||||
// printf("PG retcode %d\n", pgret);
|
||||
|
||||
if (pgret == 9999) // Process still running
|
||||
{
|
||||
BBSputs(conn, "PG Program Looping\r");
|
||||
kill(pid, SIGKILL);
|
||||
user->Temp->PG_INDEX = 0;
|
||||
conn->InputMode=0;
|
||||
SendPrompt(conn, user);
|
||||
return;
|
||||
}
|
||||
|
||||
if (pgret > 127)
|
||||
{
|
||||
// Probably killed by signal
|
||||
|
||||
int err = pgret - 128;
|
||||
char errmsg[256];
|
||||
|
||||
sprintf(errmsg, "PG Signal %s received\n", strsignal(err));
|
||||
|
||||
BBSputs(conn, errmsg);
|
||||
user->Temp->PG_INDEX = 0;
|
||||
conn->InputMode=0;
|
||||
SendPrompt(conn, user);
|
||||
return;
|
||||
}
|
||||
|
||||
// Send STDOUT from PG program to BBS user
|
||||
|
||||
iop = fdopen(pdes[0], "r");
|
||||
(void)close(pdes[1]);
|
||||
|
||||
char buffer[128];
|
||||
while (fgets(buffer, sizeof(buffer), iop) != NULL)
|
||||
{
|
||||
BBSputs(conn, buffer);
|
||||
buffer[0] = '\0';
|
||||
}
|
||||
PRET.fp = iop;
|
||||
PRET.pid= pid;
|
||||
|
||||
return(PRET);
|
||||
}
|
||||
|
||||
int
|
||||
my_pclose( POPENRET pret )
|
||||
{
|
||||
register int fdes;
|
||||
sigset_t omask, mask;
|
||||
int stat_loc;
|
||||
pid_t pid;
|
||||
FILE * iop = pret.fp;
|
||||
|
||||
fdes = fileno(iop);
|
||||
(void)fclose(iop);
|
||||
|
||||
sigemptyset(&mask);
|
||||
sigaddset(&mask, SIGQUIT);
|
||||
sigaddset(&mask, SIGINT);
|
||||
sigaddset(&mask, SIGHUP);
|
||||
sigprocmask(SIG_BLOCK, &mask, &omask);
|
||||
pid = waitpid(pret.pid, &stat_loc, 0);
|
||||
sigprocmask(SIG_SETMASK, &omask, NULL);
|
||||
if (pid == -1 || !WIFEXITED(stat_loc))
|
||||
return -1;
|
||||
return stat_loc;
|
||||
}
|
||||
|
||||
|
||||
int run_server (char **cmd, int nb_cmd, int mode, char *log, char *pgdir, char *data, CIRCUIT * conn)
|
||||
{
|
||||
int i;
|
||||
int ret = 0;
|
||||
FILE *fp;
|
||||
POPENRET PRET;
|
||||
pid_t pid;
|
||||
char *ptr;
|
||||
char file[256];
|
||||
char buf[256];
|
||||
char dir[256];
|
||||
char arg[256];
|
||||
|
||||
if (mode)
|
||||
// sprintf (file, " >>%s", log);
|
||||
// sprintf (file, " | tee -a %s", log);
|
||||
sprintf(file, "" );
|
||||
else
|
||||
sprintf (file, " </dev/null");
|
||||
|
||||
if (pgdir)
|
||||
switch (pgret)
|
||||
{
|
||||
/* remove ';' security reasons */
|
||||
ptr = strchr(pgdir, ';');
|
||||
if (ptr)
|
||||
*ptr = '\0';
|
||||
case -1: // ERROR or forced closed
|
||||
case 0:
|
||||
index=0; // Goodbye/Exit
|
||||
conn->InputMode=0;
|
||||
SendPrompt(conn, user);
|
||||
break;
|
||||
case 1:
|
||||
index++; // inc & keep in PG
|
||||
break;
|
||||
|
||||
sprintf (dir, "cd %s ; ", pgdir);
|
||||
}
|
||||
else
|
||||
*dir = '\0';
|
||||
case 2:
|
||||
|
||||
index=0; // disconnect
|
||||
conn->InputMode=0;
|
||||
Disconnect(conn->BPQStream);
|
||||
break;
|
||||
|
||||
*arg = '\0';
|
||||
case 3:
|
||||
Debugprintf("data->BBS & end");
|
||||
break;
|
||||
|
||||
if (data)
|
||||
{
|
||||
/* remove ';' security reasons */
|
||||
ptr = strchr(data, ';');
|
||||
if (ptr)
|
||||
*ptr = '\0';
|
||||
case 4:
|
||||
Debugprintf("data->BBS and inc %d", pindex++);
|
||||
break;
|
||||
case 5:
|
||||
Debugprintf("call no inc %d", pgret);
|
||||
break;
|
||||
|
||||
sprintf (arg, " %s ", data);
|
||||
}
|
||||
|
||||
|
||||
for (i = 0; i < nb_cmd; i++)
|
||||
{
|
||||
/* remove ';' security reasons */
|
||||
ptr = strchr(cmd[i], ';');
|
||||
if (ptr)
|
||||
*ptr = '\0';
|
||||
|
||||
sprintf (buf, "%s%s%s%s", dir, cmd[i], arg, file);
|
||||
|
||||
PRET = my_popen (buf, "r", conn);
|
||||
|
||||
if (PRET.fp == NULL)
|
||||
Debugprintf ("Failed to run PG command %s\n", cmd[i] );
|
||||
|
||||
ret = my_pclose( PRET );
|
||||
ret = ret >> 8;
|
||||
|
||||
if (verbose) {
|
||||
Debugprintf ("Debug: command = {%s}\n", buf);
|
||||
Debugprintf ("Debug: exit code = %d\n", ret);
|
||||
}
|
||||
|
||||
/* fail-safe bypass if executable isn't found (exit code 127) (was ret ==127)*/
|
||||
if (ret > 5) // should never be more than 5
|
||||
ret = 0;
|
||||
}
|
||||
return ( ret );
|
||||
}
|
||||
|
||||
|
||||
void run_pg( CIRCUIT * conn, struct UserInfo * user )
|
||||
{
|
||||
|
||||
if (!user->Temp->RUNPGPARAMS) {
|
||||
user->Temp->RUNPGPARAMS = (RUNPGARGS_PTR) zalloc(sizeof(RUNPGARGS));
|
||||
}
|
||||
|
||||
user->Temp->RUNPGPARAMS->user = user;
|
||||
user->Temp->RUNPGPARAMS->conn = conn;
|
||||
strncpy(user->Temp->RUNPGPARAMS->InputBuffer, conn->InputBuffer, 80); // needs to be length of actual input!
|
||||
user->Temp->RUNPGPARAMS->Len = conn->InputLen;
|
||||
|
||||
if ( conn == 0 || user == 0 ) {
|
||||
Debugprintf("run_pg null err");
|
||||
return;
|
||||
}
|
||||
|
||||
_beginthread((void (*)(void *))startrun_pgThread, 0, user->Temp->RUNPGPARAMS );
|
||||
|
||||
return;
|
||||
}
|
||||
|
||||
|
||||
void startrun_pgThread( RUNPGARGS_PTR Args ) {
|
||||
|
||||
CIRCUIT * conn = Args->conn;
|
||||
struct UserInfo * user = Args->user;
|
||||
|
||||
char cmd[20];
|
||||
sprintf( cmd, "./%s", SERVERLIST[user->Temp->PG_SERVER][1] );
|
||||
char *ptr = cmd;
|
||||
char pg_dir[MAX_PATH];
|
||||
char log_file[50] = "pg.log";
|
||||
char call[6];
|
||||
char data[80];
|
||||
char line[80];
|
||||
char *line_ptr = line;
|
||||
int index;
|
||||
char *data_ptr = data;
|
||||
size_t bufsize = 80;
|
||||
|
||||
strcpy(pg_dir, BaseDir);
|
||||
strcat(pg_dir, "/PG/");
|
||||
|
||||
sprintf(line, "%s%s", pg_dir, SERVERLIST[user->Temp->PG_SERVER][1]);
|
||||
|
||||
// check file exists and is executable
|
||||
if (access(line, F_OK) == -1 || access(line, X_OK) == -1) {
|
||||
Debugprintf("%s FileNotFound || Not EXE", line);
|
||||
BBSputs(conn, "Error running PG Server\r");
|
||||
default:
|
||||
BBSputs(conn, "PG unexexpected response\r");
|
||||
user->Temp->PG_INDEX = 0;
|
||||
conn->InputMode=0;
|
||||
SendPrompt(conn, user);
|
||||
return;
|
||||
}
|
||||
|
||||
|
||||
strcpy( call, conn->UserPointer->Call);
|
||||
// sprintf( log_file, "%s-%d.log", call, conn);
|
||||
index = user->Temp->PG_INDEX;
|
||||
user->Temp->PG_INDEX = index;
|
||||
|
||||
line[0] = '\0';
|
||||
int Len = Args->Len;
|
||||
UCHAR * Msg = Args->InputBuffer;
|
||||
strncpy( line, Msg, Len);
|
||||
line[ Len - 1 ] = 0; //remove LF
|
||||
|
||||
sprintf( data, "%s %d 0 0 %s", call, index, line);
|
||||
|
||||
// clear the input queue
|
||||
conn->InputLen = 0;
|
||||
conn->InputBufferLen = 0;
|
||||
|
||||
int ret = run_server (&ptr, 1, 1, log_file, pg_dir, data_ptr, conn);
|
||||
|
||||
switch (ret)
|
||||
{
|
||||
case -1: // ERROR or forced closed
|
||||
case 0: index=0; // Goodbye/Exit
|
||||
conn->InputMode=0;
|
||||
SendPrompt(conn, user);
|
||||
break;
|
||||
case 1: index++; // inc & keep in PG
|
||||
break;
|
||||
case 2: index=0; // disconnect
|
||||
conn->InputMode=0;
|
||||
Disconnect(conn->BPQStream);
|
||||
break;
|
||||
case 3: Debugprintf("data->BBS & end");
|
||||
break;
|
||||
case 4: Debugprintf("data->BBS and inc %d", index++);
|
||||
break;
|
||||
case 5: Debugprintf("call no inc %d", ret);
|
||||
break;
|
||||
|
||||
}
|
||||
|
||||
user->Temp->PG_INDEX=index;
|
||||
// printf("runpg return index = %d\n", index);
|
||||
}
|
||||
|
||||
|
||||
/*---- G7TAJ END ----- */
|
||||
|
||||
#else
|
||||
|
@ -12076,7 +12034,7 @@ void ReadFromPipe(void);
|
|||
|
||||
void run_pg( CIRCUIT * conn, struct UserInfo * user )
|
||||
{
|
||||
// Run PG program, rend anything from program's stdout to the user
|
||||
// Run PG program, read anything from program's stdout to the user
|
||||
|
||||
int retcode = -1;
|
||||
SECURITY_ATTRIBUTES saAttr;
|
||||
|
@ -12251,7 +12209,7 @@ void run_pg( CIRCUIT * conn, struct UserInfo * user )
|
|||
|
||||
case 4:
|
||||
|
||||
// Send Output to BBS - was down above
|
||||
// Send Output to BBS - was done above
|
||||
break;
|
||||
|
||||
case 5:
|
||||
|
|
|
@ -0,0 +1,65 @@
|
|||
<?xml version="1.0" encoding="Windows-1252"?>
|
||||
<VisualStudioUserFile
|
||||
ProjectType="Visual C++"
|
||||
Version="8.00"
|
||||
ShowAllFiles="false"
|
||||
>
|
||||
<Configurations>
|
||||
<Configuration
|
||||
Name="Debug|Win32"
|
||||
>
|
||||
<DebugSettings
|
||||
Command="$(TargetPath)"
|
||||
WorkingDirectory=""
|
||||
CommandArguments=""
|
||||
Attach="false"
|
||||
DebuggerType="3"
|
||||
Remote="1"
|
||||
RemoteMachine="NOTTSDESKTOP"
|
||||
RemoteCommand=""
|
||||
HttpUrl=""
|
||||
PDBPath=""
|
||||
SQLDebugging=""
|
||||
Environment=""
|
||||
EnvironmentMerge="true"
|
||||
DebuggerFlavor=""
|
||||
MPIRunCommand=""
|
||||
MPIRunArguments=""
|
||||
MPIRunWorkingDirectory=""
|
||||
ApplicationCommand=""
|
||||
ApplicationArguments=""
|
||||
ShimCommand=""
|
||||
MPIAcceptMode=""
|
||||
MPIAcceptFilter=""
|
||||
/>
|
||||
</Configuration>
|
||||
<Configuration
|
||||
Name="Release|Win32"
|
||||
>
|
||||
<DebugSettings
|
||||
Command="$(TargetPath)"
|
||||
WorkingDirectory=""
|
||||
CommandArguments=""
|
||||
Attach="false"
|
||||
DebuggerType="3"
|
||||
Remote="1"
|
||||
RemoteMachine="NOTTSDESKTOP"
|
||||
RemoteCommand=""
|
||||
HttpUrl=""
|
||||
PDBPath=""
|
||||
SQLDebugging=""
|
||||
Environment=""
|
||||
EnvironmentMerge="true"
|
||||
DebuggerFlavor=""
|
||||
MPIRunCommand=""
|
||||
MPIRunArguments=""
|
||||
MPIRunWorkingDirectory=""
|
||||
ApplicationCommand=""
|
||||
ApplicationArguments=""
|
||||
ShimCommand=""
|
||||
MPIAcceptMode=""
|
||||
MPIAcceptFilter=""
|
||||
/>
|
||||
</Configuration>
|
||||
</Configurations>
|
||||
</VisualStudioUserFile>
|
|
@ -1137,6 +1137,7 @@
|
|||
// Improve "New User" frequency determination (39)
|
||||
// Allow selection of 2 or 4 character country codes for forward processing (39)
|
||||
// Fix Send P to multiple BBS's when routing on HR (40)
|
||||
// Rewrite PG server code on Lunux (41)
|
||||
|
||||
#include "bpqmail.h"
|
||||
#include "winstdint.h"
|
||||
|
|
|
@ -0,0 +1,65 @@
|
|||
<?xml version="1.0" encoding="Windows-1252"?>
|
||||
<VisualStudioUserFile
|
||||
ProjectType="Visual C++"
|
||||
Version="8.00"
|
||||
ShowAllFiles="false"
|
||||
>
|
||||
<Configurations>
|
||||
<Configuration
|
||||
Name="Debug|Win32"
|
||||
>
|
||||
<DebugSettings
|
||||
Command="$(TargetPath)"
|
||||
WorkingDirectory=""
|
||||
CommandArguments=""
|
||||
Attach="false"
|
||||
DebuggerType="3"
|
||||
Remote="1"
|
||||
RemoteMachine="NOTTSDESKTOP"
|
||||
RemoteCommand=""
|
||||
HttpUrl=""
|
||||
PDBPath=""
|
||||
SQLDebugging=""
|
||||
Environment=""
|
||||
EnvironmentMerge="true"
|
||||
DebuggerFlavor=""
|
||||
MPIRunCommand=""
|
||||
MPIRunArguments=""
|
||||
MPIRunWorkingDirectory=""
|
||||
ApplicationCommand=""
|
||||
ApplicationArguments=""
|
||||
ShimCommand=""
|
||||
MPIAcceptMode=""
|
||||
MPIAcceptFilter=""
|
||||
/>
|
||||
</Configuration>
|
||||
<Configuration
|
||||
Name="Release|Win32"
|
||||
>
|
||||
<DebugSettings
|
||||
Command="$(TargetPath)"
|
||||
WorkingDirectory=""
|
||||
CommandArguments=""
|
||||
Attach="false"
|
||||
DebuggerType="3"
|
||||
Remote="1"
|
||||
RemoteMachine="NOTTSDESKTOP"
|
||||
RemoteCommand=""
|
||||
HttpUrl=""
|
||||
PDBPath=""
|
||||
SQLDebugging=""
|
||||
Environment=""
|
||||
EnvironmentMerge="true"
|
||||
DebuggerFlavor=""
|
||||
MPIRunCommand=""
|
||||
MPIRunArguments=""
|
||||
MPIRunWorkingDirectory=""
|
||||
ApplicationCommand=""
|
||||
ApplicationArguments=""
|
||||
ShimCommand=""
|
||||
MPIAcceptMode=""
|
||||
MPIAcceptFilter=""
|
||||
/>
|
||||
</Configuration>
|
||||
</Configurations>
|
||||
</VisualStudioUserFile>
|
|
@ -0,0 +1,65 @@
|
|||
<?xml version="1.0" encoding="Windows-1252"?>
|
||||
<VisualStudioUserFile
|
||||
ProjectType="Visual C++"
|
||||
Version="8.00"
|
||||
ShowAllFiles="false"
|
||||
>
|
||||
<Configurations>
|
||||
<Configuration
|
||||
Name="Debug|Win32"
|
||||
>
|
||||
<DebugSettings
|
||||
Command="$(TargetPath)"
|
||||
WorkingDirectory=""
|
||||
CommandArguments=""
|
||||
Attach="false"
|
||||
DebuggerType="3"
|
||||
Remote="1"
|
||||
RemoteMachine="SKIGACER"
|
||||
RemoteCommand=""
|
||||
HttpUrl=""
|
||||
PDBPath=""
|
||||
SQLDebugging=""
|
||||
Environment=""
|
||||
EnvironmentMerge="true"
|
||||
DebuggerFlavor=""
|
||||
MPIRunCommand=""
|
||||
MPIRunArguments=""
|
||||
MPIRunWorkingDirectory=""
|
||||
ApplicationCommand=""
|
||||
ApplicationArguments=""
|
||||
ShimCommand=""
|
||||
MPIAcceptMode=""
|
||||
MPIAcceptFilter=""
|
||||
/>
|
||||
</Configuration>
|
||||
<Configuration
|
||||
Name="Release|Win32"
|
||||
>
|
||||
<DebugSettings
|
||||
Command="$(TargetPath)"
|
||||
WorkingDirectory=""
|
||||
CommandArguments=""
|
||||
Attach="false"
|
||||
DebuggerType="3"
|
||||
Remote="1"
|
||||
RemoteMachine="SKIGACER"
|
||||
RemoteCommand=""
|
||||
HttpUrl=""
|
||||
PDBPath=""
|
||||
SQLDebugging=""
|
||||
Environment=""
|
||||
EnvironmentMerge="true"
|
||||
DebuggerFlavor=""
|
||||
MPIRunCommand=""
|
||||
MPIRunArguments=""
|
||||
MPIRunWorkingDirectory=""
|
||||
ApplicationCommand=""
|
||||
ApplicationArguments=""
|
||||
ShimCommand=""
|
||||
MPIAcceptMode=""
|
||||
MPIAcceptFilter=""
|
||||
/>
|
||||
</Configuration>
|
||||
</Configurations>
|
||||
</VisualStudioUserFile>
|
|
@ -0,0 +1,65 @@
|
|||
<?xml version="1.0" encoding="Windows-1252"?>
|
||||
<VisualStudioUserFile
|
||||
ProjectType="Visual C++"
|
||||
Version="8.00"
|
||||
ShowAllFiles="false"
|
||||
>
|
||||
<Configurations>
|
||||
<Configuration
|
||||
Name="Debug|Win32"
|
||||
>
|
||||
<DebugSettings
|
||||
Command="$(TargetPath)"
|
||||
WorkingDirectory=""
|
||||
CommandArguments=""
|
||||
Attach="false"
|
||||
DebuggerType="3"
|
||||
Remote="1"
|
||||
RemoteMachine="LAPTOP-Q6S4RP5Q"
|
||||
RemoteCommand=""
|
||||
HttpUrl=""
|
||||
PDBPath=""
|
||||
SQLDebugging=""
|
||||
Environment=""
|
||||
EnvironmentMerge="true"
|
||||
DebuggerFlavor=""
|
||||
MPIRunCommand=""
|
||||
MPIRunArguments=""
|
||||
MPIRunWorkingDirectory=""
|
||||
ApplicationCommand=""
|
||||
ApplicationArguments=""
|
||||
ShimCommand=""
|
||||
MPIAcceptMode=""
|
||||
MPIAcceptFilter=""
|
||||
/>
|
||||
</Configuration>
|
||||
<Configuration
|
||||
Name="Release|Win32"
|
||||
>
|
||||
<DebugSettings
|
||||
Command="$(TargetPath)"
|
||||
WorkingDirectory=""
|
||||
CommandArguments=""
|
||||
Attach="false"
|
||||
DebuggerType="3"
|
||||
Remote="1"
|
||||
RemoteMachine="LAPTOP-Q6S4RP5Q"
|
||||
RemoteCommand=""
|
||||
HttpUrl=""
|
||||
PDBPath=""
|
||||
SQLDebugging=""
|
||||
Environment=""
|
||||
EnvironmentMerge="true"
|
||||
DebuggerFlavor=""
|
||||
MPIRunCommand=""
|
||||
MPIRunArguments=""
|
||||
MPIRunWorkingDirectory=""
|
||||
ApplicationCommand=""
|
||||
ApplicationArguments=""
|
||||
ShimCommand=""
|
||||
MPIAcceptMode=""
|
||||
MPIAcceptFilter=""
|
||||
/>
|
||||
</Configuration>
|
||||
</Configurations>
|
||||
</VisualStudioUserFile>
|
|
@ -0,0 +1,65 @@
|
|||
<?xml version="1.0" encoding="Windows-1252"?>
|
||||
<VisualStudioUserFile
|
||||
ProjectType="Visual C++"
|
||||
Version="8.00"
|
||||
ShowAllFiles="false"
|
||||
>
|
||||
<Configurations>
|
||||
<Configuration
|
||||
Name="Debug|Win32"
|
||||
>
|
||||
<DebugSettings
|
||||
Command="$(TargetPath)"
|
||||
WorkingDirectory=""
|
||||
CommandArguments=""
|
||||
Attach="false"
|
||||
DebuggerType="3"
|
||||
Remote="1"
|
||||
RemoteMachine="NOTTSDESKTOP"
|
||||
RemoteCommand=""
|
||||
HttpUrl=""
|
||||
PDBPath=""
|
||||
SQLDebugging=""
|
||||
Environment=""
|
||||
EnvironmentMerge="true"
|
||||
DebuggerFlavor=""
|
||||
MPIRunCommand=""
|
||||
MPIRunArguments=""
|
||||
MPIRunWorkingDirectory=""
|
||||
ApplicationCommand=""
|
||||
ApplicationArguments=""
|
||||
ShimCommand=""
|
||||
MPIAcceptMode=""
|
||||
MPIAcceptFilter=""
|
||||
/>
|
||||
</Configuration>
|
||||
<Configuration
|
||||
Name="Release|Win32"
|
||||
>
|
||||
<DebugSettings
|
||||
Command="$(TargetPath)"
|
||||
WorkingDirectory=""
|
||||
CommandArguments=""
|
||||
Attach="false"
|
||||
DebuggerType="3"
|
||||
Remote="1"
|
||||
RemoteMachine="NOTTSDESKTOP"
|
||||
RemoteCommand=""
|
||||
HttpUrl=""
|
||||
PDBPath=""
|
||||
SQLDebugging=""
|
||||
Environment=""
|
||||
EnvironmentMerge="true"
|
||||
DebuggerFlavor=""
|
||||
MPIRunCommand=""
|
||||
MPIRunArguments=""
|
||||
MPIRunWorkingDirectory=""
|
||||
ApplicationCommand=""
|
||||
ApplicationArguments=""
|
||||
ShimCommand=""
|
||||
MPIAcceptMode=""
|
||||
MPIAcceptFilter=""
|
||||
/>
|
||||
</Configuration>
|
||||
</Configurations>
|
||||
</VisualStudioUserFile>
|
7
Bpq32.c
7
Bpq32.c
|
@ -1219,6 +1219,9 @@ along with LinBPQ/BPQ32. If not, see http://www.gnu.org/licenses
|
|||
// Fix ICF8101 Mode setting (37)
|
||||
// Kill link if we are getting repeated RR(F) after timeout
|
||||
// (Indicating other station is seeing our RR(P) but not the resent I frame) (40)
|
||||
// Change default of SECURETELNET to 1 (41)
|
||||
// Add optional ATTACH time limit for ARDOP (42)
|
||||
// Fix buffer overflow risk in HTTP Terminal(42)
|
||||
|
||||
|
||||
|
||||
|
@ -1313,6 +1316,7 @@ void * KISSHFExtInit(EXTPORTDATA * PortEntry);
|
|||
void * WinRPRExtInit(EXTPORTDATA * PortEntry);
|
||||
void * HSMODEMExtInit(EXTPORTDATA * PortEntry);
|
||||
void * FreeDataExtInit(EXTPORTDATA * PortEntry);
|
||||
void * SIXPACKExtInit(EXTPORTDATA * PortEntry);
|
||||
|
||||
extern char * ConfigBuffer; // Config Area
|
||||
VOID REMOVENODE(dest_list * DEST);
|
||||
|
@ -3950,6 +3954,9 @@ VOID * InitializeExtDriver(PEXTPORTDATA PORTVEC)
|
|||
if (strstr(Value, "FREEDATA"))
|
||||
return FreeDataExtInit;
|
||||
|
||||
if (strstr(Value, "6PACK"))
|
||||
return SIXPACKExtInit;
|
||||
|
||||
ExtDriver = LoadLibrary(Value);
|
||||
|
||||
if (ExtDriver == NULL)
|
||||
|
|
|
@ -57,7 +57,7 @@
|
|||
UsePrecompiledHeader="0"
|
||||
AssemblerOutput="2"
|
||||
AssemblerListingLocation="c:\devprogs\bpq32\listings\debug\"
|
||||
BrowseInformation="0"
|
||||
BrowseInformation="1"
|
||||
WarningLevel="3"
|
||||
Detect64BitPortabilityProblems="false"
|
||||
DebugInformationFormat="4"
|
||||
|
@ -234,6 +234,10 @@
|
|||
Filter="cpp;c;cc;cxx;def;odl;idl;hpj;bat;asm;asmx"
|
||||
UniqueIdentifier="{4FC737F1-C7A5-4376-A066-2A32D752A2FF}"
|
||||
>
|
||||
<File
|
||||
RelativePath=".\6pack.c"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath="..\CommonSource\adif.c"
|
||||
>
|
||||
|
|
|
@ -0,0 +1,65 @@
|
|||
<?xml version="1.0" encoding="Windows-1252"?>
|
||||
<VisualStudioUserFile
|
||||
ProjectType="Visual C++"
|
||||
Version="8.00"
|
||||
ShowAllFiles="false"
|
||||
>
|
||||
<Configurations>
|
||||
<Configuration
|
||||
Name="Debug|Win32"
|
||||
>
|
||||
<DebugSettings
|
||||
Command="C:\Devprogs\BPQ32\bpq32.exe"
|
||||
WorkingDirectory=""
|
||||
CommandArguments=""
|
||||
Attach="false"
|
||||
DebuggerType="3"
|
||||
Remote="1"
|
||||
RemoteMachine="LAPTOP-Q6S4RP5Q"
|
||||
RemoteCommand=""
|
||||
HttpUrl=""
|
||||
PDBPath=""
|
||||
SQLDebugging=""
|
||||
Environment=""
|
||||
EnvironmentMerge="true"
|
||||
DebuggerFlavor=""
|
||||
MPIRunCommand=""
|
||||
MPIRunArguments=""
|
||||
MPIRunWorkingDirectory=""
|
||||
ApplicationCommand=""
|
||||
ApplicationArguments=""
|
||||
ShimCommand=""
|
||||
MPIAcceptMode=""
|
||||
MPIAcceptFilter=""
|
||||
/>
|
||||
</Configuration>
|
||||
<Configuration
|
||||
Name="Release|Win32"
|
||||
>
|
||||
<DebugSettings
|
||||
Command=""
|
||||
WorkingDirectory=""
|
||||
CommandArguments=""
|
||||
Attach="false"
|
||||
DebuggerType="3"
|
||||
Remote="1"
|
||||
RemoteMachine="LAPTOP-Q6S4RP5Q"
|
||||
RemoteCommand=""
|
||||
HttpUrl=""
|
||||
PDBPath=""
|
||||
SQLDebugging=""
|
||||
Environment=""
|
||||
EnvironmentMerge="true"
|
||||
DebuggerFlavor=""
|
||||
MPIRunCommand=""
|
||||
MPIRunArguments=""
|
||||
MPIRunWorkingDirectory=""
|
||||
ApplicationCommand=""
|
||||
ApplicationArguments=""
|
||||
ShimCommand=""
|
||||
MPIAcceptMode=""
|
||||
MPIAcceptFilter=""
|
||||
/>
|
||||
</Configuration>
|
||||
</Configurations>
|
||||
</VisualStudioUserFile>
|
|
@ -0,0 +1,65 @@
|
|||
<?xml version="1.0" encoding="Windows-1252"?>
|
||||
<VisualStudioUserFile
|
||||
ProjectType="Visual C++"
|
||||
Version="8.00"
|
||||
ShowAllFiles="false"
|
||||
>
|
||||
<Configurations>
|
||||
<Configuration
|
||||
Name="Debug|Win32"
|
||||
>
|
||||
<DebugSettings
|
||||
Command="C:\Devprogs\BPQ32\bpq32.exe"
|
||||
WorkingDirectory=""
|
||||
CommandArguments=""
|
||||
Attach="false"
|
||||
DebuggerType="3"
|
||||
Remote="1"
|
||||
RemoteMachine="NOTTSDESKTOP"
|
||||
RemoteCommand=""
|
||||
HttpUrl=""
|
||||
PDBPath=""
|
||||
SQLDebugging=""
|
||||
Environment=""
|
||||
EnvironmentMerge="true"
|
||||
DebuggerFlavor=""
|
||||
MPIRunCommand=""
|
||||
MPIRunArguments=""
|
||||
MPIRunWorkingDirectory=""
|
||||
ApplicationCommand=""
|
||||
ApplicationArguments=""
|
||||
ShimCommand=""
|
||||
MPIAcceptMode=""
|
||||
MPIAcceptFilter=""
|
||||
/>
|
||||
</Configuration>
|
||||
<Configuration
|
||||
Name="Release|Win32"
|
||||
>
|
||||
<DebugSettings
|
||||
Command="C:\Devprogs\BPQ32\bpq32.exe"
|
||||
WorkingDirectory=""
|
||||
CommandArguments=""
|
||||
Attach="false"
|
||||
DebuggerType="3"
|
||||
Remote="1"
|
||||
RemoteMachine="NOTTSDESKTOP"
|
||||
RemoteCommand=""
|
||||
HttpUrl=""
|
||||
PDBPath=""
|
||||
SQLDebugging=""
|
||||
Environment=""
|
||||
EnvironmentMerge="true"
|
||||
DebuggerFlavor=""
|
||||
MPIRunCommand=""
|
||||
MPIRunArguments=""
|
||||
MPIRunWorkingDirectory=""
|
||||
ApplicationCommand=""
|
||||
ApplicationArguments=""
|
||||
ShimCommand=""
|
||||
MPIAcceptMode=""
|
||||
MPIAcceptFilter=""
|
||||
/>
|
||||
</Configuration>
|
||||
</Configurations>
|
||||
</VisualStudioUserFile>
|
|
@ -0,0 +1,65 @@
|
|||
<?xml version="1.0" encoding="Windows-1252"?>
|
||||
<VisualStudioUserFile
|
||||
ProjectType="Visual C++"
|
||||
Version="8.00"
|
||||
ShowAllFiles="false"
|
||||
>
|
||||
<Configurations>
|
||||
<Configuration
|
||||
Name="Debug|Win32"
|
||||
>
|
||||
<DebugSettings
|
||||
Command="C:\DevProgs\BPQ32\bpq32.exe"
|
||||
WorkingDirectory=""
|
||||
CommandArguments=""
|
||||
Attach="false"
|
||||
DebuggerType="3"
|
||||
Remote="1"
|
||||
RemoteMachine="SKIGACER"
|
||||
RemoteCommand=""
|
||||
HttpUrl=""
|
||||
PDBPath=""
|
||||
SQLDebugging=""
|
||||
Environment=""
|
||||
EnvironmentMerge="true"
|
||||
DebuggerFlavor=""
|
||||
MPIRunCommand=""
|
||||
MPIRunArguments=""
|
||||
MPIRunWorkingDirectory=""
|
||||
ApplicationCommand=""
|
||||
ApplicationArguments=""
|
||||
ShimCommand=""
|
||||
MPIAcceptMode=""
|
||||
MPIAcceptFilter=""
|
||||
/>
|
||||
</Configuration>
|
||||
<Configuration
|
||||
Name="Release|Win32"
|
||||
>
|
||||
<DebugSettings
|
||||
Command=""
|
||||
WorkingDirectory=""
|
||||
CommandArguments=""
|
||||
Attach="false"
|
||||
DebuggerType="3"
|
||||
Remote="1"
|
||||
RemoteMachine="SKIGACER"
|
||||
RemoteCommand=""
|
||||
HttpUrl=""
|
||||
PDBPath=""
|
||||
SQLDebugging=""
|
||||
Environment=""
|
||||
EnvironmentMerge="true"
|
||||
DebuggerFlavor=""
|
||||
MPIRunCommand=""
|
||||
MPIRunArguments=""
|
||||
MPIRunWorkingDirectory=""
|
||||
ApplicationCommand=""
|
||||
ApplicationArguments=""
|
||||
ShimCommand=""
|
||||
MPIAcceptMode=""
|
||||
MPIAcceptFilter=""
|
||||
/>
|
||||
</Configuration>
|
||||
</Configurations>
|
||||
</VisualStudioUserFile>
|
16
CommonCode.c
16
CommonCode.c
|
@ -4859,7 +4859,6 @@ DllExport uint64_t APIENTRY GetPortFrequency(int PortNo, char * FreqString)
|
|||
|
||||
struct TNCINFO * TNC;
|
||||
struct RIGINFO * RIG = 0;
|
||||
int RigPort;
|
||||
|
||||
if (PORT->RIGPort)
|
||||
TNC = TNCInfo[PORT->RIGPort];
|
||||
|
@ -5089,6 +5088,8 @@ void BuildPortMH(char * MHJSON, struct PORTCONTROL * PORT)
|
|||
int len;
|
||||
char * ptr;
|
||||
char mhstr[400];
|
||||
int i;
|
||||
char c;
|
||||
|
||||
if (MH == NULL)
|
||||
return;
|
||||
|
@ -5110,7 +5111,16 @@ void BuildPortMH(char * MHJSON, struct PORTCONTROL * PORT)
|
|||
continue;
|
||||
}
|
||||
|
||||
Normcall[len++] = 0;
|
||||
// validate call to prevent corruption of json
|
||||
|
||||
for (i=0; i < len; i++)
|
||||
{
|
||||
c = Normcall[i];
|
||||
|
||||
if (!isalnum(c) && !(c == '#') && !(c == ' ') && !(c == '-'))
|
||||
goto skipit;
|
||||
}
|
||||
|
||||
|
||||
//format TIME
|
||||
|
||||
|
@ -5123,7 +5133,7 @@ void BuildPortMH(char * MHJSON, struct PORTCONTROL * PORT)
|
|||
Normcall, PORT->PORTNUMBER, MH->MHCOUNT, MHTIME);
|
||||
|
||||
strcat( MHJSON, mhstr );
|
||||
|
||||
skipit:
|
||||
MH++;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -1876,6 +1876,8 @@ int standardParams(struct TNCINFO * TNC, char * buf)
|
|||
TNC->WL2K = DecodeWL2KReportLine(buf);
|
||||
else if (_memicmp(buf, "SESSIONTIMELIMIT", 16) == 0)
|
||||
TNC->SessionTimeLimit = TNC->DefaultSessionTimeLimit = atoi(&buf[17]) * 60;
|
||||
else if (_memicmp(buf, "ATTACHTIMELIMIT", 15) == 0)
|
||||
TNC->AttachTimeLimit = atoi(&buf[16]) * 60;
|
||||
else if (_memicmp(buf, "BUSYHOLD", 8) == 0) // Hold Time for Busy Detect
|
||||
TNC->BusyHold = atoi(&buf[8]);
|
||||
else if (_memicmp(buf, "BUSYWAIT", 8) == 0) // Wait time before failing connect if busy
|
||||
|
|
19
HTTPcode.c
19
HTTPcode.c
|
@ -600,7 +600,8 @@ VOID HTTPTimer()
|
|||
|
||||
for (n = Last;;)
|
||||
{
|
||||
strcat(_REPLYBUFFER, Session->ScreenLines[n]);
|
||||
if ((strlen(Session->ScreenLines[n]) + strlen(_REPLYBUFFER)) < 99999)
|
||||
strcat(_REPLYBUFFER, Session->ScreenLines[n]);
|
||||
|
||||
if (n == 99)
|
||||
n = -1;
|
||||
|
@ -680,13 +681,15 @@ struct HTTPConnectionInfo * FindSession(char * Key)
|
|||
|
||||
void ProcessTermInput(SOCKET sock, char * MsgPtr, int MsgLen, char * Key)
|
||||
{
|
||||
char _REPLYBUFFER[1024];
|
||||
char _REPLYBUFFER[2048];
|
||||
int ReplyLen;
|
||||
char Header[256];
|
||||
int HeaderLen;
|
||||
int State;
|
||||
struct HTTPConnectionInfo * Session = FindSession(Key);
|
||||
int Stream;
|
||||
int maxlen = 1000;
|
||||
|
||||
|
||||
if (Session == NULL)
|
||||
{
|
||||
|
@ -701,12 +704,24 @@ void ProcessTermInput(SOCKET sock, char * MsgPtr, int MsgLen, char * Key)
|
|||
char c;
|
||||
UCHAR hex;
|
||||
|
||||
int msglen = end - input;
|
||||
|
||||
struct TNCINFO * TNC = Session->TNC;
|
||||
struct TCPINFO * TCP = 0;
|
||||
|
||||
if (TNC)
|
||||
TCP = TNC->TCPInfo;
|
||||
|
||||
if (TCP && TCP->WebTermCSS)
|
||||
maxlen -= strlen(TCP->WebTermCSS);
|
||||
|
||||
if (MsgLen > maxlen)
|
||||
{
|
||||
Session->KillTimer = 99999; // close session
|
||||
return;
|
||||
}
|
||||
|
||||
|
||||
if (TCP && TCP->WebTermCSS)
|
||||
ReplyLen = sprintf(_REPLYBUFFER, InputLine, Key, TCP->WebTermCSS);
|
||||
else
|
||||
|
|
323
LinBPQ.c
323
LinBPQ.c
|
@ -1077,216 +1077,211 @@ int main(int argc, char * argv[])
|
|||
|
||||
BBSApplMask = 1<<(BBSApplNum-1);
|
||||
|
||||
// See if we need to warn of possible problem with BaseDir moved by installer
|
||||
// See if we need to warn of possible problem with BaseDir moved by installer
|
||||
|
||||
sprintf(BaseDir, "%s", BPQDirectory);
|
||||
sprintf(BaseDir, "%s", BPQDirectory);
|
||||
|
||||
|
||||
// Set up file and directory names
|
||||
// Set up file and directory names
|
||||
|
||||
strcpy(UserDatabasePath, BaseDir);
|
||||
strcat(UserDatabasePath, "/");
|
||||
strcat(UserDatabasePath, UserDatabaseName);
|
||||
strcpy(UserDatabasePath, BaseDir);
|
||||
strcat(UserDatabasePath, "/");
|
||||
strcat(UserDatabasePath, UserDatabaseName);
|
||||
|
||||
strcpy(MsgDatabasePath, BaseDir);
|
||||
strcat(MsgDatabasePath, "/");
|
||||
strcat(MsgDatabasePath, MsgDatabaseName);
|
||||
strcpy(MsgDatabasePath, BaseDir);
|
||||
strcat(MsgDatabasePath, "/");
|
||||
strcat(MsgDatabasePath, MsgDatabaseName);
|
||||
|
||||
strcpy(BIDDatabasePath, BaseDir);
|
||||
strcat(BIDDatabasePath, "/");
|
||||
strcat(BIDDatabasePath, BIDDatabaseName);
|
||||
strcpy(BIDDatabasePath, BaseDir);
|
||||
strcat(BIDDatabasePath, "/");
|
||||
strcat(BIDDatabasePath, BIDDatabaseName);
|
||||
|
||||
strcpy(WPDatabasePath, BaseDir);
|
||||
strcat(WPDatabasePath, "/");
|
||||
strcat(WPDatabasePath, WPDatabaseName);
|
||||
strcpy(WPDatabasePath, BaseDir);
|
||||
strcat(WPDatabasePath, "/");
|
||||
strcat(WPDatabasePath, WPDatabaseName);
|
||||
|
||||
strcpy(BadWordsPath, BaseDir);
|
||||
strcat(BadWordsPath, "/");
|
||||
strcat(BadWordsPath, BadWordsName);
|
||||
strcpy(BadWordsPath, BaseDir);
|
||||
strcat(BadWordsPath, "/");
|
||||
strcat(BadWordsPath, BadWordsName);
|
||||
|
||||
strcpy(NTSAliasesPath, BaseDir);
|
||||
strcat(NTSAliasesPath, "/");
|
||||
strcat(NTSAliasesPath, NTSAliasesName);
|
||||
strcpy(NTSAliasesPath, BaseDir);
|
||||
strcat(NTSAliasesPath, "/");
|
||||
strcat(NTSAliasesPath, NTSAliasesName);
|
||||
|
||||
strcpy(MailDir, BaseDir);
|
||||
strcat(MailDir, "/");
|
||||
strcat(MailDir, "Mail");
|
||||
strcpy(MailDir, BaseDir);
|
||||
strcat(MailDir, "/");
|
||||
strcat(MailDir, "Mail");
|
||||
|
||||
#ifdef WIN32
|
||||
CreateDirectory(MailDir, NULL); // Just in case
|
||||
CreateDirectory(MailDir, NULL); // Just in case
|
||||
#else
|
||||
mkdir(MailDir, S_IRWXU | S_IRWXG | S_IRWXO);
|
||||
chmod(MailDir, S_IRWXU | S_IRWXG | S_IRWXO);
|
||||
mkdir(MailDir, S_IRWXU | S_IRWXG | S_IRWXO);
|
||||
chmod(MailDir, S_IRWXU | S_IRWXG | S_IRWXO);
|
||||
#endif
|
||||
|
||||
// Make backup copies of Databases
|
||||
// Make backup copies of Databases
|
||||
|
||||
// CopyConfigFile(ConfigName);
|
||||
// CopyConfigFile(ConfigName);
|
||||
|
||||
CopyBIDDatabase();
|
||||
CopyMessageDatabase();
|
||||
CopyUserDatabase();
|
||||
CopyWPDatabase();
|
||||
CopyBIDDatabase();
|
||||
CopyMessageDatabase();
|
||||
CopyUserDatabase();
|
||||
CopyWPDatabase();
|
||||
|
||||
SetupMyHA();
|
||||
SetupFwdAliases();
|
||||
SetupNTSAliases(NTSAliasesPath);
|
||||
SetupMyHA();
|
||||
SetupFwdAliases();
|
||||
SetupNTSAliases(NTSAliasesPath);
|
||||
|
||||
GetWPDatabase();
|
||||
GetWPDatabase();
|
||||
|
||||
GetMessageDatabase();
|
||||
GetUserDatabase();
|
||||
GetBIDDatabase();
|
||||
GetBadWordFile();
|
||||
GetHTMLForms();
|
||||
GetPGConfig();
|
||||
GetMessageDatabase();
|
||||
GetUserDatabase();
|
||||
GetBIDDatabase();
|
||||
GetBadWordFile();
|
||||
GetHTMLForms();
|
||||
GetPGConfig();
|
||||
|
||||
// Make sure there is a user record for the BBS, with BBS bit set.
|
||||
// Make sure there is a user record for the BBS, with BBS bit set.
|
||||
|
||||
user = LookupCall(BBSName);
|
||||
user = LookupCall(BBSName);
|
||||
|
||||
if (user == NULL)
|
||||
{
|
||||
user = AllocateUserRecord(BBSName);
|
||||
user->Temp = zalloc(sizeof (struct TempUserInfo));
|
||||
}
|
||||
|
||||
if ((user->flags & F_BBS) == 0)
|
||||
{
|
||||
// Not Defined as a BBS
|
||||
|
||||
if(SetupNewBBS(user))
|
||||
user->flags |= F_BBS;
|
||||
}
|
||||
|
||||
// if forwarding AMPR mail make sure User/BBS AMPR exists
|
||||
|
||||
if (SendAMPRDirect)
|
||||
{
|
||||
BOOL NeedSave = FALSE;
|
||||
|
||||
user = LookupCall("AMPR");
|
||||
|
||||
if (user == NULL)
|
||||
{
|
||||
user = AllocateUserRecord("AMPR");
|
||||
user = AllocateUserRecord(BBSName);
|
||||
user->Temp = zalloc(sizeof (struct TempUserInfo));
|
||||
NeedSave = TRUE;
|
||||
}
|
||||
|
||||
if ((user->flags & F_BBS) == 0)
|
||||
{
|
||||
// Not Defined as a BBS
|
||||
|
||||
if (SetupNewBBS(user))
|
||||
if(SetupNewBBS(user))
|
||||
user->flags |= F_BBS;
|
||||
NeedSave = TRUE;
|
||||
}
|
||||
|
||||
if (NeedSave)
|
||||
SaveUserDatabase();
|
||||
}
|
||||
// if forwarding AMPR mail make sure User/BBS AMPR exists
|
||||
|
||||
|
||||
// Make sure SYSOPCALL is set
|
||||
|
||||
if (SYSOPCall[0] == 0)
|
||||
strcpy(SYSOPCall, BBSName);
|
||||
|
||||
// See if just want to add user (mainly for setup scripts)
|
||||
|
||||
if (argc == 5 && _stricmp(argv[1], "--adduser") == 0)
|
||||
{
|
||||
BOOL isBBS = FALSE;
|
||||
char * response;
|
||||
|
||||
if (_stricmp(argv[4], "TRUE") == 0)
|
||||
isBBS = TRUE;
|
||||
|
||||
printf("Adding User %s\r\n", argv[2]);
|
||||
response = AddUser(argv[2], argv[3], isBBS);
|
||||
printf("%s", response);
|
||||
exit(0);
|
||||
}
|
||||
// Allocate Streams
|
||||
|
||||
strcpy(pgm, "BBS");
|
||||
|
||||
for (i=0; i < MaxStreams; i++)
|
||||
{
|
||||
conn = &Connections[i];
|
||||
conn->BPQStream = FindFreeStream();
|
||||
|
||||
if (conn->BPQStream == 255) break;
|
||||
|
||||
NumberofStreams++;
|
||||
|
||||
// BPQSetHandle(conn->BPQStream, hWnd);
|
||||
|
||||
SetAppl(conn->BPQStream, (i == 0 && EnableUI) ? 0x82 : 2, BBSApplMask);
|
||||
Disconnect(conn->BPQStream);
|
||||
}
|
||||
|
||||
strcpy(pgm, "LINBPQ");
|
||||
|
||||
Debugprintf("POP3 Debug Before Init TCP Timer = %d", POP3Timer);
|
||||
|
||||
InitialiseTCP();
|
||||
Debugprintf("POP3 Debug Before Init NNTP Timer = %d", POP3Timer);
|
||||
InitialiseNNTP();
|
||||
|
||||
SetupListenSet(); // Master set of listening sockets
|
||||
|
||||
if (EnableUI || MailForInterval)
|
||||
SetupUIInterface();
|
||||
|
||||
if (MailForInterval)
|
||||
_beginthread(SendMailForThread, 0, 0);
|
||||
|
||||
|
||||
// Calulate time to run Housekeeping
|
||||
{
|
||||
struct tm *tm;
|
||||
time_t now;
|
||||
|
||||
now = time(NULL);
|
||||
|
||||
tm = gmtime(&now);
|
||||
|
||||
tm->tm_hour = MaintTime / 100;
|
||||
tm->tm_min = MaintTime % 100;
|
||||
tm->tm_sec = 0;
|
||||
|
||||
MaintClock = mktime(tm) - (time_t)_MYTIMEZONE;
|
||||
|
||||
while (MaintClock < now)
|
||||
MaintClock += MaintInterval * 3600;
|
||||
|
||||
Debugprintf("Maint Clock %lld NOW %lld Time to HouseKeeping %lld", (long long)MaintClock, (long long)now, (long long)(MaintClock - now));
|
||||
|
||||
if (LastHouseKeepingTime)
|
||||
if (SendAMPRDirect)
|
||||
{
|
||||
if ((now - LastHouseKeepingTime) > MaintInterval * 3600)
|
||||
BOOL NeedSave = FALSE;
|
||||
|
||||
user = LookupCall("AMPR");
|
||||
|
||||
if (user == NULL)
|
||||
{
|
||||
DoHouseKeeping(FALSE);
|
||||
user = AllocateUserRecord("AMPR");
|
||||
user->Temp = zalloc(sizeof (struct TempUserInfo));
|
||||
NeedSave = TRUE;
|
||||
}
|
||||
|
||||
if ((user->flags & F_BBS) == 0)
|
||||
{
|
||||
// Not Defined as a BBS
|
||||
|
||||
if (SetupNewBBS(user))
|
||||
user->flags |= F_BBS;
|
||||
NeedSave = TRUE;
|
||||
}
|
||||
|
||||
if (NeedSave)
|
||||
SaveUserDatabase();
|
||||
}
|
||||
for (i = optind; i < argc; i++)
|
||||
|
||||
|
||||
// Make sure SYSOPCALL is set
|
||||
|
||||
if (SYSOPCall[0] == 0)
|
||||
strcpy(SYSOPCall, BBSName);
|
||||
|
||||
// See if just want to add user (mainly for setup scripts)
|
||||
|
||||
if (argc == 5 && _stricmp(argv[1], "--adduser") == 0)
|
||||
{
|
||||
if (_stricmp(argv[i], "tidymail") == 0)
|
||||
DeleteRedundantMessages();
|
||||
BOOL isBBS = FALSE;
|
||||
char * response;
|
||||
|
||||
if (_stricmp(argv[i], "nohomebbs") == 0)
|
||||
DontNeedHomeBBS = TRUE;
|
||||
if (_stricmp(argv[4], "TRUE") == 0)
|
||||
isBBS = TRUE;
|
||||
|
||||
printf("Adding User %s\r\n", argv[2]);
|
||||
response = AddUser(argv[2], argv[3], isBBS);
|
||||
printf("%s", response);
|
||||
exit(0);
|
||||
}
|
||||
// Allocate Streams
|
||||
|
||||
strcpy(pgm, "BBS");
|
||||
|
||||
for (i=0; i < MaxStreams; i++)
|
||||
{
|
||||
conn = &Connections[i];
|
||||
conn->BPQStream = FindFreeStream();
|
||||
|
||||
if (conn->BPQStream == 255) break;
|
||||
|
||||
NumberofStreams++;
|
||||
|
||||
// BPQSetHandle(conn->BPQStream, hWnd);
|
||||
|
||||
SetAppl(conn->BPQStream, (i == 0 && EnableUI) ? 0x82 : 2, BBSApplMask);
|
||||
Disconnect(conn->BPQStream);
|
||||
}
|
||||
|
||||
printf("Mail Started\n");
|
||||
Logprintf(LOG_BBS, NULL, '!', "Mail Starting");
|
||||
strcpy(pgm, "LINBPQ");
|
||||
|
||||
}
|
||||
}
|
||||
InitialiseTCP();
|
||||
InitialiseNNTP();
|
||||
|
||||
Debugprintf("POP3 Debug After Mail Init Timer = %d", POP3Timer);
|
||||
SetupListenSet(); // Master set of listening sockets
|
||||
|
||||
if (EnableUI || MailForInterval)
|
||||
SetupUIInterface();
|
||||
|
||||
if (MailForInterval)
|
||||
_beginthread(SendMailForThread, 0, 0);
|
||||
|
||||
|
||||
// Calulate time to run Housekeeping
|
||||
{
|
||||
struct tm *tm;
|
||||
time_t now;
|
||||
|
||||
now = time(NULL);
|
||||
|
||||
tm = gmtime(&now);
|
||||
|
||||
tm->tm_hour = MaintTime / 100;
|
||||
tm->tm_min = MaintTime % 100;
|
||||
tm->tm_sec = 0;
|
||||
|
||||
MaintClock = mktime(tm) - (time_t)_MYTIMEZONE;
|
||||
|
||||
while (MaintClock < now)
|
||||
MaintClock += MaintInterval * 3600;
|
||||
|
||||
Debugprintf("Maint Clock %lld NOW %lld Time to HouseKeeping %lld", (long long)MaintClock, (long long)now, (long long)(MaintClock - now));
|
||||
|
||||
if (LastHouseKeepingTime)
|
||||
{
|
||||
if ((now - LastHouseKeepingTime) > MaintInterval * 3600)
|
||||
{
|
||||
DoHouseKeeping(FALSE);
|
||||
}
|
||||
}
|
||||
for (i = optind; i < argc; i++)
|
||||
{
|
||||
if (_stricmp(argv[i], "tidymail") == 0)
|
||||
DeleteRedundantMessages();
|
||||
|
||||
if (_stricmp(argv[i], "nohomebbs") == 0)
|
||||
DontNeedHomeBBS = TRUE;
|
||||
}
|
||||
|
||||
printf("Mail Started\n");
|
||||
Logprintf(LOG_BBS, NULL, '!', "Mail Starting");
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
if (NUMBEROFTNCPORTS)
|
||||
InitializeTNCEmulator();
|
||||
|
|
|
@ -0,0 +1,65 @@
|
|||
<?xml version="1.0" encoding="Windows-1252"?>
|
||||
<VisualStudioUserFile
|
||||
ProjectType="Visual C++"
|
||||
Version="8.00"
|
||||
ShowAllFiles="false"
|
||||
>
|
||||
<Configurations>
|
||||
<Configuration
|
||||
Name="Debug|Win32"
|
||||
>
|
||||
<DebugSettings
|
||||
Command="$(TargetPath)"
|
||||
WorkingDirectory="c:\linbpq"
|
||||
CommandArguments=""
|
||||
Attach="false"
|
||||
DebuggerType="3"
|
||||
Remote="1"
|
||||
RemoteMachine="NOTTSDESKTOP"
|
||||
RemoteCommand=""
|
||||
HttpUrl=""
|
||||
PDBPath=""
|
||||
SQLDebugging=""
|
||||
Environment=""
|
||||
EnvironmentMerge="true"
|
||||
DebuggerFlavor="0"
|
||||
MPIRunCommand=""
|
||||
MPIRunArguments=""
|
||||
MPIRunWorkingDirectory=""
|
||||
ApplicationCommand=""
|
||||
ApplicationArguments=""
|
||||
ShimCommand=""
|
||||
MPIAcceptMode=""
|
||||
MPIAcceptFilter=""
|
||||
/>
|
||||
</Configuration>
|
||||
<Configuration
|
||||
Name="Release|Win32"
|
||||
>
|
||||
<DebugSettings
|
||||
Command="$(TargetPath)"
|
||||
WorkingDirectory=""
|
||||
CommandArguments=""
|
||||
Attach="false"
|
||||
DebuggerType="3"
|
||||
Remote="1"
|
||||
RemoteMachine="NOTTSDESKTOP"
|
||||
RemoteCommand=""
|
||||
HttpUrl=""
|
||||
PDBPath=""
|
||||
SQLDebugging=""
|
||||
Environment=""
|
||||
EnvironmentMerge="true"
|
||||
DebuggerFlavor=""
|
||||
MPIRunCommand=""
|
||||
MPIRunArguments=""
|
||||
MPIRunWorkingDirectory=""
|
||||
ApplicationCommand=""
|
||||
ApplicationArguments=""
|
||||
ShimCommand=""
|
||||
MPIAcceptMode=""
|
||||
MPIAcceptFilter=""
|
||||
/>
|
||||
</Configuration>
|
||||
</Configurations>
|
||||
</VisualStudioUserFile>
|
|
@ -0,0 +1,65 @@
|
|||
<?xml version="1.0" encoding="Windows-1252"?>
|
||||
<VisualStudioUserFile
|
||||
ProjectType="Visual C++"
|
||||
Version="8.00"
|
||||
ShowAllFiles="false"
|
||||
>
|
||||
<Configurations>
|
||||
<Configuration
|
||||
Name="Debug|Win32"
|
||||
>
|
||||
<DebugSettings
|
||||
Command="$(TargetPath)"
|
||||
WorkingDirectory=""
|
||||
CommandArguments=""
|
||||
Attach="false"
|
||||
DebuggerType="3"
|
||||
Remote="1"
|
||||
RemoteMachine="SKIGACER"
|
||||
RemoteCommand=""
|
||||
HttpUrl=""
|
||||
PDBPath=""
|
||||
SQLDebugging=""
|
||||
Environment=""
|
||||
EnvironmentMerge="true"
|
||||
DebuggerFlavor=""
|
||||
MPIRunCommand=""
|
||||
MPIRunArguments=""
|
||||
MPIRunWorkingDirectory=""
|
||||
ApplicationCommand=""
|
||||
ApplicationArguments=""
|
||||
ShimCommand=""
|
||||
MPIAcceptMode=""
|
||||
MPIAcceptFilter=""
|
||||
/>
|
||||
</Configuration>
|
||||
<Configuration
|
||||
Name="Release|Win32"
|
||||
>
|
||||
<DebugSettings
|
||||
Command="$(TargetPath)"
|
||||
WorkingDirectory=""
|
||||
CommandArguments=""
|
||||
Attach="false"
|
||||
DebuggerType="3"
|
||||
Remote="1"
|
||||
RemoteMachine="SKIGACER"
|
||||
RemoteCommand=""
|
||||
HttpUrl=""
|
||||
PDBPath=""
|
||||
SQLDebugging=""
|
||||
Environment=""
|
||||
EnvironmentMerge="true"
|
||||
DebuggerFlavor=""
|
||||
MPIRunCommand=""
|
||||
MPIRunArguments=""
|
||||
MPIRunWorkingDirectory=""
|
||||
ApplicationCommand=""
|
||||
ApplicationArguments=""
|
||||
ShimCommand=""
|
||||
MPIAcceptMode=""
|
||||
MPIAcceptFilter=""
|
||||
/>
|
||||
</Configuration>
|
||||
</Configurations>
|
||||
</VisualStudioUserFile>
|
|
@ -195,6 +195,9 @@ KC6OAR*>ID:
|
|||
// Check Port
|
||||
|
||||
Port = msg->PORT;
|
||||
|
||||
if (Port == 40)
|
||||
Port = Port;
|
||||
|
||||
if (Port & 0x80)
|
||||
{
|
||||
|
@ -250,10 +253,8 @@ KC6OAR*>ID:
|
|||
ptr += 7;
|
||||
n--;
|
||||
|
||||
if (n == 0)
|
||||
{
|
||||
if (n < 0)
|
||||
return 0; // Corrupt - no end of address bit
|
||||
}
|
||||
}
|
||||
|
||||
// Reached End of digis
|
||||
|
|
4322
SCSPactor.c.bak
4322
SCSPactor.c.bak
File diff suppressed because it is too large
Load Diff
|
@ -452,8 +452,7 @@ ok:
|
|||
|
||||
if (buffptr == 0) return (0); // No buffers, so ignore
|
||||
|
||||
buffptr->Len = 36;
|
||||
memcpy(&buffptr->Data[0], "No Connection to TNC\r", 36);
|
||||
buffptr->Len = sprintf(&buffptr->Data[0], "No Connection to TNC\r");
|
||||
|
||||
C_Q_ADD(&TNC->Streams[Stream].PACTORtoBPQ_Q, buffptr);
|
||||
|
||||
|
|
|
@ -427,6 +427,7 @@ int ProcessLine(char * buf, int Port)
|
|||
TCP->MaxSessions = 10; // Default Values
|
||||
TNC->Hardware = H_TELNET;
|
||||
TCP->IPV4 = TRUE;
|
||||
TCP->SecureTelnet = 1;
|
||||
strcpy(TCP->CMSServer, "cms.winlink.org");
|
||||
}
|
||||
|
||||
|
|
2
VARA.c
2
VARA.c
|
@ -2586,7 +2586,7 @@ VOID VARAProcessDataPacket(struct TNCINFO * TNC, UCHAR * Data, int Length)
|
|||
STREAM->BytesRXed += Length;
|
||||
|
||||
Data[Length] = 0;
|
||||
Debugprintf("VARA: RXD %d bytes", Length);
|
||||
// Debugprintf("VARA: RXD %d bytes", Length);
|
||||
|
||||
sprintf(TNC->WEB_TRAFFIC, "Sent %d RXed %d Queued %d",
|
||||
STREAM->BytesTXed, STREAM->BytesRXed,STREAM->BytesOutstanding);
|
||||
|
|
|
@ -10,14 +10,14 @@
|
|||
|
||||
#endif
|
||||
|
||||
#define KVers 6,0,24,40
|
||||
#define KVerstring "6.0.24.40\0"
|
||||
#define KVers 6,0,24,42
|
||||
#define KVerstring "6.0.24.42\0"
|
||||
|
||||
#ifdef CKernel
|
||||
|
||||
#define Vers KVers
|
||||
#define Verstring KVerstring
|
||||
#define Datestring "January 2024"
|
||||
#define Datestring "August 2024"
|
||||
#define VerComments "G8BPQ Packet Switch (C Version)" KVerstring
|
||||
#define VerCopyright "Copyright © 2001-2024 John Wiseman G8BPQ\0"
|
||||
#define VerDesc "BPQ32 Switch\0"
|
||||
|
|
|
@ -0,0 +1,65 @@
|
|||
<?xml version="1.0" encoding="Windows-1252"?>
|
||||
<VisualStudioUserFile
|
||||
ProjectType="Visual C++"
|
||||
Version="8.00"
|
||||
ShowAllFiles="false"
|
||||
>
|
||||
<Configurations>
|
||||
<Configuration
|
||||
Name="Debug|Win32"
|
||||
>
|
||||
<DebugSettings
|
||||
Command="$(TargetPath)"
|
||||
WorkingDirectory=""
|
||||
CommandArguments=""
|
||||
Attach="false"
|
||||
DebuggerType="3"
|
||||
Remote="1"
|
||||
RemoteMachine="NOTTSDESKTOP"
|
||||
RemoteCommand=""
|
||||
HttpUrl=""
|
||||
PDBPath=""
|
||||
SQLDebugging=""
|
||||
Environment=""
|
||||
EnvironmentMerge="true"
|
||||
DebuggerFlavor=""
|
||||
MPIRunCommand=""
|
||||
MPIRunArguments=""
|
||||
MPIRunWorkingDirectory=""
|
||||
ApplicationCommand=""
|
||||
ApplicationArguments=""
|
||||
ShimCommand=""
|
||||
MPIAcceptMode=""
|
||||
MPIAcceptFilter=""
|
||||
/>
|
||||
</Configuration>
|
||||
<Configuration
|
||||
Name="Release|Win32"
|
||||
>
|
||||
<DebugSettings
|
||||
Command="$(TargetPath)"
|
||||
WorkingDirectory=""
|
||||
CommandArguments=""
|
||||
Attach="false"
|
||||
DebuggerType="3"
|
||||
Remote="1"
|
||||
RemoteMachine="NOTTSDESKTOP"
|
||||
RemoteCommand=""
|
||||
HttpUrl=""
|
||||
PDBPath=""
|
||||
SQLDebugging=""
|
||||
Environment=""
|
||||
EnvironmentMerge="true"
|
||||
DebuggerFlavor=""
|
||||
MPIRunCommand=""
|
||||
MPIRunArguments=""
|
||||
MPIRunWorkingDirectory=""
|
||||
ApplicationCommand=""
|
||||
ApplicationArguments=""
|
||||
ShimCommand=""
|
||||
MPIAcceptMode=""
|
||||
MPIAcceptFilter=""
|
||||
/>
|
||||
</Configuration>
|
||||
</Configurations>
|
||||
</VisualStudioUserFile>
|
|
@ -0,0 +1,65 @@
|
|||
<?xml version="1.0" encoding="Windows-1252"?>
|
||||
<VisualStudioUserFile
|
||||
ProjectType="Visual C++"
|
||||
Version="8.00"
|
||||
ShowAllFiles="false"
|
||||
>
|
||||
<Configurations>
|
||||
<Configuration
|
||||
Name="Debug|Win32"
|
||||
>
|
||||
<DebugSettings
|
||||
Command="$(TargetPath)"
|
||||
WorkingDirectory=""
|
||||
CommandArguments=""
|
||||
Attach="false"
|
||||
DebuggerType="3"
|
||||
Remote="1"
|
||||
RemoteMachine="LAPTOP-Q6S4RP5Q"
|
||||
RemoteCommand=""
|
||||
HttpUrl=""
|
||||
PDBPath=""
|
||||
SQLDebugging=""
|
||||
Environment=""
|
||||
EnvironmentMerge="true"
|
||||
DebuggerFlavor=""
|
||||
MPIRunCommand=""
|
||||
MPIRunArguments=""
|
||||
MPIRunWorkingDirectory=""
|
||||
ApplicationCommand=""
|
||||
ApplicationArguments=""
|
||||
ShimCommand=""
|
||||
MPIAcceptMode=""
|
||||
MPIAcceptFilter=""
|
||||
/>
|
||||
</Configuration>
|
||||
<Configuration
|
||||
Name="Release|Win32"
|
||||
>
|
||||
<DebugSettings
|
||||
Command="$(TargetPath)"
|
||||
WorkingDirectory=""
|
||||
CommandArguments=""
|
||||
Attach="false"
|
||||
DebuggerType="3"
|
||||
Remote="1"
|
||||
RemoteMachine="LAPTOP-Q6S4RP5Q"
|
||||
RemoteCommand=""
|
||||
HttpUrl=""
|
||||
PDBPath=""
|
||||
SQLDebugging=""
|
||||
Environment=""
|
||||
EnvironmentMerge="true"
|
||||
DebuggerFlavor=""
|
||||
MPIRunCommand=""
|
||||
MPIRunArguments=""
|
||||
MPIRunWorkingDirectory=""
|
||||
ApplicationCommand=""
|
||||
ApplicationArguments=""
|
||||
ShimCommand=""
|
||||
MPIAcceptMode=""
|
||||
MPIAcceptFilter=""
|
||||
/>
|
||||
</Configuration>
|
||||
</Configurations>
|
||||
</VisualStudioUserFile>
|
|
@ -0,0 +1,65 @@
|
|||
<?xml version="1.0" encoding="Windows-1252"?>
|
||||
<VisualStudioUserFile
|
||||
ProjectType="Visual C++"
|
||||
Version="8.00"
|
||||
ShowAllFiles="false"
|
||||
>
|
||||
<Configurations>
|
||||
<Configuration
|
||||
Name="Debug|Win32"
|
||||
>
|
||||
<DebugSettings
|
||||
Command="$(TargetPath)"
|
||||
WorkingDirectory=""
|
||||
CommandArguments=""
|
||||
Attach="false"
|
||||
DebuggerType="3"
|
||||
Remote="1"
|
||||
RemoteMachine="NOTTSDESKTOP"
|
||||
RemoteCommand=""
|
||||
HttpUrl=""
|
||||
PDBPath=""
|
||||
SQLDebugging=""
|
||||
Environment=""
|
||||
EnvironmentMerge="true"
|
||||
DebuggerFlavor=""
|
||||
MPIRunCommand=""
|
||||
MPIRunArguments=""
|
||||
MPIRunWorkingDirectory=""
|
||||
ApplicationCommand=""
|
||||
ApplicationArguments=""
|
||||
ShimCommand=""
|
||||
MPIAcceptMode=""
|
||||
MPIAcceptFilter=""
|
||||
/>
|
||||
</Configuration>
|
||||
<Configuration
|
||||
Name="Release|Win32"
|
||||
>
|
||||
<DebugSettings
|
||||
Command="$(TargetPath)"
|
||||
WorkingDirectory=""
|
||||
CommandArguments=""
|
||||
Attach="false"
|
||||
DebuggerType="3"
|
||||
Remote="1"
|
||||
RemoteMachine="NOTTSDESKTOP"
|
||||
RemoteCommand=""
|
||||
HttpUrl=""
|
||||
PDBPath=""
|
||||
SQLDebugging=""
|
||||
Environment=""
|
||||
EnvironmentMerge="true"
|
||||
DebuggerFlavor=""
|
||||
MPIRunCommand=""
|
||||
MPIRunArguments=""
|
||||
MPIRunWorkingDirectory=""
|
||||
ApplicationCommand=""
|
||||
ApplicationArguments=""
|
||||
ShimCommand=""
|
||||
MPIAcceptMode=""
|
||||
MPIAcceptFilter=""
|
||||
/>
|
||||
</Configuration>
|
||||
</Configurations>
|
||||
</VisualStudioUserFile>
|
|
@ -70,8 +70,9 @@
|
|||
// Allow /History to be shortened to /Hi (45)
|
||||
// Fix extra r charater in Chat Config Web Page
|
||||
|
||||
//.25
|
||||
|
||||
// Increase sise of status display buffers (7)
|
||||
// Increase size of status display buffers (7)
|
||||
|
||||
#include "BPQChat.h"
|
||||
#include "Dbghelp.h"
|
||||
|
|
|
@ -1194,8 +1194,7 @@ int CountMessagestoForward(struct UserInfo * user);
|
|||
|
||||
VOID * GetMultiLineDialogParam(HWND hDialog, int DLGItem);
|
||||
|
||||
#define LIBCONFIG_STATIC
|
||||
#include "libconfig.h"
|
||||
|
||||
VOID * GetMultiStringValue(config_setting_t * hKey, char * ValueName);
|
||||
VOID * RegGetMultiStringValue(HKEY hKey, char * ValueName);
|
||||
|
||||
|
|
11
tncinfo.h
11
tncinfo.h
|
@ -225,6 +225,8 @@ struct STREAMINFO
|
|||
char AGWKey[21]; // Session Key for AGW Session Based Drivers
|
||||
|
||||
time_t ConnectTime; // Time connection made
|
||||
time_t AttachTime;
|
||||
|
||||
int BytesTXed;
|
||||
int BytesAcked;
|
||||
int BytesRXed;
|
||||
|
@ -258,6 +260,7 @@ struct STREAMINFO
|
|||
HWND xIDC_DIRN;
|
||||
|
||||
int RelaySyncStream;
|
||||
int VaraACMode;
|
||||
};
|
||||
|
||||
typedef struct AGWINFO
|
||||
|
@ -409,7 +412,7 @@ struct FreeDataINFO
|
|||
char * SSIDS[16];
|
||||
};
|
||||
|
||||
|
||||
struct sixPackInfo;
|
||||
|
||||
typedef struct TNCINFO
|
||||
{
|
||||
|
@ -427,6 +430,9 @@ typedef struct TNCINFO
|
|||
time_t SessionTimeLimit; // Optional limit to total session time
|
||||
time_t DefaultSessionTimeLimit; // Configured value
|
||||
|
||||
time_t AttachTimeLimit; // to trap port left attached for a long time without other activity
|
||||
time_t AttachTime;
|
||||
|
||||
int Hardware; // Hardware Type
|
||||
|
||||
#define H_WINMOR 1
|
||||
|
@ -449,6 +455,7 @@ typedef struct TNCINFO
|
|||
#define H_WINRPR 17
|
||||
#define H_HSMODEM 18
|
||||
#define H_FREEDATA 19
|
||||
#define H_SIXPACK 20
|
||||
|
||||
|
||||
int Port; // BPQ Port Number
|
||||
|
@ -839,6 +846,8 @@ typedef struct TNCINFO
|
|||
char * NRNeighbour;
|
||||
int NRCloseTimer;
|
||||
struct _LINKTABLE * DummyLink; // Simulated link to simplify interface to ax,25 netrom code
|
||||
struct sixPackPortInfo * sixPack;
|
||||
int VaraACMode;
|
||||
|
||||
} *PTNCINFO;
|
||||
|
||||
|
|
9
upnp.c
9
upnp.c
|
@ -85,6 +85,7 @@ char * leaseDuration = NULL;
|
|||
|
||||
struct UPNPDev * devlist = 0;
|
||||
char lanaddr[64] = "unset"; /* my ip address on the LAN */
|
||||
char wanaddr[64] = "unset"; /* my ip address on the LAN */
|
||||
struct UPNPUrls urls;
|
||||
struct IGDdatas data;
|
||||
|
||||
|
@ -126,7 +127,11 @@ int upnpInit()
|
|||
return 0;
|
||||
}
|
||||
|
||||
#if MINIUPNPC_API_VERSION == 18
|
||||
i = UPNP_GetValidIGD(devlist, &urls, &data, lanaddr, sizeof(lanaddr), wanaddr, sizeof(wanaddr));
|
||||
#else
|
||||
i = UPNP_GetValidIGD(devlist, &urls, &data, lanaddr, sizeof(lanaddr));
|
||||
#endif
|
||||
}
|
||||
|
||||
AddMap(devlist->descURL, Config->LANport, Config->WANPort, Config->Protocol);
|
||||
|
@ -153,7 +158,11 @@ int upnpClose()
|
|||
return 0;
|
||||
}
|
||||
|
||||
#if MINIUPNPC_API_VERSION == 18
|
||||
i = UPNP_GetValidIGD(devlist, &urls, &data, lanaddr, sizeof(lanaddr), wanaddr, sizeof(wanaddr));
|
||||
#else
|
||||
i = UPNP_GetValidIGD(devlist, &urls, &data, lanaddr, sizeof(lanaddr));
|
||||
#endif
|
||||
}
|
||||
|
||||
DeleteMap(devlist->descURL, Config->LANport, Config->WANPort, Config->Protocol);
|
||||
|
|
Loading…
Reference in New Issue