Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Upgrade wolfssh 1.4.13 #893

Merged
merged 2 commits into from
May 4, 2023
Merged

Conversation

llange
Copy link
Contributor

@llange llange commented May 4, 2023

Now that wolfssl has been upgraded to a recent version, we can target the latest release of wolfssh.

llange added 2 commits May 2, 2023 23:36
Recent versions of WolfSSH define a new enum `WS_LOG_CERTMAN` that we need
to handle (otherwise we are greeted with a compilation error message).

Signed-off-by: Ludovic LANGE <[email protected]>
Now that wolfssl has been upgraded to a recent version, we can
target the latest release of wolfssh.

Signed-off-by: Ludovic LANGE <[email protected]>
@dexterbg dexterbg merged commit 1412cc0 into openvehicles:master May 4, 2023
@dexterbg
Copy link
Member

dexterbg commented May 4, 2023

Ludovic, the standard build with idf 3 fails after merging the wolfssl update:

CC build/wolfssh/wolfssh/src/io.o
/home/balzer/esp/Open-Vehicle-Monitoring-System-3/vehicle/OVMS.V3/components/wolfssh/wolfssh/src/internal.c: In function 'IdentifyKey':
/home/balzer/esp/Open-Vehicle-Monitoring-System-3/vehicle/OVMS.V3/components/wolfssh/wolfssh/src/internal.c:883:9: warning: unused variable 'dynType' [-Wunused-variable]
     int dynType = isPrivate ? DYNTYPE_PRIVKEY : DYNTYPE_PUBKEY;
         ^
/home/balzer/esp/Open-Vehicle-Monitoring-System-3/vehicle/OVMS.V3/components/wolfssh/wolfssh/src/internal.c: In function 'DoKexDhReply':
/home/balzer/esp/Open-Vehicle-Monitoring-System-3/vehicle/OVMS.V3/components/wolfssh/wolfssh/src/internal.c:3947:17: error: implicit declaration of function 'PRIVATE_KEY_UNLOCK' [-Werror=implicit-function-declaration]
                 PRIVATE_KEY_UNLOCK();
                 ^
/home/balzer/esp/Open-Vehicle-Monitoring-System-3/vehicle/OVMS.V3/components/wolfssh/wolfssh/src/internal.c:3952:17: error: implicit declaration of function 'PRIVATE_KEY_LOCK' [-Werror=implicit-function-declaration]
                 PRIVATE_KEY_LOCK();
                 ^

Can you have a look or shall I revert the merge?

Regards,
Michael

@dexterbg
Copy link
Member

dexterbg commented May 4, 2023

Oh, I just saw you write "now that wolfssl has been upgraded" -- I haven't merged those PRs yet, because they're still tagged as draft. Are they mergable now?

@dexterbg
Copy link
Member

dexterbg commented May 4, 2023

I've just tried merging your wolfssl draft PRs locally, still doesn't build:

In file included from /home/balzer/esp/Open-Vehicle-Monitoring-System-3/vehicle/OVMS.V3/components/wolfssl/wolfssl/wolfssl/wolfcrypt/sha256.h:96:0,
                 from /home/balzer/esp/Open-Vehicle-Monitoring-System-3/vehicle/OVMS.V3/components/console_ssh/src/console_ssh.cpp:52:
/home/balzer/esp/Open-Vehicle-Monitoring-System-3/vehicle/OVMS.V3/components/wolfssl/wolfssl/wolfssl/wolfcrypt/port/Espressif/esp32-crypt.h:30:24: fatal error: esp_random.h: No such file or directory
compilation terminated.

@dexterbg
Copy link
Member

dexterbg commented May 4, 2023

Apparently, the submodule points to another tag than v5.3.0-stable:

balzer@leela:~/esp/Open-Vehicle-Monitoring-System-3/vehicle/OVMS.V3> git submodule status
 7b953e7ebb440ce9461ee469159c3759450e7c98 components/mongoose/mongoose (6.2-882-g7b953e7)
 326a4bf004a6f4f19c8741ae10f24e1169e80f85 components/wolfssh/wolfssh (v1.4.13-stable)
 462f76c1fff3a14f8fa99e4735874a1045b46822 components/wolfssl/wolfssl (v5.5.4-stable-252-g462f76c1f)
 7c3878f8302c0e84578a67473e49e60bc6b3ada7 components/zip/libzip (rel-1-5-1-60-g7c3878f)
 d6bcf4ca4d02479f058fff44cfd171f928148179 components/zip/zlib (v1.2.12-2-gd6bcf4c)

After checking out v5.3.0-stable, I still get the warning, but the build succeeds.

@llange
Copy link
Contributor Author

llange commented May 4, 2023

Yes, sorry, I thought that my mail could help prevent this but unfortunately I failed at it :-)

So the idea is to merge, in order:

Once this is done, the tip of https://github.com/openvehicles/wolfssl/tree/v4.7.0-stable-ovms will have changed, and I will update #887 accordingly, and switch it from Draft to "OK" so that you can merge it.

(At this point, wolfssl will be in submodule at v4.7.0-stable-ovms (ovms patches added))

Then we would upgrade wolfssl from v4.7.0-stable-ovms to v5.3.0-stable (official upstream) with #890 (that I will take out of Draft)

(At this point, wolfssl will be in submodule at v5.3.0-stable (official, NO ovms patches))

And (only) after that should we merge this very wolfssh 1.4.13-stable update ;-) meaning wolfssh will compile after wolfssl being set to v5.3.0-stable.

Sorry for failing to properly communicate, I realize I've made too much PRs and it's not easy to synchronize.

Do you have any other preferred semi-synchronous communication way you would like to use (Like IRC / Matrix-Element / SMS / Phone / .... ) for proper synchronization ? Let me know if you prefer it that way.

@dexterbg
Copy link
Member

dexterbg commented May 4, 2023

It's late now, I'll revert the merges to get back to a buildable state for now. For PRs that are not ready to be merged or need additional steps, it's best to use the "draft" tag and explain the necessary steps in the PR comment/thread, to have everything together that needs to be considered.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants