daily pastebin goal
69%
SHARE
TWEET

Untitled

a guest Mar 25th, 2019 81 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. #!/bin/sh
  2. men=`(date +"%b")`
  3. dateNr=`date +"%m"`
  4. print "Einamasis menuo: $men ( $dateNr men. )"
  5.  
  6. Naxui(){
  7. print "Iveskite vartotojo varda:"
  8. read vardas
  9. print "Vartotojo login: $vardas"
  10. grep $vardas /etc/passwd > data
  11. awk -F : '{print $5}' data > data1
  12. awk3="$(awk '{print $2, $1}' data1)"
  13. print "Vardas Pavarde:" $awk3
  14. awk '{print $4}' data1 > data2
  15. awk3="$(awk -F - '{print $1}' data2)"
  16. print "Sistemoje registruotas nuo $awk3 metu"
  17. print "Si men jungesi is siu IP"
  18. print "-----------------------------------"
  19. print "|kiek    |IP adresas     |"
  20. print "-----------------------------------"
  21. echo "Ar norite pratesti? [yes arba no]: "
  22. read yno
  23. case $yno in
  24.  
  25.         [yY] | [yY][Ee][Ss] )
  26.                 Naxui
  27.                 ;;
  28.         [nN] | [nN][Oo] )
  29.                 exit 1
  30.                 ;;
  31.         *) echo "Blogi duomenys"
  32.            exit 255
  33.            ;;
  34. esac
  35. }
  36. Naxui
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top