Jump to content




rednet frequencies


137 replies to this topic

#121 PixelToast

  • Signature Abuser
  • 2,265 posts
  • Location3232235883

Posted 13 December 2012 - 04:26 AM

View PostCoolisTheName007, on 06 December 2012 - 07:38 AM, said:

-snippy-
why does the ENTIRE network have to use the same, unsecured channel?
just make secure connections to every client, and now even if an attacker has the frequency they wont be able to do anything
if done correctly it can run seamlessly with the rednet api

#122 CoolisTheName007

  • Members
  • 304 posts

Posted 13 December 2012 - 05:35 AM

View PostPixelToast, on 13 December 2012 - 04:26 AM, said:

View PostCoolisTheName007, on 06 December 2012 - 07:38 AM, said:

-snippy-
why does the ENTIRE network have to use the same, unsecured channel?
Because it needs to broadcast in order to detect it's peers; and they only use it to broadcast, other transmissions are dealt with the secure send(id,msg) and it is due to that broadcast that a new member validates itself. Static, manual setup networks don't need frequencies obviously; I and others are referring to dynamic networks.
just make secure connections to every client, and now even if an attacker has the frequency they wont be able to do anything
They will be able to detect packets sent by the network during broadcast cycles, and work their way to fake themselves as a valid member. If you use encryption/frequencies, the transmission of keys/frequencies id's over a large group of users ends up being insecure. I do realize that partitioning the network into different frequencies could lead to a secure setup, however it puts a halt to simple one-frequency town networks. Also, I am trying to avoid whitlelists, because of the syncronization problem they pose.
if done correctly it can run seamlessly with the rednet api
Even if you ignore networks' needs, the original api, as Cloudy stated, needs some replacement for broadcast; I now realize I never read the reason for it, but I assume it is to reduce the number of computers waked up unnecessarily by broadcasts.


#123 PixelToast

  • Signature Abuser
  • 2,265 posts
  • Location3232235883

Posted 13 December 2012 - 06:44 AM

View PostCoolisTheName007, on 13 December 2012 - 05:35 AM, said:

Because it needs to broadcast in order to detect it's peers; and they only use it to broadcast, other transmissions are dealt with the secure send(id,msg) and it is due to that broadcast that a new member validates itself. Static, manual setup networks don't need frequencies obviously; I and others are referring to dynamic networks.
as long as rednet.receive() returns an actual id you can ensure it is valid
in that case MiM is impossible (or atleast preventable)

View PostCoolisTheName007, on 13 December 2012 - 05:35 AM, said:

the transmission of keys/frequencies id's over a large group of users ends up being insecure.
again, if you use the method i said before you dont actually broadcast a key
you agree on a random prime and primitive root then you can use an symetric key algorithm to encrypt the message
it is completely secure, and the attacker will have to brute force it

#124 CoolisTheName007

  • Members
  • 304 posts

Posted 13 December 2012 - 07:12 AM

View PostPixelToast, on 13 December 2012 - 06:44 AM, said:

View PostCoolisTheName007, on 13 December 2012 - 05:35 AM, said:

Because it needs to broadcast in order to detect it's peers; and they only use it to broadcast, other transmissions are dealt with the secure send(id,msg) and it is due to that broadcast that a new member validates itself. Static, manual setup networks don't need frequencies obviously; I and others are referring to dynamic networks.
as long as rednet.receive() returns an actual id you can ensure it is valid
Only if I have a whitelist explicitly telling me which id's are valid for the network. If I want to add computers to the whitelist on the go, I must deal with the problems of synchronizing a whitelist over an entire network.
in that case MiM is impossible (or atleast preventable)

View PostCoolisTheName007, on 13 December 2012 - 05:35 AM, said:

the transmission of keys/frequencies id's over a large group of users ends up being insecure.
again, if you use the method i said before you dont actually broadcast a key
you agree on a random prime and primitive root then you can use an symetric key algorithm to encrypt the message
it is completely secure, and the attacker will have to brute force it
The problem lies with the Steve side of sharing the key with many users; I'm talking of treason or something like that, which is likely if you start a big network. It isn't broadcasted. If an OS is furnished with the purpose of storing the key away from the user, it could work.


#125 PixelToast

  • Signature Abuser
  • 2,265 posts
  • Location3232235883

Posted 13 December 2012 - 07:35 AM

View PostCoolisTheName007, on 13 December 2012 - 07:12 AM, said:

