Cipher type EC/CBC
Cipher type EC/CBC
I am looking at writing up some code to operate as a small localized receiver for an ethernet based alarm module. It runs in both plain text mode & encrypted modes. The data is sent in a csv format, so in plain text it has taken me about an hour to get data both readable and transmittable, so easy enough for me to sort that side hopefully.
The system also has an option to send & receive data using what it calls EC/CBC cipher.
I have never heard of this encryption & am wondering if anybody here could point in the right direction to get information on what this EC/CBC stuff is?
The system also has an option to send & receive data using what it calls EC/CBC cipher.
I have never heard of this encryption & am wondering if anybody here could point in the right direction to get information on what this EC/CBC stuff is?
Re: Cipher type EC/CBC
EC=Elliptic Curve algorithm (could also mean: Electronic Commerce)Baldrick wrote:I am looking at writing up some code to operate as a small localized receiver for an ethernet based alarm module. It runs in both plain text mode & encrypted modes. The data is sent in a csv format, so in plain text it has taken me about an hour to get data both readable and transmittable, so easy enough for me to sort that side hopefully.
The system also has an option to send & receive data using what it calls EC/CBC cipher.
I have never heard of this encryption & am wondering if anybody here could point in the right direction to get information on what this EC/CBC stuff is?
CBC=Cipher Block Chaining
Best wishes to the PB community. Thank you for the memories. 
- netmaestro
- PureBasic Bullfrog

- Posts: 8453
- Joined: Wed Jul 06, 2005 5:42 am
- Location: Fort Nelson, BC, Canada
Re: Cipher type EC/CBC
That'll be AES, EC in this case stands for "Electronic Codebook". See Purebasic AESEncoder docs for a bit more info.
BERESHEIT
Re: Cipher type EC/CBC
@Kuron, We have come to the same conclusion. Is it codebook or eliptic curve, who knows, the sales people I have tried to speak with just cringe & runaway & hide with questions like that....
@Netmaestro, That looks like it might give me an excellent place to start & being that I can change these units between plain text & encrypted modes quite easily means I am confidant I will be able to work this out with simple trial & error until I get it right.
From what I have seen so far it seems to be using a 4 digit hex key which means it is using a 16 bit key. So, from the PB docs you have pointed me at, I can assume I am dealing with 128 bit encryption now, so that is what I will work with.
Think I will get it all running smoothly in plain text mode 1st, then come back to this part later...
@Netmaestro, That looks like it might give me an excellent place to start & being that I can change these units between plain text & encrypted modes quite easily means I am confidant I will be able to work this out with simple trial & error until I get it right.
From what I have seen so far it seems to be using a 4 digit hex key which means it is using a 16 bit key. So, from the PB docs you have pointed me at, I can assume I am dealing with 128 bit encryption now, so that is what I will work with.
Think I will get it all running smoothly in plain text mode 1st, then come back to this part later...
Re: Cipher type EC/CBC
it should read ecb or cbc
ecb = electronic code book
cbc = cipher block chaining
chances are it will probably be AES but it may be others like blowfish
ecb is like a static encryption mode that uses the same cipher on each block
cbc modifies the cipher block based on the last encrypted block (more secure and a little slower)
it's won't be elliptic curve.
ecb = electronic code book
cbc = cipher block chaining
chances are it will probably be AES but it may be others like blowfish
ecb is like a static encryption mode that uses the same cipher on each block
cbc modifies the cipher block based on the last encrypted block (more secure and a little slower)
it's won't be elliptic curve.
Windows 11, Manjaro, Raspberry Pi OS


