-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathnullpasw.sh
More file actions
50 lines (44 loc) · 779 Bytes
/
nullpasw.sh
File metadata and controls
50 lines (44 loc) · 779 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
#!/bin/bash
echo Heloy User. This script is deleting password for user Windows
echo
echo
if [ "$1" == "install" ]
then
echo Installing packeges.
apt-get install chntpw
fi
if [ "$1" == "help" ]
then
echo install as intaling packeges.
echo help as helping.
echo setasuser \(/windows/system32/config\) as see istalling users in Windows.
echo removepassw \(/windows/system32/config\) \(users RID\) as see config users menu.
fi
if [ "$1" == "setasuser" ]
then
if [ -n "$2" ]
then
cd "$2"
else
echo "No parameters found. "
exit
fi
chntpw -l SAM
fi
if [ "$1" == "removepassw" ]
then
if [ -n "$2" ]
then
cd "$2"
else
echo "No parameters found. "
exit
fi
if [ -n "$3" ]
then
chntpw -u 0x"$3" SAM
else
echo "No parameters found. "
exit
fi
fi