Only if I have a whitelist explicitly telling me which id's are valid for the network. If I want to add computers to the whitelist on the go, I must deal with the problems of synchronizing a whitelist over an entire network.
didnt you have to do that anyway .-. i am confused
the way i have my network set up is there is a global host password that you need to enter in order to be added to the closest host
the already existing host will then send its list of hosts, and then every host in that list (that is in range) will be added to the new host list

the problem with this is that you will have to keep your password a secret , and if your friend leaks the password to someone untrustworthy then you will be prone to MiM attacks

View PostCoolisTheName007, on 13 December 2012 - 07:12 AM, said:

The problem lies with the Steve side of sharing the key with many users; I'm talking of treason or something like that, which is likely if you start a big network. It isn't broadcasted. If an OS is furnished with the purpose of storing the key away from the user, it could work.
im not talking about generating a key for the entire network, i mean a key that only one client and one server will know
it dosent matter if the client knows it because it will only work for decrypting messages directed towards the client

#126 CoolisTheName007

  • Members
  • 304 posts

Posted 13 December 2012 - 12:16 PM

View PostPixelToast, on 13 December 2012 - 07:35 AM, said:

snip

I don't want whitelists like those, because they require human intervention each time the network changes; also, I want to keep lengthy encryption computations to a minimum. I'm thinking a local whitelist plus a header specifying that a msg is a broadcast to allow new members to join in. However, that msg must also validate the new member as safe, and if the msg is really independent of time and most network state, that is impossible, because an attacker can just copy it, wait for the new member to turn off and then fake it's way through by repeating the same message. So I suppose I will have to involve the sender's id somewhere in the msg, because that's one of the things rednet has, unique identifiers, and that may solve this.
EDIT: encode the new member M id in the message with a pre-shared key K; host decrypts the message and checks if decoded id matches the id given by the rednet event 1st parameter; attacker C though he has the message and M's id, won't be able to send a valid message because it would need to know K to encode it's id.
By buffering the encoded sequences, one can avoid virtually all encryption computations.
I'm not an expert in encryption, but I guess that deterministically assigning id's, plus in an ordered fashion, like it is done now, e.g. 1,2,3,... it's a killer for this idea.
Any reason it has to be this way?

EDIT:
I guess that mapping id's to some reasonably sized string in a bijective way would be enough.
Also, to ensure that the host is valid, one could send a random password encrypted in the message, and expect receiving back a transformation of it.

#127 PixelToast

  • Signature Abuser
  • 2,265 posts
  • Location3232235883

Posted 13 December 2012 - 02:43 PM

View PostCoolisTheName007, on 13 December 2012 - 12:16 PM, said:

View PostPixelToast, on 13 December 2012 - 07:35 AM, said:

snip

I don't want whitelists like those, because they require human intervention each time the network changes; also, I want to keep lengthy encryption computations to a minimum. I'm thinking a local whitelist plus a header specifying that a msg is a broadcast to allow new members to join in. However, that msg must also validate the new member as safe, and if the msg is really independent of time and most network state, that is impossible, because an attacker can just copy it, wait for the new member to turn off and then fake it's way through by repeating the same message. So I suppose I will have to involve the sender's id somewhere in the msg, because that's one of the things rednet has, unique identifiers, and that may solve this.
EDIT: encode the new member M id in the message with a pre-shared key K; host decrypts the message and checks if decoded id matches the id given by the rednet event 1st parameter; attacker C though he has the message and M's id, won't be able to send a valid message because it would need to know K to encode it's id.
By buffering the encoded sequences, one can avoid virtually all encryption computations.
I'm not an expert in encryption, but I guess that deterministically assigning id's, plus in an ordered fashion, like it is done now, e.g. 1,2,3,... it's a killer for this idea.
Any reason it has to be this way?
encryption is not lengthy and not that hard to implement

also, your talking about a symmetric key algorithm
the method i was talking about was creating a key to feed into one of those algorithms
so the client dosent have to know a password in order to connect

i dont get why you would include your own id in your message, its unnecessary
the attacker wont be able to figure out the password just from listening nor can he fake his id

#128 CoolisTheName007

  • Members
  • 304 posts

Posted 14 December 2012 - 03:15 AM

View PostPixelToast, on 13 December 2012 - 02:43 PM, said:

encryption is not lengthy and not that hard to implement
The less is it is needed the better; I don't want to encrypt every message, only authentication ones.