Re: Cipher type EC/CBC
Thanks Idle.
I havent looked at it at all today, but if I can get around to it, I might see what I can do to get it running in plain text mode over the next few days which from what I have looked at with them so far I think should be pretty straight forward.
Once I am happy with that I will make up a bit of an emulator for the uC and see what I can sniff out.
(These things are actually 1 your NZ products. The biggest problem at the moment is the Aus distributor has basically gone belly up from what I can gather, so getting hold of these units is a bit of a challenge ATM, let alone getting any technical questions answered. But no matter, I will hack my way through it 1 way or another.....)
The biggest issue is the setup software they are supplying is really, really, welllll... Ordinary, buggy, etc, which is a pity as these things have so much potential.
So apart from making my own setup software, I am thinking of writing my own mini receiver application which I can supply to small industries, etc to allow them to monitor stuff for limited times as they choose from their admin offices, etc which I would limit this to just a few systems per receiver.
This is the Uc - http://www.micronsecurity.com/news.php?id=18
I havent looked at it at all today, but if I can get around to it, I might see what I can do to get it running in plain text mode over the next few days which from what I have looked at with them so far I think should be pretty straight forward.
Once I am happy with that I will make up a bit of an emulator for the uC and see what I can sniff out.
(These things are actually 1 your NZ products. The biggest problem at the moment is the Aus distributor has basically gone belly up from what I can gather, so getting hold of these units is a bit of a challenge ATM, let alone getting any technical questions answered. But no matter, I will hack my way through it 1 way or another.....)
The biggest issue is the setup software they are supplying is really, really, welllll... Ordinary, buggy, etc, which is a pity as these things have so much potential.
So apart from making my own setup software, I am thinking of writing my own mini receiver application which I can supply to small industries, etc to allow them to monitor stuff for limited times as they choose from their admin offices, etc which I would limit this to just a few systems per receiver.
This is the Uc - http://www.micronsecurity.com/news.php?id=18
Re: Cipher type EC/CBC
You could try to flick them an email at their info address or get on the blower to them.
It does seem a bit odd to mention encryption modes without saying what it is.
It does seem a bit odd to mention encryption modes without saying what it is.
Windows 11, Manjaro, Raspberry Pi OS


Re: Cipher type EC/CBC
I have spoken with them Idle & all they want to do is refer me to the 'new temporary Australian distributor'.
The new Au distributor is a software developer in Brisbane & I have known the owner (by telephone at least) for years. Speaking with him, he freely admits that he knows very little about the units & is just keeping a supply line open until they find a more permanent solution.
Also, with the NZ, I have had awful trouble just trying to understand the guy they have as tech support due to his really thick non english accent.
Edit: I do also have full technical access via their website and apart from saying it is using this EC/CBC encryption it contains nothing in the way of detail about what it actually is......
The new Au distributor is a software developer in Brisbane & I have known the owner (by telephone at least) for years. Speaking with him, he freely admits that he knows very little about the units & is just keeping a supply line open until they find a more permanent solution.
Also, with the NZ, I have had awful trouble just trying to understand the guy they have as tech support due to his really thick non english accent.
Edit: I do also have full technical access via their website and apart from saying it is using this EC/CBC encryption it contains nothing in the way of detail about what it actually is......
Re: Cipher type EC/CBC
I suppose you'll just have to try to decrypt the data!
Windows 11, Manjaro, Raspberry Pi OS


- netmaestro
- PureBasic Bullfrog

- Posts: 8453
- Joined: Wed Jul 06, 2005 5:42 am
- Location: Fort Nelson, BC, Canada
Re: Cipher type EC/CBC
Do you have the key / init vector? If not, there will be no decoding it..
BERESHEIT
Re: Cipher type EC/CBC
Netmaestro, I have a receiver here which will show me all the keys, data, etc, in real time so I think it is worth having a stab at it.
I know exactly what the csv data looks like now, so that combined with the receiver showing me the decrypted keys along with what looks like a raw data string will give a me place to start from.
Definitely will be an interesting challenge.
I know exactly what the csv data looks like now, so that combined with the receiver showing me the decrypted keys along with what looks like a raw data string will give a me place to start from.
Definitely will be an interesting challenge.
Re: Cipher type EC/CBC
Little update:
I did write up a nice simple little test server for this unit, but haven't bothered attempting the encryption. Good thing I think as I have just been sent a unit from a company which is manufactured in Hungary to do some testing. This new unit quite simply chews up & spits out the other companies product. Even better is that they are open about the cipher they use which is 128 bit AES & allows me to set my IV. Don't know what they are going to cost yet, but I do believe I have an excellent answer now in my product search.
I did write up a nice simple little test server for this unit, but haven't bothered attempting the encryption. Good thing I think as I have just been sent a unit from a company which is manufactured in Hungary to do some testing. This new unit quite simply chews up & spits out the other companies product. Even better is that they are open about the cipher they use which is 128 bit AES & allows me to set my IV. Don't know what they are going to cost yet, but I do believe I have an excellent answer now in my product search.

