maximkulkin / esp-homekit

Apple HomeKit accessory server library for ESP-OPEN-RTOS
MIT License
1.11k stars 170 forks source link

- move definition of WOLFCRYPT_ONLY to component makefile. #26

Closed cduvenhorst closed 6 years ago

cduvenhorst commented 6 years ago

An alternate solution for compatibility with wolfssl v3.13.0-stable is to do a full TLS build with EXTRA_WOLFSSL_CFLAGS containing

-DHAVE_ONE_TIME_AUTH -DHAVE_ECC -DNO_OLD_TLS

maximkulkin commented 6 years ago

Does absence of WOLFCRYPT_ONLY affects anything?

cduvenhorst commented 6 years ago

It doesn't build if you link against your latest commit on esp-wolfssl. It tries to build the TLS functions of wolfssl without the needed ciphers (which are defined in the alternate solution). I understood that HomeACcessoryKid needs the TLS for his OTA-update component - so I tend to the the definition of the ciphers for use in the WOLFSSL ssl struct.

HomeACcessoryKid commented 6 years ago

My idea is this: in esp-wolfssl, we remove WOLFCRYPT_ONLY, this will get a new repo version Considering that esp-homekit refers to a specific (older) version of the esp-wolfssl-repo, it wil still work, based on that old version If then you update the esp-homekit, you can start referring to the newest esp-wolfssl while having the WOLFCRYPT_ONLY inside the esp-homekit makefile

So, yes, it works, but only in the order proposed

HomeACcessoryKid commented 6 years ago

Just to comment on my OTA initiative branch 'testing', it does NOT combine OTA with existing app code. It works side-by-side. For that reason, there is zero interaction between what happens in homekit and OTA. So we should make the decisions here based on what works for esp-homekit, not OTA.

cduvenhorst commented 6 years ago

Then my pull request does the right thing. Building a small version with the required ciphers and without TLS routines.

maximkulkin commented 6 years ago

@cduvenhorst Can you remove "-" from commit message and start it with a capital and we are good to go.

HomeACcessoryKid commented 6 years ago

Mind you, this should somehow be accompanied by referring to the last esp-wolfssl.

BR, HacK

On 6 Feb 2018, at 19:17, Maxim Kulkin notifications@github.com wrote:

@cduvenhorst Can you remove "-" from commit message and start it with a capital and we are good to go.

— You are receiving this because you commented. Reply to this email directly, view it on GitHub, or mute the thread.

maximkulkin commented 6 years ago

@HomeACcessoryKid There is no harm in having the same CFLAG twice.

cduvenhorst commented 6 years ago

Done.