cryptonas-branches/pythonrewrite/bin-perl-old/cryptobox_wrapper.c
lars e80b8874ff implemented root actions for plugins
finished network and date plugins
renamed old 'bin' direcory
2006-09-13 10:38:05 +00:00

21 lines
514 B
C

/* $Id$ */
// define the location of your cryptobox.pl file in this header file
#include "cryptobox_wrapper.h"
#include <stdio.h>
#include <unistd.h>
/* C wrapper to allow cryptobox to run under a different uid */
/* Copyright (C) 02006, senselab, All Rights Reserved */
/* See the LICENSE file in this distribution for copyright information */
int main(int argc, char *argv[]) {
// necessary for mount action of the root-script
setreuid(geteuid(), -1);
argv[0] = EXEC_PATH;
execv(EXEC_PATH, argv);
}