Branch: Tag:

1996-11-12

1996-11-12 08:06:14 by Per Hedbor <ph@opera.com>

omorganisation

Rev: server/base_server/config/low_describers.pike:1.2
Rev: server/base_server/config/savers.pike:1.2
Rev: server/base_server/disk_cache.pike:1.3
Rev: server/base_server/language.pike:1.4
Rev: server/base_server/mainconfig.pike:1.2
Rev: server/base_server/module.pike:1.3
Rev: server/base_server/module_support.pike:1.2
Rev: server/base_server/roxen.pike:1.3
Rev: server/base_server/roxenlib.pike:1.2
Rev: server/base_server/roxenloader.pike:1.2
Rev: server/etc/include/roxen.pre.pike:1.2
Rev: server/etc/roxen_master.pike:1.3
Rev: server/modules/filesystems/secure_fs.pike:1.2
Rev: server/modules/filesystems/userfs.pike:1.2
Rev: server/modules/tags/tablify.pike:1.1
Rev: server/more_modules/lysator.pike:1.2
Rev: server/more_modules/tablify.pike:1.2(DEAD)
Rev: server/unfinishedmodules/whois++.pike:1.2

1: + string popen(string s, void|mapping env) + { +  object p,p2; +  +  p2 = File(); +  p=p2->pipe(); +  if(!p) error("Popen failed. (couldn't create pipe)\n"); +  +  if(!fork()) +  { +  array (int) olduid; +  catch { +  if(p->query_fd() < 0) +  { +  perror("File to dup2 to closed!\n"); +  exit(99); +  } +  p->dup2(File("stdout")); +  +  olduid = ({ geteuid(), getegid() }); +  seteuid(0); + #if efun(setegid) +  setegid(getgid()); + #endif +  setgid(olduid[1]); +  setuid(olduid[0]); +  catch(exece("/bin/sh", ({ "-c", s }), (env||environment))); +  }; +  exit(69); +  }else{ +  string t; +  destruct(p); +  t=p2->read(6553555); +  destruct(p2); +  return t; +  } + } +  +    mapping make_mapping(string *f)   {    mapping foo=([ ]);
79:   {    add_constant("spawne",spawne);    add_constant("perror",werror); +  add_constant("popen",popen);   }   Newline at end of file added.