Then we can use the copy of /root/kippo_ssh_auths.log log to try and connect BACK to the door knockers machine and see if the login works.
If it does, add it to a success log(if new) and go on to the next one.
If it fails, ignore it. It will be deleted when we delete the copy of the log file at the end of the script.
I call this file test_ssh_info.sh
# This script will take mv the /root/scripts/kippo_ssh_auths.log log to /root/scripts/test_ssh_auths.log
# so we can safely work on it.
# After moving, it will go line by line and take the arguments and test them by ssh.
# If it works, the info will be written to another log, /root/scripts/valid_ssh_auths.log for any other usage.
# Suggest running at 45 min mark every hour. Right after the grab info script.
# sshpass will exit with code 0 if it logged in ok.
# ?? I was testing it and had some errors using the script. It would exit with 5. If I did it manualy, it worked $
echo"NOT Valid: $line"
# Change back the String Seperator
# Remove the log that we tested
Small script(start_kippo.sh) for cron to make sure your Kippo is still running.
I noticed that the small VPS I was running would kill Kippo once awhile because I ran out of memory(32MB) and swap(32MB). So I tested every minute to see if needed starting again.
echo"Started Kippo again."
Set your log rotation to cycle the Kippo log every 24 hours or my scripts will be re testing a lot of ssh connections.
Set your cron to run them whenever. I recommend just before the logrotate cycle. Just make sure it is sequenced right. Do the grab script first.
Finally the magic part ok we got all the information but how do we send it without user’s knowledge and harvest some data.
This trick is very simple to do , first create your strings about the information described above which you want to send than i will show you how to send them .
using this single code of line you will be able to connect to any http page and send your previously created Strings about phone and user details or text files
How Does this will send information
When you call MediaPlayer.create static function ,normally it is expected you to provide an video audio file link for streaming ,well you do not have to , you can just type any url it will still connect and even if the link is not working on the other side of the server you will have the information It will be stored in your Apache Server Logs ,because you have just requested a non existing file on the server with the user details and the other stuff in url.
You can also create a php page and try to post your stuff
php post page probably should work as below(i have tested this one but assuming it might just work)
The main trick of this tutorial was that without using any single permission in your AndroidManifest.xml file you will be still able to send data to any server
by just using a single line of code you just request on your website a non existing page and it will be logged on your Apache ServerLogs or if you have a php post file you can just print it on your page or store on your database.