Using webservices to connect two different computers throught the midway webservice.

Hello experts,

I plan to make a tool to connect my home computer to my laptop and android phone that I carry around. The connection would basically include some features like showing up status of download progresses, capturing images using the webcam, etc.

I was asked to use port forwarding but that is not an option, as my home computer uses a cable internet connection that does not give access to the public ip, and the phone and the laptop both use my phone internet connection which does not provide me a public ip either. So, while looking for solutions, I came to know, setting up web services might be of help.

Now, what I want to know is that, is it possible to set up a web service on cloud such that I can ping the web service from my phone with specific commands when I want, and my home computer on the other hand keeps looking for requests at the web service every minute and as soon as it finds a ping from my phone, it executes the command requested and forwards it to the service, which forwards the result to my phone?

In case that is possible, can free webhosting sites be used to host such services??

P.S.- I plan to write a simple SOAP service using PHP if this can be done, and I would need some help in setting that up too.

Help is much awaited.

Thanks in advance.
Soumen RoySenior ManagerAsked:
Who is Participating?

[Webinar] Streamline your web hosting managementRegister Today

x
 
shalomcConnect With a Mentor CTOCommented:
Excellent. So here is a plan:

On your hosted service install tt-rss https://tt-rss.org/gitlab/fox/tt-rss/wikis/home 
It needs php.

Now you need 2 clients:
A mobile client to post commands - there is a base client in the project.
A server (home) client to poll the RSS feed for new commands, execute them, and post back to a reply channel.

If it is clear, then you can drop the tt-rss ready solution and develop your own.
If you work correctly with the right amount of abstraction in your code, then you can use any subscription channel: rss, twitter, irc, or home brewed.
0
 
Jackie ManConnect With a Mentor Commented:
I will suggest an easier and more straight forward approach.

It is to buy a D-link router and use the free bundled D-link cloud service to do what you want.

http://cloud.dlink.com/
1
 
shalomcCTOCommented:
This is exactly the technology botnets use as C&C (command and control).
You have a place where the master can post commands, and the slave can read and execute. With botnets the command channel is usually IRC, or twitter, because then someone else manages the servers and pays the bills.

In your case, you should use IRC or twitter so you don't have to develop a mobile client.
On the PC side you will have to use a client library like this https://github.com/bear/python-twitter or this http://tweepy.readthedocs.io/en/v3.5.0/ 

There are alternatives  to twitter feeds like RSS, but then you need a server.
https://tt-rss.org/gitlab/fox/tt-rss/wikis/home 
Try the AWS free tier plan
1
Get expert help—faster!

Need expert help—fast? Use the Help Bell for personalized assistance getting answers to your important questions.

 
shalomcCTOCommented:
0
 
Soumen RoySenior ManagerAuthor Commented:
Thanks for the response.. I am sorry for the delayed reply.. I had been a bit busy with some work..

@Jackie Man.. Yes, I have heard of this, but I plan to make something like what I specified, so that I can submit it as my college project.

@shalomc.. I have already paid for some shared hosting server space, and hosted a few webpages there. I was planning to make use of that investment to host my web service if it was possible.. As I already told Mr. Jackie Man, I can make use of this tool by submitting it as my semester project..
0
 
Jackie ManCommented:
What you want to do is nothing new but difficult to implement. From my knowledge, your task is to setup your own DDNS server in your shared hosting server space and have your home router to link with your own DDNS server so that you can do port forwarding to have remote access to your home computer.

 Have a look of the link below for details.

http://andrwe.org/linux/own-ddns
0
 
Soumen RoySenior ManagerAuthor Commented:
Thank you.. I'll be starting with my web service coding tomorrow..

I'll drop a few questions here when I come across hassles.. Please bear with me for not closing this question just now..
0
All Courses

From novice to tech pro — start learning today.