LinuxQuestions.org
Visit Jeremy's Blog.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Non-*NIX Forums > Programming
User Name
Password
Programming This forum is for all programming questions.
The question does not have to be directly related to Linux and any language is fair game.

Notices


Reply
  Search this Thread
Old 08-03-2015, 10:47 AM   #1
akash_rawal
LQ Newbie
 
Registered: Aug 2015
Distribution: Lubuntu
Posts: 6

Rep: Reputation: Disabled
Thinking of developing a new secure protocol/framework


I am inspired by whenever I look around I find a sneakernet moving here and there for transfering even smallest files. I find it annoying. Given all computers here are networked, FTP is an alternative, but not nice enough (involves the frustating process of entering an ever changing IP address again and again).

So I want to create a cross-platform framework where devices on any network are identified by public keys. The devices can discover each other on any network using DNS-SD or SLP. Then they can communicate after establishing an encrypted connection. So for example if I want to send a file to any device I can use an easy to use interface to find my destination device, verify the public key and securely send the file. Next time I want to send file to same device I can do it quickly as my device knows public key of another device, even if the IP addresses have changed.

All this can happen without user intervention so that I could do things like syncing my contacts, calender, ... in my android phone with my laptop by just connecting both of them to same public wifi.

The framework will be modular. There will be a central component (e.g. a daemon process) which will manage discovery and connections to other devices, verification of public keys, and encrypting all data transfer. All functions like file transfer and syncing can be implemented as services. Services and applications using them will connect to this framework using an easy to use API. Conceptually anything achievable using conventional networks will be achievable with this (just replace IP addresses with public keys).

So here are my questions.
  1. Has anyone implemented anything similar before? I searched hard but didn't find any.
  2. I am thinking of doing the implementation in C as much as possible in order to produce a lightweight solution. (On android I need to put in some java stuff anyway.) Can this turn out to be a bad decision?
  3. Is there a distributed object system suitable for this purpose? Or should I roll out my own? I am examining CORBA but I don't see any transparent way to integrate public key based identity enforcement in it yet. Also documentation seems to be seriously scattered, making it hard to learn.
  4. I want to support all major platforms like linux, android, windows, etc. Is there any abstraction layer that would enable me to maintain maximum amount of code in common?
  5. Is LQ a correct place to discuss this topic, or are there better places?

Thanks for your feedbacks in advance.

Last edited by akash_rawal; 08-08-2015 at 12:17 AM. Reason: File sharing and sync are not the only applications.
 
Old 08-04-2015, 07:13 AM   #2
rtmistler
Moderator
 
Registered: Mar 2011
Location: USA
Distribution: MINT Debian, Angstrom, SUSE, Ubuntu, Debian
Posts: 9,882
Blog Entries: 13

Rep: Reputation: 4930Reputation: 4930Reputation: 4930Reputation: 4930Reputation: 4930Reputation: 4930Reputation: 4930Reputation: 4930Reputation: 4930Reputation: 4930Reputation: 4930
Quote:
Originally Posted by akash_rawal View Post
So for example if I want to send a file to any device I can use an easy to use interface to find my destination device, verify the public key and securely send the file. Next time I want to send file to same device I can do it quickly as my device knows public key of another device, even if the IP addresses have changed.
Bluetooth. One can connect two devices, transfer files, and once identified to each other, these devices can reconnect in the future as much as they want/need.
Quote:
Originally Posted by akash_rawal View Post
All this can happen without user intervention so that I could do things like syncing my contacts, calender, ... in my android phone with my laptop by just connecting both of them to same public wifi.
Google already does this with gmail, their calendar, and so forth. You have an Android phone containing google calendar, and it will be synced with your laptop, or any other system. You don't necessarily have to use gmail, but they have an applications framework to do this. So what you're saying is similar. It's not just a network protocol, it would be an applications framework too, per my example.
 
Old 08-04-2015, 08:44 AM   #3
akash_rawal
LQ Newbie
 
Registered: Aug 2015
Distribution: Lubuntu
Posts: 6

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by rtmistler
Bluetooth. One can connect two devices, transfer files, and once identified to each other, these devices can reconnect in the future as much as they want/need.
Bluetooth is slow. "Smallest files" was a misleading bias. We transfer big files too.

