Annotation of src/usr.bin/tcfs/tcfstatold.c, Revision 1.1
1.1 ! provos 1: /*
! 2: * Transparent Cryptographic File System (TCFS) for NetBSD
! 3: * Author and mantainer: Luigi Catuogno [luicat@tcfs.unisa.it]
! 4: *
! 5: * references: http://tcfs.dia.unisa.it
! 6: * tcfs-bsd@tcfs.unisa.it
! 7: */
! 8:
! 9: /*
! 10: * Base utility set v0.1
! 11: *
! 12: * $Source: /usr/src/tcfs-utils_0.1/bin/RCS/tcfsrun.c,v $
! 13: * $State: Exp $
! 14: * $Revision: 1.1 $
! 15: * $Author: luicat $
! 16: * $Date: 2000/01/14 13:44:04 $
! 17: *
! 18: */
! 19:
! 20: static const char *RCSid="$id: $";
! 21:
! 22: /* RCS_HEADER_ENDS_HERE */
! 23:
! 24:
! 25:
! 26: #include <stdio.h>
! 27: #include <sys/types.h>
! 28: #include <unistd.h>
! 29: #include <sys/param.h>
! 30: #include <sys/mount.h>
! 31: #include <sys/wait.h>
! 32: #include <des.h>
! 33: #include "tcfs.h"
! 34:
! 35: void main(int argc, char *argv[], char *envp[])
! 36: {
! 37: struct tcfs_status st;
! 38: int e;
! 39:
! 40: if(argc <2)
! 41: {
! 42: fprintf(stderr,"usage: tcfstat <filesystem>\n");
! 43: exit(1);
! 44: }
! 45:
! 46: e=tcfs_getstatus(argv[1],&st);
! 47: if(e==-1)
! 48: {
! 49: fprintf(stderr,"filesystem %s not mounted\n",argv[0]);
! 50: exit(1);
! 51: }
! 52:
! 53: printf("Status: %d; user keys: %d, group keys: %d\n",st.status, st.n_ukey, st.n_gkey);
! 54: printf("TCFS version: %d, Cipher: %s, keysize: %d, cipher version: %d\n",st.tcfs_version, st.cipher_desc, st.cipher_keysize, st.cipher_version);
! 55:
! 56:
! 57: }
! 58:
! 59: