Custom compiling.... #4503
Replies: 1 comment
-
Posted at 2015-03-06 by d0773d Posted at 2015-03-07 by alexanderbrevig This is available in Espruino https://github.com/espruino/Espruino/tree/master/libs/hashlib EDIT: a bit too quick to the keyboard there... This is SHA not AES, silly me. Posted at 2015-03-07 by d0773d SHA-224/256/384/512 will work for the signature :). Now, it depends on whether AES128 or 256 can work which I guess will depend on memory consumption. I was able to implement encryption on a LPC1768 mcu which only has 32KB RAM, 512KB FLASH. The Espruino board has RAM 48 kBytes, Flash 256 kBytes Posted at 2015-03-07 by alexanderbrevig You could offload the hashing to an external µCU maybe? Then talk to it via serial/i2c/whatever. Posted at 2015-03-07 by d0773d Ya, I thought about that. Maybe make an Ecryption breakout board designated only for crypto. For example: https://www.sparkfun.com/products/12773 The CryptoCape is for the beagle bone black. The Cape is rather large and I would most likely need a smaller breakout board. I've been thinking about a crypto project for a while now, but I haven't had the time to sit down and research the subject in depth. For all I know, there already might be a crypto project out there like the cryptocape. Posted at 2015-03-07 by DrAzzy Regarding setting up the toolchain: There's a thread somewhere on these forums where it's described in some detail. I think it was last posted in around mid december, when I discovered that the old compiler I was using for bigram didn't work anymore. If you're familiar with AWS, I've shared an AMI with tested compiler toolchain - ami-1ce28974 (if that happens to be more convenient than setting it up on your own linux box) Posted at 2015-03-07 by d0773d I'm not familiar with any of this :/ the only experience I have with microcontrollers is the arduino and mbed platform where you import a library and etc then press compile. I do remember the big ram post. I will do a search and hopefully figure this out. Posted at 2015-03-09 by @gfwilliams The first step would be building Espruino yourself. There's some info on the GitHub page. I've just merged in some information about 'Vagrant' from @boneskull - you could give it a try - it appears to be a way to automatically set up the image you'd need to build Espruino with. Actually adding functions to Espruino once that is done is quite easy - however you may find it slightly trickier if PolarSSL wants access to functions that can real/write to a socket. In terms of porting PolarSSL yourself - you should be able to make it fit, but you might have to lower the amount of 'variables' used by Espruino in the Are you thinking of using it with WiFi? It might be worth doing some research into the ESP8266 and SSL - surely someone must have implemented it in the ESP8266 itself by now. If so it'd be perfect. Posted at 2015-03-09 by d0773d @gfwilliams I was thinking about encryption for both ethernet and wifi. I am trying to take the route with the least resistance, so Wifi might be the better option for me to start with and see what kind of results I find. |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
-
Posted at 2015-03-06 by d0773d
I am on a mission to some how impliment aes128/256 and HMAC on the Espruino. There has to be a way to implement encryption. @gfwilliams I know you mentioned that it might be possible to impliment encryption by custom compiling Firmware. I started to search Google for away to add encryption and stumbled upon this guide: http://hobbymc.blogspot.com/2011/02/stm32-discovery-porting-polar-ssl.html?m=1 I have never played around with the Espruino firmware and was wondering what tools and software I will need to possible attempt what is explained in the guide? I do know the guide explains what tools are needed, but I am not sure if I will need different tools or what? Also is there a tutorial on the website for custom compilation?
Beta Was this translation helpful? Give feedback.
All reactions