A: I wanna send you a file.
B: My phone is visible.
A: Its large.
B: Okay I'll start my FTP server.
C: Come on guys, don't your phones support OTG?
A: Nice! Can I have your pendrive for a while?
C: ... Sorry! My roommate seems to have gone away with it.

These things really happen over here every now and then.

Plus range of bluetooth is limited. It is nothing compared to our hostel ethernet/wifi. Using computer networks opens wider possibilities.

A: "File transfer failed" ... Now I have to go all way from first floor to 8th.. Damn the lift is broken...

Quote:
Originally Posted by rtmistler
Google already does this with gmail, their calendar, and so forth. You have an Android phone containing google calendar, and it will be synced with your laptop, or any other system. You don't necessarily have to use gmail, but they have an applications framework to do this. So what you're saying is similar. It's not just a network protocol, it would be an applications framework too, per my example.
Local networks are always more reliable than internet and those cloud services. Plus I want something distributed, open, modular and interoperable. And none of us will trust google with private data.

And what if you want to sync an entire directory containing gigabytes of your movie or music collection?
 
Old 08-04-2015, 09:15 AM   #4
rtmistler
Moderator
 
Registered: Mar 2011
Location: USA
Distribution: MINT Debian, Angstrom, SUSE, Ubuntu, Debian
Posts: 9,882
Blog Entries: 13

Rep: Reputation: 4930Reputation: 4930Reputation: 4930Reputation: 4930Reputation: 4930Reputation: 4930Reputation: 4930Reputation: 4930Reputation: 4930Reputation: 4930Reputation: 4930
Do you wish to do this development to solve the problems you're discussing, or for something to do as a development project?

Because instead of reinventing the history of network communications and associated sync applications, instead you should be concentrating on setting up a multimedia share server that you and all of your roommates can access over the WIFI.

Not trying to be a jerk about that either. Just thinking that (1) it is a lot of work to develop that and (2) the technology already exists. If I want to share files large and small, if I establish a server which I can connect my phone, tablet, laptop, desktop all too and transfer files, then that about solves 99% of my dilemma. And thus it becomes a question of what type of file server and what available apps can I use that are already out there?
 
Old 08-07-2015, 11:43 PM   #5
akash_rawal
LQ Newbie
 
Registered: Aug 2015
Distribution: Lubuntu
Posts: 6

Original Poster
Rep: Reputation: Disabled
I already agree this is a lot of work, and probably I might not be able to do it alone, but I think replacing the ever changing and spoofable IP addresses with constant and verifyable public keys would be highly advantageous.

Also it would be a one time effort and the solution is reusable everywhere in the world and everyone would benefit from it. And this is the thing that is motivating me to atleast try this out.

We already have DC servers in many hostels. But they don't solve all problems.
  1. If the server goes down we have to fall back to sneakernet.
  2. IP address of the server keeps changing, and it is easier to ask IP address of your friend than asking the server's IP address from the admin (Just imagine his condition when so many ask him the IP address).
  3. You need to set up a server wherever you intend to use it. (Not reusable)
 
Old 08-08-2015, 07:13 AM   #6
genss
Member
 
Registered: Nov 2013
Posts: 741

Rep: Reputation: Disabled
to have a secure connection you just need end to end encryption
other then that, a trusted server to map names to IP-s

funny enough, we could use something like that
NFS kindof sux
MTP is bad
FTP is for one way (and not really good)
etc.


gl
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Secure Neighbor Discovery Protocol savona Linux - Networking 2 02-14-2013 01:36 PM
Russia Doesn't Trust Google--Developing Secure Android frankbell General 3 09-07-2012 08:37 PM
LXer: Kaspersky Developing Cyber Secure Operating System LXer Syndicated Linux News 0 05-11-2012 09:51 PM
Developing LEACH protocol using ns2.34 prajwal.parihar Linux - Newbie 4 04-16-2012 09:22 AM
Most secure wireless network protocol metallica1973 Linux - Wireless Networking 1 10-25-2006 08:26 AM

LinuxQuestions.org > Forums > Non-*NIX Forums > Programming

All times are GMT -5. The time now is 10:58 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration