Home | History | Annotate | only in /external/ltp/testcases/kernel/security/mmc_security
Up to higher level directory
NameDateSize
ask_password.sh05-Oct-20172.6K
assign_password.sh05-Oct-20172.6K
AUTHORS05-Oct-2017146
change_password.sh05-Oct-20172.8K
force_erase.sh05-Oct-20172.9K
LICENSE05-Oct-201717.6K
Makefile05-Oct-20171K
README05-Oct-20171.8K
remove_password.sh05-Oct-20172.5K

README

      1 MMC Password Protection Reference UI
      2 ------------------------------------
      3 
      4 This is a simple text-mode reference UI for the MMC password protection
      5 support, written in shell script. It's very simple and does not hash nor cache
      6 passwords.
      7 
      8 It's composed of the following files:
      9 
     10 - ask_password.sh: get the password from userspace. It's called when unlocking
     11   the card or assigning a new password to an unlocked card.
     12 - change_password.sh: used to change the password from a unlocked card.
     13 - forced_erase.sh: used to force-erase a card, usually when the user has forgot
     14   the password and wants to unlock the card. NOTE: all the card's contents are
     15   lost when using this option! It only works for _locked_ cards.
     16 - remove_password.sh: used to remove the passwor from a card previously unlocked.
     17 
     18 Setting up
     19 ----------
     20 
     21 1) Install the keyutils package available from http://people.redhat.com/~dhowells/keyutils/
     22 2) Install this package:
     23 
     24 
     25 2) Add the following lines to /etc/request-key.conf (remember to remove any
     26 previous mmc lines):
     27 
     28 create   mmc   mmc:key   unlock   /usr/share/keyutils/ask_password.sh %k %S
     29 create   mmc   mmc:key   assign   /usr/share/keyutils/assign_password.sh %k %S
     30 
     31 Using it
     32 --------
     33 
     34 1) Unlocking a card:
     35 
     36 keyctl request2 mmc mmc:key unlock
     37 
     38 2) Assigning a password to an unlocked card:
     39 
     40 keyctl request2 mmc mmc:key assign
     41 
     42 3) Changing the password (card must be unlocked first):
     43 
     44 /usr/share/keyutils/change_password.sh
     45 
     46 4) Removing the password (card must be unlocked first):
     47 
     48 /usr/share/keyutils/remove_password.sh
     49 
     50 5) Force erase card (card must be LOCKED):
     51 
     52 /usr/share/keyutils/force_erase.sh
     53 
     54 Contact Info
     55 ------------
     56 
     57 Any comments or suggestions regarding these scripts should be sent to:
     58 
     59 Anderson Briglia <anderson.briglia (a] indt.org.br>
     60 Anderson Lizardo <anderson.lizardo (a] indt.org.br>
     61 Carlos Eduardo Aguiar <carlos.aguiar (a] indt.org.br>
     62