"Application already running on the network" scrip

LiveCode is the premier environment for creating multi-platform solutions for all major operating systems - Windows, Mac OS X, Linux, the Web, Server environments and Mobile platforms. Brand new to LiveCode? Welcome!

Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller, robinmiller

Post Reply
gyroscope
Livecode Opensource Backer
Livecode Opensource Backer
Posts: 404
Joined: Tue Jan 08, 2008 3:44 pm
Contact:

"Application already running on the network" scrip

Post by gyroscope » Tue Jul 08, 2008 11:32 am

I would ideally like my app(s) to have the following capability eventually:

When the app is started, for it to "recognize" if there is already a copy of the app running on another computer on a network (with the same license number) and so to give a message that it can't be opened.

Is that possible within RR and if so, would that be relatively straightforward to script? And would this script be cross-platform, or would there be some differences between the Mac and PC coding, could anyone tell me please? :?:

Another related question: is there any way to protect a license number-registered app from being copied, or if it is copied, it won't open? :?: (Or perhaps this shouldn't be a worry; if it happens, it happens, maybe...)

:)

Janschenkel
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 977
Joined: Sat Apr 08, 2006 7:47 am
Contact:

Post by Janschenkel » Tue Jul 08, 2008 12:56 pm

While you can try very hard to prevent copying, the hacker community will always find away to circumvent your restrictions. So it's a balancing act between how much you want to slow them down and how much time you want to spend on that.

As for detecting the same app running on the network with the same license key, you could use a combination of UDP datagrams that you broadcast on the network or perhaps some TCP socket communication.

Interesting items can be found in RevOnline > User Spaces > Browse by category : UDP client, UDP server, TCP app 1 and TCP app 2.

Hope this helped,

Jan Schenkel.
Quartam Reports & PDF Library for LiveCode
www.quartam.com

gyroscope
Livecode Opensource Backer
Livecode Opensource Backer
Posts: 404
Joined: Tue Jan 08, 2008 3:44 pm
Contact:

Post by gyroscope » Tue Jul 08, 2008 6:03 pm

Excellent Jan, very helpful, thank you! :)

This area is relatively new to me (for instance, I had never heard of a "UDP datagram" and foggy on ports and sockets, etc) so I was wondering if you know or someone else might know of any first base info for me to gen up on: "UDP/TCP for Dummies" sort of stuff, please?

:)

Janschenkel
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 977
Joined: Sat Apr 08, 2006 7:47 am
Contact:

Post by Janschenkel » Tue Jul 08, 2008 7:45 pm

Well, apart from those two sets of stacks, I'm not sure where there are tutorials on this particular topic.
However, if you're new to Revolution, you may get some mileage out of these two sets of tutorials on other topics, before you move on to tackling socket communication:
http://www.runrev.com/developers/tutorials/
http://revolution.byu.edu/

Hope this helped,

Jan Schenkel.
Quartam Reports & PDF Library for LiveCode
www.quartam.com

gyroscope
Livecode Opensource Backer
Livecode Opensource Backer
Posts: 404
Joined: Tue Jan 08, 2008 3:44 pm
Contact:

Post by gyroscope » Tue Jul 08, 2008 10:38 pm

Thanks for your quick reply, Jan.

Yes, I am new to Revolution (and my previous coding experience isn't much either, relatively speaking) and I guess my enthusiasm for wanting to get my first ever finished app "out there", outweighs my understanding level and experience at the moment (I know I'm trying to run before I can walk sometimes...:wink:) Though like all newbies, I'm sure, I try to soak myself in as much Revolution stuff as I can, hoping more will "seep in" as I go along!

You've given me the spark to go through the Rev Users Guide again (for the fourth time) as I know that yet more stuff will sink in this time around, as well as reminding me about the RR website tutorials, which I had quite forgotten about and have yet to go through...

One of the things which I think is so brilliant about Rev (I'm sure you'd agree) is the amount of tutorials/help/literature/websites, etc which is available, compared with other similar programs. I suppose the only downside to this is with so much info its sometimes difficult to track down specific stuff...

Anyhow, thank you!

:)

Post Reply