also, your talking about a symmetric key algorithm
No, it may ressemble one, but the idea is to use it together with rednet id's to ensure a safe authentication.
the method i was talking about was creating a key to feed into one of those algorithms
so the client dosent have to know a password in order to connect
My problem is to have a computer authenticate itself to a network, using only a network shared key.
Quoting a previous post:
the way i have my network set up is there is a global host password that you need to enter in order to be added to the closest host
the already existing host will then send its list of hosts, and then every host in that list (that is in range) will be added to the new host list
Your client seems to need to know the host id, otherwise it would have to broadcast it and then the password would be known to anyone listening.
In my case, the client must auto-detect in-range hosts (that's dynamic networking), and that's why it has to broadcast in order to detect them, and then both parties must ensure their partner is valid. I left out the part where the client checked if the host was valid; a possible solution would be having the client encode a random password on the fly, and expecting to get back a transformation of the pasword.


#129 PixelToast

  • Signature Abuser
  • 2,265 posts
  • Location3232235883

Posted 14 December 2012 - 04:27 AM

View PostCoolisTheName007, on 14 December 2012 - 03:15 AM, said:

The less is it is needed the better; I don't want to encrypt every message, only authentication ones.
why wouldn't you want to encrypt every single message, encryption isnt that hard nor does it lag ffs

View PostCoolisTheName007, on 14 December 2012 - 03:15 AM, said:

No, it may ressemble one, but the idea is to use it together with rednet id's to ensure a safe authentication.
its still symetric key encryption because it has a single private key
adding your id dosent make the connection any more secure if rednet.receive returns an id then it does not need authentication

View PostCoolisTheName007, on 14 December 2012 - 03:15 AM, said:

My problem is to have a computer authenticate itself to a network, using only a network shared key.
-snip-
im researching ways to ensure two hosts have the same password without them leaking the password itself
elliptic curves sound nice c:

and for efficiency
only make the host authenticate the closest valid host in range
then the old host will send its list of hosts over to the new one
and every host on that list that is in range will be added to the new hosts list

#130 CoolisTheName007

  • Members
  • 304 posts

Posted 14 December 2012 - 05:08 AM

View PostPixelToast, on 14 December 2012 - 04:27 AM, said:

View PostCoolisTheName007, on 14 December 2012 - 03:15 AM, said:

The less is it is needed the better; I don't want to encrypt every message, only authentication ones.
why wouldn't you want to encrypt every single message, encryption isnt that hard nor does it lag ffs
It depends on how big your network is and what kind of traffic you'll have. I know it isn't hard, because I know some algorithms myself, in addition to various encryption tools already coded for CC.

View PostCoolisTheName007, on 14 December 2012 - 03:15 AM, said:

No, it may ressemble one, but the idea is to use it together with rednet id's to ensure a safe authentication.
its still symetric key encryption because it has a single private key
adding your id dosent make the connection any more secure if rednet.receive returns an id then it does not need authentication
Yes, it does, how would you distinguish between a valid authentication message sent by valid computer B and the same message sent by malicious computer C?

View PostCoolisTheName007, on 14 December 2012 - 03:15 AM, said:

My problem is to have a computer authenticate itself to a network, using only a network shared key.
-snip-
im researching ways to ensure two hosts have the same password without them leaking the password itself
elliptic curves sound nice c:

and for efficiency
only make the host authenticate the closest valid host in range
then the old host will send its list of hosts over to the new one
and every host on that list that is in range will be added to the new hosts list
Won't work for a host that is in range of two disjoint parts of the network.


#131 PixelToast

  • Signature Abuser
  • 2,265 posts
  • Location3232235883

Posted 14 December 2012 - 05:36 AM

View PostCoolisTheName007, on 14 December 2012 - 05:08 AM, said:

It depends on how big your network is and what kind of traffic you'll have. I know it isn't hard, because I know some algorithms myself, in addition to various encryption tools already coded for CC.
then use a light weight encryption algorithm, or optimize it with pre generated tables

View PostCoolisTheName007, on 14 December 2012 - 05:08 AM, said:

Yes, it does, how would you distinguish between a valid authentication message sent by valid computer B and the same message sent by malicious computer C?
what you want is to xor your mac address and a key together and combine it with the message, not just include your own id to the message, its a bit complicated and is only neccicary if you are trying to prevent the message from being tampered while going across the network itself

View PostCoolisTheName007, on 14 December 2012 - 05:08 AM, said:

Won't work for a host that is in range of two disjoint parts of the network.
then auth every id you detected that wasnt on the list the old host sent
or just dont make disjointed networks at all

#132 BigSHinyToys

  • Members
  • 1,001 posts

Posted 14 December 2012 - 07:41 AM

View PostPixelToast, on 14 December 2012 - 05:36 AM, said:

View PostCoolisTheName007, on 14 December 2012 - 05:08 AM, said:

It depends on how big your network is and what kind of traffic you'll have. I know it isn't hard, because I know some algorithms myself, in addition to various encryption tools already coded for CC.
then use a light weight encryption algorithm, or optimize it with pre generated tables
If you can make a light weight encryption system capable of terminal redirection and playing "star wars" without shudder I would like to see it.

#133 PixelToast

  • Signature Abuser
  • 2,265 posts
  • Location3232235883

Posted 14 December 2012 - 07:42 AM

View PostBigSHinyToys, on 14 December 2012 - 07:41 AM, said:

View PostPixelToast, on 14 December 2012 - 05:36 AM, said:

View PostCoolisTheName007, on 14 December 2012 - 05:08 AM, said:

It depends on how big your network is and what kind of traffic you'll have. I know it isn't hard, because I know some algorithms myself, in addition to various encryption tools already coded for CC.
then use a light weight encryption algorithm, or optimize it with pre generated tables
If you can make a light weight encryption system capable of terminal redirection and playing "star wars" without shudder I would like to see it.
ok :3

#134 CoolisTheName007

  • Members
  • 304 posts

Posted 14 December 2012 - 07:44 AM

View PostPixelToast, on 14 December 2012 - 05:36 AM, said:

or just dont make disjointed networks at all
lol, of course I want to be able to merge disjoint networks! e.g. a middle node goes offline and then restarts.
What I just realized is that I could not put the id in the messages, but then an attacker could repeat the broadcasts from the network. It wouldn't be able to change the message, and consequently the network could detect it was not a valid computer after some time, but by including the encrypted id I guarantee total safety.
I am only talking about using encryption for authentication, in-network messages go around without encryption.
Now on to coding!

#135 PixelToast

  • Signature Abuser
  • 2,265 posts
  • Location3232235883

Posted 14 December 2012 - 08:02 AM

View PostCoolisTheName007, on 14 December 2012 - 07:44 AM, said:

View PostPixelToast, on 14 December 2012 - 05:36 AM, said:

or just dont make disjointed networks at all
lol, of course I want to be able to merge disjoint networks! e.g. a middle node goes offline and then restarts.
What I just realized is that I could not put the id in the messages, but then an attacker could repeat the broadcasts from the network. It wouldn't be able to change the message, and consequently the network could detect it was not a valid computer after some time, but by including the encrypted id I guarantee total safety.
I am only talking about using encryption for authentication, in-network messages go around without encryption.
Now on to coding!
if the attacker had the password to the network, and was added to nearby host's host list you can just take a users id and create a fake message from that
however you can prevent tampering as long as you securely transfer a password
if the attacker gets a hold of that password then you are prone to tampering

EDIT:
host to host connections will work the same as host to client connections
if you want you can layer encryption by resetting the connections password every time data is transfered
meaning you will have to crack every single previous password before getting to the current one

#136 CoolisTheName007

  • Members
  • 304 posts

Posted 14 December 2012 - 08:19 AM

View PostPixelToast, on 14 December 2012 - 08:02 AM, said:

if the attacker had the password to the network, and was added to nearby host's host list you can just take a users id and create a fake message from that
That's not what an attacker would have to do; it would have to get the key==password and encode it's own id in it, exactly like if it was running the normal protocol.
An attacker who gets the pass certainly can break everything, as in all systems; but I plan on subdividing the network in regions with different keys for authentication, and possibly a password for each pair of id's in delicate situations, such as gateways to public networks.
When I said a client connecting, I really meant a new host/ new client.

#137 Tiin57

    Java Lunatic

  • Members
  • 1,412 posts
  • LocationIndiana, United States

Posted 15 December 2012 - 02:24 AM

I cannot tell how far off topic this has gone.

#138 PixelToast

  • Signature Abuser
  • 2,265 posts
  • Location3232235883

Posted 15 December 2012 - 03:36 AM

View Posttiin57, on 15 December 2012 - 02:24 AM, said:

I cannot tell how far off topic this has gone.
:s i know





1 user(s) are reading this topic

0 members, 1 guests, 0 anonymous users