SDK openssl issue

Have a question about our Software Developer Kit? Ask them here.

SDK openssl issue

Postby xenic » Sun Jan 12, 2014 8:48 pm

We have been getting libopenssl updates at OS4Depot and through AmiUpdate for quite a while. The libopenssl header files are installed in the SDK:Local/common/include/openssl/ directory. However, there already exists an SDK:Include/include_h/openssl/ directory in the SDK. If someone compiles or ports a program with include lines like: #include <openssl/xxxx.h> without overriding the default search path on the GCC command line, they will be using a new openssl library with ancient openssl includes (used by amissl ?) dated 2005.

It seems to me like it might be wise for the SDK maintainers to rename the OS4 system openssl/ directory to something like "amiopenssl/" in the next SDK update. Anyone who is porting a program that uses openssl might want to check that they are getting the correct header files when they compile with OS4 system includes present.
AmigaOne X1000 with 2GB memory - OS4.1 FE
xenic
 
Posts: 1160
Joined: Sun Jun 19, 2011 1:06 am

Re: SDK openssl issue

Postby MickJT » Mon Jan 13, 2014 12:46 pm

I'm the one who has currently been maintaining the openssl port on OS4Depot (I hope it's satisfactory. I use a custom RAND_poll function). I haven't personally built anything against AmiSSL, but I'd imagine that it's much easier to just rename those directories when necessary, otherwise you'd have to modify the headers and source of every program you want to build against AmiSSL. I don't know how it is now, but when I first discovered the conflict, I noticed you could still build programs using the old headers, unless the program required a newer feature.
Last edited by MickJT on Tue Jan 14, 2014 5:53 am, edited 1 time in total.
MickJT
 
Posts: 9
Joined: Sat Jun 18, 2011 3:51 pm

Re: SDK openssl issue

Postby xenic » Mon Jan 13, 2014 6:00 pm

@MickJT
I misunderstood what the libopenssl AutoInstall script is doing. Since it appears to be renaming the SDK:Include/include_h/openssl directory, it would be AmiSSL that might be affected by using newer header files and not libopenssl using older header files. It just seems to me like there could eventually be problems. I suspect that this AmiSSL/libopenssl header issue might affect other Amiga platforms too. The only long-term solution I can think of is a new AmiSSL library with a different name and non-conflicting header file directory name. That's probably unlikely to happen. Hopefully, the OS4 Devs are aware that an SDK include directory is being renamed by a 3rd party addon library in case some problems arise.
AmigaOne X1000 with 2GB memory - OS4.1 FE
xenic
 
Posts: 1160
Joined: Sun Jun 19, 2011 1:06 am

Re: SDK openssl issue

Postby MickJT » Tue Jan 14, 2014 5:49 am

There's a potential conflict either way. If people opt to install libopenssl and want to use it, the renaming is necessary. If people mistakenly install it as part of a batch update, then the dialog box (which doesn't block/halt anything) warns you so you can revert back if you wish. So, I think that's the best solution for now, to provide a warning that a directory has been renamed as part of the installation. Any other solution is going to require modifying the source of all past and future programs. If I remember correctly, if both directories exist, then include_h/openssl is favoured and used first.
MickJT
 
Posts: 9
Joined: Sat Jun 18, 2011 3:51 pm


Return to SDK Support

Who is online

Users browsing this forum: No registered users and 2 guests