I have a project that I am trying to accomplish. Goal being, have my iPhone run stored procedures from a SQL database from outside the network.
As I am very new to this I am trying to put together all the pieces conceptually.
From researching and asking around so far I have implemented the following:
A. On my home pc, I setup a Restful WCF service. I've been reading about rest services and don't quite understand the difference but that seems to be what is recommended a lot.
B. Then I have it hosted using IIS. From what I understand on this, you have to host the webservice somehow, so this is what I am using. Correct me if I am wrong, but IIS give others the ability to SEE/ACCESS this webservice.
C. Right now it works INSIDE my home network. All I have setup now is a standard, user types in a http address, like "www.192.xxx.xxx.xx/mywebservice/custommessagegoeshere
Then the service returns a message like YOU HAVE RETURNED custommessagegoeshere.
D. Next step will be to return data from a local SQL stored procedure, and return that data in xml or json format.
Will I be able to Run stored procedures using a http GET or POST like I am using so far in my very standard message above?
Eventually when this project is complete I will host on a site like godaddy or something like that. But until then I will have this hosted on my home computer, and goal being able to access from outside my home network.
So... to accomplish having outside users access this local webservice. I think I need to do PORTFORWARDING. I'm still trying to learn about this, but I think anytime my router gets a request at X port, it forwards to my webservice.
- Is this correct? Is port forwarding what I should use?
- Is this safe? By using a port forwarding am I opening up my home pc to the world? Can hackers ruin my home pc doing this?
Sorry for the long post.