I'll looking for advice/resources to write a program that can intercept system calls from a programm to supervise it's filesystem, network, etc access.
The aim of this is to write an online judge, so that untrusted code can be run safely on a server.
This is on linux, and I would prefer to write C++ or a scripting langauge (ruby, pytho...
Hi, as per http://stackoverflow.com/questions/3642370/using-ptrace-to-write-a-program-supervisor-in-userspace, I'm attempting to create the program supervisor component of an online judge.
What system calls would I need to block totally, always allow or check the attributes of to:
Prevent forking or runing other commands
Restrict to s...
I'm at a loss debugging this code. I copied the example from a guide, is this file being improperly indexed?
#include <sys/types.h>
#include <unistd.h>
#include <fcntl.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <math.h>
char *inicio(void);
main(void)
{
char *c;
int fd, sz, i;
c = inicio();
fd ...
For my OS class I'm supposed to implement Linux's cat using only system calls (no printf)
Reading this reference I found it being used to print to a file. I guess I should manipulate ofstream.
In the example appears: ofstream outfile ("new.txt",ofstream::binary);
How can I make it write to the screen?
EDIT: I realized this write() is...
For my OS class I have the assignment of implementing Unix's cat command with system calls (no scanf or printf). Here's what I got so far:
(Edited thanks to responses)
#include <sys/types.h>
#include <unistd.h>
#include <fcntl.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <math.h>
main(void)
{
int fd1; ...
I have the below code only a part of it is shown here and I am checking if a the type of file.
struct stat *buf /* just to show the type buf is*/
switch (buf.st_mode & S_IFMT) {
case S_IFBLK: printf(" block device\n"); break;
case S_IFCHR: printf(" character device\n"); break;
case S_IFDIR:...
I am running SSIS from a C# application. I would like to run the SSIS process using the dtexec utility but without showing the dtexec window when running. I have set the ProcessStartInfo.CreateNoWindow to true yet dtexec still displays the window. I assume this is due to dtexec and not C#, but I cannot find a argument for dtexec that ...