I am trying to make an app which will allow users to register and send pictures to each other. I am just wondering how to make it possible for 2 android phones to connect with each other using an internet connection? Only thing I know is of Server-Client communication but I am not sure whether this will work. When I searched I also read about GCM but if I understood correctly this is only for getting the server to send a message to an android device but not for the device to send back to the server.

Thanks for your help