003 File Manager
Current Path:
/usr/src/contrib/opie
usr
/
src
/
contrib
/
opie
/
📁
..
📄
BUG-REPORT
(3.58 KB)
📄
COPYRIGHT.NRL
(3.3 KB)
📄
INSTALL
(7.68 KB)
📄
License.TIN
(2.34 KB)
📄
Makefile.in
(13.01 KB)
📄
README
(21.99 KB)
📄
acconfig.h
(5.99 KB)
📄
config.h.in
(11.48 KB)
📄
config.testeflag
(162 B)
📄
configure
(144.58 KB)
📄
configure.in
(18.14 KB)
📄
configure.munger.in
(409 B)
📄
ftpcmd.y
(27.11 KB)
📄
glob.c
(13.22 KB)
📄
install-sh
(4.66 KB)
📁
libmissing
📁
libopie
📄
opie.4
(14.27 KB)
📄
opie.h
(5.57 KB)
📄
opie_cfg.h
(4.99 KB)
📄
opieaccess.5
(3.1 KB)
📄
opieauto.c
(8.45 KB)
📄
opieftpd.8
(8.82 KB)
📄
opieftpd.c
(41.79 KB)
📄
opiegen.1
(2.4 KB)
📄
opiegen.c
(2.36 KB)
📄
opieinfo.1
(2.63 KB)
📄
opieinfo.c
(2.78 KB)
📄
opiekey.1
(4.87 KB)
📄
opiekey.c
(9.15 KB)
📄
opiekeys.5
(1.88 KB)
📄
opielogin.1
(3.21 KB)
📄
opielogin.c
(35.74 KB)
📄
opiepasswd.1
(4.36 KB)
📄
opiepasswd.c
(12.01 KB)
📄
opieserv.1
(2.13 KB)
📄
opieserv.c
(2.04 KB)
📄
opiesu.1
(2.97 KB)
📄
opiesu.c
(13.84 KB)
📄
opietest.c
(7.22 KB)
📄
permsfile.c
(4.22 KB)
📄
popen.c
(6.41 KB)
Editing: opieserv.c
/* opieserv.c: Sample OTP server based on the opiechallenge() and opieverify() library routines. %%% copyright-cmetz-96 This software is Copyright 1996-2001 by Craig Metz, All Rights Reserved. The Inner Net License Version 3 applies to this software. You should have received a copy of the license with this software. If you didn't get a copy, you may request one from <license@inner.net>. History: Modified by cmetz for OPIE 2.3. Send debug info to syslog. Created by cmetz for OPIE 2.2. */ #include "opie_cfg.h" #include <stdio.h> #if DEBUG #include <syslog.h> #endif /* DEBUG */ #include "opie.h" int main FUNCTION((argc, argv), int argc AND char *argv[]) { struct opie opie; char *principal; char buffer[1024]; char challenge[OPIE_CHALLENGE_MAX+1]; char response[OPIE_RESPONSE_MAX+1]; int result; if (argc <= 1) { fputs("Principal: ", stderr); if (!opiereadpass(buffer, sizeof(buffer)-1, 1)) fprintf(stderr, "Error reading principal!"); principal = buffer; } else { principal = argv[1]; } #if DEBUG syslog(LOG_DEBUG, "Principal is +%s+", principal); #endif /* DEBUG */ switch (result = opiechallenge(&opie, principal, challenge)) { case -1: fputs("System error!\n", stderr); exit(1); case 0: break; case 1: fputs("User not found!\n", stderr); exit(1); case 2: fputs("System error!\n", stderr); exit(1); default: fprintf(stderr, "Unknown error %d!\n", result); exit(1); }; fputs(challenge, stdout); fputc('\n', stdout); fflush(stdout); fputs("Response: ", stderr); if (!opiereadpass(response, OPIE_RESPONSE_MAX, 1)) { fputs("Error reading response!\n", stderr); exit(1); }; switch (result = opieverify(&opie, response)) { case -1: fputs("System error!\n", stderr); exit(1); case 0: fputs("User verified.\n", stderr); exit(0); case 1: fputs("Verify failed!\n", stderr); exit(1); default: fprintf(stderr, "Unknown error %d!\n", result); exit(1); } }
Upload File
Create Folder