philanc / luatweetnacl

Lua wrapper arount the Tweet NaCl cryptographic library
MIT License
17 stars 5 forks source link

Windows support? #1

Closed macsek1911 closed 2 years ago

macsek1911 commented 7 years ago

First of all: Thank you for this great library. :smile:

But I had no success with porting it to windows. Is there a chance that we'll see windows support in the future?

Thanks in advance.

philanc commented 7 years ago

Ooops I missed your issue. Sorry for the looong wait :-(

Regarding Windows, I initially didn't include support for it because of the lack of OS random generator support (no /dev/urandom on Windows!). Since that time, I learnt how to do it on Windows, so I should update this library.

I don't have a Windows PC handy here at the moment, but you may try to replace randombytes.c here with the src/randombytes.c in my luazen library (see https://github.com/philanc/luazen/ )

philanc commented 7 years ago

Hi Freefall01, I added a randombyte.c version that includes support for the Windows random generator. I built it on Windows with VC (Visual Studio 2014) and Mingw gcc. Let me know if it works for you.