#! /usr/bin/perl -T --
#
# $Id$


use strict;
use warnings;

my $CMD="/usr/libexec/openssh/sftp-server";
my $PATH="/FIXME";
my $UID=FIXME;

%ENV=();	# Prevent: Insecure $ENV{PATH} while running with -T switch
chroot $PATH or die "chroot: $PATH: $!";
($<,$>)=($UID,$UID);
$<==$UID or die "real UID==$<, expected $UID";
$>==$UID or die "EUID==$>, expected $UID";
chdir "/" or die "chdir: $!";
exec $CMD;
die "$CMD: $!";
