/mandos/trunk

To get this branch, use:
bzr branch http://bzr.recompile.se/loggerhead/mandos/trunk

« back to all changes in this revision

Viewing changes to plugins.d/mandos-client.c

  • Committer: Teddy Hogeborn
  • Date: 2009-01-29 22:22:32 UTC
  • Revision ID: teddy@fukt.bsnet.se-20090129222232-p9hqnq338nsvxayp
* mandos (main): Bug fix: Do setgid before setuid.  Add verbose GnuTLS
                 debugging messages.
* plugins.d/mandos-client.c (main): Bug fix: Do setgid before setuid.

Show diffs side-by-side

added added

removed removed

Lines of Context:
961
961
    uid = getuid();
962
962
    gid = getgid();
963
963
    
 
964
    setgid(gid);
 
965
    if(ret == -1){
 
966
      perror("setgid");
 
967
    }
 
968
    
964
969
    ret = setuid(uid);
965
970
    if(ret == -1){
966
971
      perror("setuid");
967
972
    }
968
973
    
969
 
    setgid(gid);
970
 
    if(ret == -1){
971
 
      perror("setgid");
972
 
    }
973
 
    
974
974
    ret = init_gnutls_global(&mc, pubkey, seckey);
975
975
    if(ret == -1){
976
976
      fprintf(stderr, "init_gnutls_global failed\n");