VNC Server & Client : Source Code For Sale

sfsameer

Well-Known Member
Licensed User
Longtime User
Hello Dear,

Because we have started the updates loop so i have 2 questions if i may regarding the public remote connection without setting up the router :
1- Should we use the same method as the TVA which is a middle ware server that transmits the connection data between clients through web sockets?
2- Should we use a proxy server to enable both parties to connect to each other without the need to open a port in the router?

Note : Option 1 & Option 2 will need a middle ware server to receive and send requests.

Thank you,
Saif
 

JohnC

Expert
Licensed User
Longtime User
Before I answer your above question, I would like to first reiterate the three use-cases that I hope the next update can support:

1) The first use-case is to have both the host and server support "reverse connections". For example, I could setup port-forwarding on my office pc so it will route "incoming connections" on a particular port from external "hosts" app to my PC. Then I would run the "viewer" app in reverse connection mode so it is waiting for an incoming connection from a "host" app. Since I have control over my end of the connection, it is easy to setup this port-forwarding in my router.

Then, I would create a custom version of the host app that would be hard-coded to make a reverse connection to the IP address of my office pc. This would then allow my client to simply run the custom host app and connect to my waiting viewer app - allowing me to support them immediately.

I am only mentioning this use-case because I hope the next update for your host and viewer apps can support reverse connections so that they can connect to each other without the need for any "middleware" (just as VNC is designed to do).

Next, I can see at least two different use-cases where middleware would be needed:

2) I have a bunch of remote (and unattended) PC's that I need to remotely maintain (which I am looking to change to android devices soon). I am hoping that the next update of your host and viewer can operate in a mode that uses a middleware server that would allow a viewer app running on my PC to connect to any of those remote pc's at any time. So, I am thinking that I would configure each of the remote PC's to auto-load your host app to run it when the PC boots up. These host apps would then contact the middleware server every 10 seconds or so to let the middleware server know that the pc is available to be connected to. Then the viewer app would have the ability to connect to the middleware server and get a list of all the available pcs that can be connected to. Then all I would have to do is click on a host PC name and my viewer app will connect to the remote host app and allow me to control it.

In this configuration, I'm thinking that it would be best to not require any routers to be pre-configured with port forwarding, so that the host and viewer app can connect to each other even if both ends have dynamic IP addresses and also that they may not have the ability to configure their firewall/router at all.

3) The final use-case is the ability for me to be able to still support one of my clients when I am not back at my office. In this situation, it would not be practical for the clients host app to be hard coded to make a reverse connection to a fixed IP address because my portable PC or smartphone device will probably be using a connection with a dynamic IP address. In this use-case, middleware will be needed to connect the client's host app to my viewer app.

Maybe the host app could allow the client to type in their name when they first run the host app and their name will appear in the list of the available devices that my viewer app will list as available to connect to, just like the above #2 use-case. I could then click on their name and my viewer app would be connected to their host app.

I just wanted to mention the above use-cases so that they might help give you ideas for the next update of this project.

Now, to answer your question....I think it would be best to:

1) Design the middleware to utilize a database but only for the purpose of managing what devices are available to connect to.
2) Then when I click on a host device to connect to, the middleware will then act as a proxy to route the packets between the host and viewer directly to each other without any overhead (like going through a database like the TVA did).

I hope all this makes sense and I am very much looking forward to the next update!
 

sfsameer

Well-Known Member
Licensed User
Longtime User

Hello Dear,

You know what i love about talking to you? you are a very detailed person which makes our lives easier, so thank you for that ❤

1- Consider it done
2- Consider it done

--------
1- Consider it done
2- Consider it done

As always, Thank you,
Saif
 

Xfood

Expert
Licensed User
good morning Saif, I had the opportunity to try this splendid work you have done in these days, at the moment it is fantastic, I imagine that the next update will be amazing. Thanks Saif, keep it up.
 

Louis Moskowitz

Member
Licensed User
Longtime User
Hi All.
I have made a similar suggestion to the developers in private and if they can solve this conundrum (host behind a firewall) we would truly have a a TeamViewer / AnyDesk RealVNC alternative. I would be happy to contribute to this kind of development. RealVNC offer this as a cloud service. See: https://www.realvnc.com/en/news/what-vnc-cloud/

Would anyone else contribute to some sort of "crowd funded development" for Saif and his team to tackle this?

Thanks
Louis
 

JohnC

Expert
Licensed User
Longtime User
I think they are already working on a "middleware" program that we will be able to run/host on our own web servers, so we would not need a third party cloud server.
 
Last edited:

jose luis gudino

Active Member
Licensed User
Longtime User
Future Updates :
1- B4A Client, the android client will be able to fully control the server side (host)
2- File Transfer
3- Able to use any VNC viewer to view the Server side (Host)
4- Hidden Mode/Stealth Mode

HI, how long will the new features be up and running?
Thank.
 

Louis Moskowitz

Member
Licensed User
Longtime User
I think they are already working on a "middleware" program that we will be able to run/host on our own web servers, so we would not need a third party cloud server.
Just to be clear, we would not be able to use the RealVNC cloud broker service, it is for their version. I was just sharing it as reference as to what we need Saif and his team to do to be able to have an alternative to RealVNC.

Great to hear that they are working on a solution.

Thanks
Louis
 

Louis Moskowitz

Member
Licensed User
Longtime User
Wow, I missed this. Totally agree that this is a very precise and clear description of what we need. Thanks Saif and team for undertaking to get 1 & 2 done.

Louis
 

sfsameer

Well-Known Member
Licensed User
Longtime User
Hello everyone

The update was scheduled to be uploaded today at 11:00 PM GMT 3+ but we will have to delay it just a little bit longer (less than 24 hours) because we are making sure that the code is understandable and bugs free so bear with us



Thank you,
Saif
 

amorosik

Expert
Licensed User
I still don't understand if this system can also be used for remote assistance from PCs to Android phones that are not manned
I mean, how do you know the network address of the phone?
And even if you know it, how do you start a connection from pc to phone?
Obviously I'm talking about a telephone connected only via the telephone data network
 

sfsameer

Well-Known Member
Licensed User
Longtime User
Hello,

Simply :
1-In a local connection you can connect both PC and Android through local IP address and port (Direct Connection)
2-In a public connection : We did this in Teamviewer alternative V1 & Web Control (TVA V2) where we do have a middle ware server (Non-UI B4J) that receives the packets (byteBuffer, inputs, gestures, etc...) and sends them to the receiving the point (Point A) , once point A receives the packets then it will send the response (Updated byteBuffer, etc...) to Point B and all of this information exchange will be in a loop until the connection is disconnected.

 

ocalle

Active Member
Licensed User
Longtime User
Hi
In the interest of consulting, even with the version now released with B4x code you can access a remote pc knowing the public ip (and enabling the firewall) right?
ty in advance
 

sfsameer

Well-Known Member
Licensed User
Longtime User
Hi
In the interest of consulting, even with the version now released with B4x code you can access a remote pc knowing the public ip (and enabling the firewall) right?
ty in advance
Hello,

Yes, as soon as you activate the port in your firewall your PC will be exposed to the internet and the VNC client will be able to connect to the VNC server.

Thank you,
Saif
 

sfsameer

Well-Known Member
Licensed User
Longtime User
Hello Everyone

After Writing 9 classes from scratch, Wrapping 29 classes, The B4A VNC Viewer simple version is born
Currently it's only used to view the server, no inputs, gestures, etc.. just for viewing.

**But this is the first version which means there will be many more version coming very soon, because the most difficult part is over which is :
1- Connecting to the server socket
2- Establishing the handshake
3- Encrypting and decrypting the password using : androidx.security:security-crypto
4- Enabling the color mode 256 and reading the bytebuffer
5- etc... (and many many more steps to accomplish the connection & the viewing)


-Below is the viewing demo (Keep in mind that the viewing activity is set to landscape so in the video it shows very small but in reality it's in landscape mode) :


Or you can view the video from the below URL :


-You can use it to connect to any VNC server BTW and not just B4J VNC Server

Before downloading the source code you need to know that there are 3 important libraries :
1- #AdditionalJar: androidx.security:security-crypto So make sure you open B4A SDK manager to download it
2- #AdditionalJar: tink-android-1.6.0.jar So make sure you put it in the additional libraries folder
3- VNCB4AClient.jar & VNCB4AClient.xml Make sure to put them in your internal libraries folder

*Please use the same download link we sent you earlier to download the B4A VNC Version and you will see a new file under the name : "VNCB4AClient.zip"

One last thing, the connection and the viewing is established by 2 lines of code in B4A because everything is happening in the libraries :
B4X:
B4AVNCClient1.mainSettings(Main.ServerIP,Main.ServerPort,Main.ServerPassword)
    B4AVNCClient1.StartViewer(img1)


**The next update is coming very soon which will contain the B4A VNC Server, so stay tuned

Thank you,
Saif
 
Last edited:
Cookies are required to use this site. You must accept them to continue using the site. Learn more…