Re: WinNT + Apache + mod_ssl + openssl -> VC++6 = doesn't work?!

1999-05-20 Thread Trung Tran-Duc

Ingo Zitzmann <[EMAIL PROTECTED]> writes:

> Hi folks,
> 
> I am trying to compile Apache 1.3.6, mod_ssl-2.2.7-1.3.6,
> opensssl-0.9.2b using VisualC++ 6.0 and apparently it compiles the
> openssl option into apache (I checked it by hiding the ssleay.dll and
> the libeay32.dll) but when I call "apache -l" I don't see the mod_ssl.c.

No, you can't see mod_ssl.c in the output of "apache -l". On NT
mod_ssl is build as an DLL (==DSO). "apache -l" only lists the
modules compiled and statically linked in apachecore.dll.

Just go ahead and configure ssl. This is the ssl-related part of my
httpd.conf

Listen 80
Listen 443

;; NT specific
LoadModule ssl_module modules/ApacheModuleSSL.dll


SSLMutex sem
SSLSessionCache dbm:logs/ssl_gcache_data
SSLSessionCacheTimeout 15
SSLLog logs/ssl.log
SSLLogLevel warn


SSLEngine On
SSLCertificateFile cert/server.crt
SSLCertificateKeyFile cert/server.key.unsecure

ServerName myserver.mydomain.dom

# this is the common stuff for http and https virtual hosts
# DocumentRoot, Alias and the likes
Include conf/tranduc.conf







> > Of course I can't use SSLEnable for example. I followed the
> instructions in install.Win32.
> 
> Can anybody help?
> 
> thanx,
> Ingo.
> 
> 
> __
> Apache Interface to OpenSSL (mod_ssl)   www.modssl.org
> User Support Mailing List  [EMAIL PROTECTED]
> Automated List Manager[EMAIL PROTECTED]

__
Apache Interface to OpenSSL (mod_ssl)   www.modssl.org
User Support Mailing List  [EMAIL PROTECTED]
Automated List Manager[EMAIL PROTECTED]



Re: Apache-MOD-SSL 4 Win

1999-05-12 Thread Trung Tran-Duc

It was me who uploaded that file. I've just zipped all necessary
binaries so people without M$ C compiler can use the software.

It's up to you to configure that stuff. Basically you'll have to
follow these steps

1) unzip it into a root dir on some drive
2) create a subdir conf, put your config files there
3) try to run Apache without SSL first
4) create your site key and cert using openssl.exe
5) modify conf files to add SSL support there

4) and 5) are explained in mod_ssl FAQ

If you still have problems with it, I could create a minimum
config for you, so you can let it run immediately to have a feel
about it.

-t


Alex `Taker` Pircher <[EMAIL PROTECTED]> writes:

> Maybe anyone can help me here.
> 
> 
> Ralf S. Engelschall wrote:
> > 
> > On Thu, May 06, 1999, Alex 'Taker' Pircher wrote:
> > 
> > > A question about
> > > Apache_1.3.6-mod_ssl_2.2.6-openssl_0.9.2b-WIN32-i386.zip
> > > (in http://www.modssl.org/contrib/)
> > >
> > > I want to test SSL under Windows, but what should I do with that
> > > file? Copy it over an existing Apache-1.3.6 installation?
> > >
> > > It won't run because the Configuartion-Files and the Registry-Key
> > > is missing!
> > 
> > Hmmm.. I've neither experiences with Win32 nor have I ever looked at this
> > contributed stuff. It's provided directly by the mod_ssl users for other
> > mod_ssl users.  I just provide the diskspace and location for this stuff.  So
> > you've to ask the guy who created this ZIP archive or at least ask on
> > [EMAIL PROTECTED] for help. Sorry that I cannot help you with this
> > stuff.
> 
> Thx & Greetz,
>  Alex

> [...]
> 

__
Apache Interface to OpenSSL (mod_ssl)   www.modssl.org
User Support Mailing List  [EMAIL PROTECTED]
Automated List Manager[EMAIL PROTECTED]



Re: Basic auth with SSL - again

1999-03-24 Thread Trung Tran-Duc

> > > "Ralf S. Engelschall" <[EMAIL PROTECTED]> wrote:

> [...]
> 
> > Thanks for the answer, Ralf. My problem is that I can't build
> > applications under Win32 platform.
> > 
> > Is anybody able to build and uplownload on
> > ftp://contrib:[EMAIL PROTECTED]/sw/mod_ssl/ (read/write
> > access). an update version of Apache (Win32) with mod_ssl/mod_ssl/2.2.5
> > ?
> 
> Perhaps one of the Win32 users can put a binary there.  I cannot do it,
> because my Win32 box is still totally messed up. 

I've uploaded

Apache_1.3.6-mod_ssl_2.2.6-openssl_0.9.2b-WIN32-i386.zip

to the contrib area.

(The mod_proxy source was patched to fix one crash bug and a bug preventing
cache GC from functioning)

__
Apache Interface to SSLeay (mod_ssl)   www.engelschall.com/sw/mod_ssl/
Official Support Mailing List   [EMAIL PROTECTED]
Automated List Manager   [EMAIL PROTECTED]



Re: Compiling Apache 1.3.4 + mod_ssl 2.2.1 on NT

1999-02-04 Thread Trung Tran-Duc

The fix:

before running nmake, open src/ApacheCore.def, go to the end, and modify it

;; comment out this one
;;  ap_hook_register   @325
ap_hook_call   @326
;; add these two lines
ap_hook_register_I @327
ap_hook_unregister_I @328

Ralf, this is due to the #define in your ap_hook.h

--cut--
#define ap_hook_register(hook,func,ctx) ap_hook_register_I(hook,(void *)(func),ctx)
#define ap_hook_unregister(hook,func)   ap_hook_unregister_I(hook,(void *)(func))
--cut--

-trung

Christian Buysschaert <[EMAIL PROTECTED]> wrote:

> Hi everybody,
> 
> Anybody succeeded in compiling the latest mod_ssl on NT?
> I'm getting the following error...
> 
> -BEGIN WEIRD FORMATTED VC5 OUTPUT-
> cl.exe @C:\TEMP\nma00578.
> buildmark.c
> link.exe @C:\TEMP\nmb00578.
> ApacheCore.def : error LNK2001: unresolved external symbol ap_hook_register
> .\CoreR\ApacheCore.lib : fatal error LNK1120: 1 unresolved externals
> LINK : fatal error LNK1141: failure during build of exports file
> NMAKE : fatal error U1077: 'link.exe' : return code '0x475'
> Stop.
> NMAKE : fatal error U1077: '"c:\program files\devstudio\vc\bin\NMAKE.EXE"' :
> ret
> urn code '0x2'
> Stop.
> -END WEIRD FORMATTED VC5 OUTPUT-
> 
> Ralf, it seems that you added some to-be-exported functions in the
> ApacheCore.def file which he can't seem to be able to link... I'm not
> too familiar with linking so I'll try to take a closer look but if
> you could help already that would be great! ;-)

> [...]
> 

__
Apache Interface to SSLeay (mod_ssl)   www.engelschall.com/sw/mod_ssl/
Official Support Mailing List   [EMAIL PROTECTED]
Automated List Manager   [EMAIL PROTECTED]



Re: ANNOUNCE: 2.1b9-1.3.3 (2.1.0 to-be)

1998-11-17 Thread Trung Tran-Duc

On Mon, 16 Nov 1998 18:08:51 GMT,
  Ralf S. Engelschall <[EMAIL PROTECTED]> wrote:

> On Mon, Nov 16, 1998, Trung Tran-Duc wrote:
> 
> > Ooops. We have problem with patching Makefile on Win32. I'll see to it
> > tomorrow.
> 
> I've looked at it. The appended patch solves it for me.  Please try it out
> also yourself, Trung. 

worked like a charm!! I think you can go ahead with an announcement now


> We have to make sure the Win32-stuff doesn't work as expected for
> 2.1.0. 

doesn't ?! :-)

Anyway I and probably everybody else should know that Windows is a
broken platform. A few days ago I myself ran into a well-known Windows
DLL hell. We cannot overstate the fact that SSLeay's DLLs must be put
on _system_ %PATH%, especially when Apache is intended to run as a
Windows service.

I also have a few suggestions concerning cosmetic aspects of
configure.bat. They don't need to be put into the 2.1 release

1) should we make backups (*.orig) when we patch those win32
makefiles?

2) in Makefile.nt you invoke mod_ssl's makefile with

nmake /nologo CFG="mod_ssl - Win32 %LONG%" -f Makefile
nmake /nologo CFG="mod_ssl - Win32 %LONG%" -f Makefile clean
...


The define CFG="mod_ssl - Win32 %LONG%" has nothing to do here. The
other .mak need it, because they are generated by DevStudio, and it's
the way they do it. Our Makefile is hand written. Also nmake looks for
'makefile' by default, so no need to use the -f option. You can just

nmake /nologo all # or without 'all'
nmake /nologo clean

-trung

P.S. Ralf, thanks for cooperation. It's my first experience with such
a project. Good feeling.

> [...]

__
Apache Interface to SSLeay (mod_ssl)   www.engelschall.com/sw/mod_ssl/
Official Support Mailing List   [EMAIL PROTECTED]
Automated List Manager   [EMAIL PROTECTED]



Re: ANNOUNCE: 2.1b9-1.3.3 (2.1.0 to-be)

1998-11-16 Thread Trung Tran-Duc

Ooops. We have problem with patching Makefile on Win32. I'll see to it
tomorrow.

-trung


On Sun, 15 Nov 1998 16:30:44 GMT,
  Ralf S. Engelschall <[EMAIL PROTECTED]> wrote:

> Except for the final updates of the README files in the distribution and
> Chapter 4 of the User Manual the mod_ssl 2.1 branch is now ready for release.
> To make sure we don't have introduced new heavy bugs here is one more but
> really last Beta version. 
> 
> Test it now (again) and speak up for the 2.1 branch or be quiet later ;-)
> 
> The birth of the final mod_ssl 2.1.0 version is planned for Tuesday, November
> 17th, 1998. Because on this day we then can celebrate two birthdays: a 2.1*1
> birthday and a 2.6*10 birthday... :-)
> 
> Greetings,
>Ralf S. Engelschall
>[EMAIL PROTECTED]
>www.engelschall.com
> 
>   Changes with mod_ssl 2.1b9 (04-Nov-1998 to 15-Nov-1998)
> 
>*) Replaced the pkg.ssldoc/* stuff with the new mod_ssl 2.1 User Manual.
> 
>*) Fixed patching of Makefile.nt under Win32.
> 
>*) Changed test `-e' option to more portable `-r' option.
> 
>*) Fixed again the init round handling: The SSLeay initialization
>   has to be done _every_ time under DSO/DLL situation because
>   there SSLeay is part of the mod_ssl DSO/DLL which is re-loaded.
> 
>*) Under DSO situation the LoadModule directive for libssl.so
>   is now surrounded by , too. This way when
>   -DSSL is not used not even the module is loaded.
> 
>*) Replaced the last global var (ssl_ModConfig) with an ap_global_ctx
>   based approach. This way thread-safety for Win32 and Apache 2.0 
>   can be made more easily.
> 
>*) Added compile time check for EAPI: 
>   mod_ssl now can only be compiled when EAPI is active.
> 
>*) Forward port from 2.0 branch:
>   Now SSLVerifyDepth defaults to 1 and this means the client certificate
>   has to be signed directly by the root CA. The verify depth now is the
>   max number of CAs which are checked: 0 = self-signed only, 1 =
>   self-signed or signed by root-CA, 2 = signed by root-CA or signed by a
>   CA which is signed by the root-CA, etc.
> 
>*) Forward port from 2.0 branch:
>   Now SSLSessionCacheTime defaults to 300s.
> 
>*) Forward port from 2.0 branch:
>   Fixed RSAref instructions in INSTALL file and added more support for
>   implicitly finding the RSA_BASE to the libssl.module script.
> 
>*) Added a SSL_COMPAT configuration rule which is enabled per
>   default. But when you disable it via --disable-rule=SSL_COMPAT the
>   backward compatibility code is not build into mod_ssl.  This provides a
>   little bit better performance for those people who don't need the compat
>   stuff. 
> 
>*) Removed the patch from mod_auth.c by not spreading the -I option for
>   SSLeay. Because with the EAPI only the mod_ssl needs to include SSLeay
>   headers. So we no longer have a conflict with the vendors
>   crypt.h stuff ;-)
> 
>*) Moved the patch from ap_config.h into libssl.module.
> 
>*) Overhauled the mod_ssl distribution tree: Now four packages exists
>   (eapi, sslmod, ssldoc, sslcfg, sslsup) and each contains the patches and
>   corresponding files. Especially the EAPI stuff is now stand-alone and
>   doesn't contain any crypto-related stuff.
> 
>*) Fixed version parsing in configure.bat script (Win32)
> 
>*) Fixed default value for SSLCertificateFile directive.
> 
>*) Added real contents for the environment variable mapping. Now all
>   Apache-SSL 1.x and mod_ssl 2.0.x and the most important Stronghold 2.0.x
>   variables (the ones corresponding to certificate DN fields) are mapped
>   to mod_ssl 2.1 variables.
> 
>*) Added on-the-fly mapping for the Apache-SSL 1.x and mod_ssl
>   2.0.x SSLRequireCipher and SSLBanCipher directives.
> 
>*) Added a useful SSL_CIPHER_EXPORT variable.
> 
>*) Fixed compatibility on-the-fly directive mapping: Now comment and blank
>   lines are correctly recognized by the mapping mechanism so the user no
>   longer gets confusing warnings about obsolete directives when they still
>   occured in comments.
> 
>*) Fixed complex situation where the SSL logfile cannot be opened but the
>   error message should be still logged: to the Apache general error log.
> 
>*) Forward port from 2.0 branch:
>   Make sure the mkcert.sh can only be used by `make certificate' _inside_
>   the Apache source tree.
> __
> Apache Interface to SSLeay (mod_ssl)   www.engelschall.com/sw/mod_ssl/
> Official Support Mailing List   [EMAIL PROTECTED]
> Automated List Manager   [EMAIL PROTECTED]

__
Apache Interface to 

Re: Win32: Apache-1.1.3 + mod_ssl 2.1b8 + mod_jserv

1998-11-09 Thread Trung Tran-Duc

On Mon, 09 Nov 1998 11:18:19 GMT,
  Ralf S. Engelschall <[EMAIL PROTECTED]> wrote:

> On Mon, Nov 09, 1998, Trung Tran-Duc wrote:
> 
> > On Mon, 09 Nov 1998 10:03:23 GMT,
> >   Ralf S. Engelschall <[EMAIL PROTECTED]> wrote:
> > 
> > > [...]
> > > This way we init SSLeay on every init under DSO/DLL situation but not under
> > > Unix/non-DSO. And the pass phrase handling is done only on the first init.
> > 
> > Rhetoric question: what would happen if I change the mod_ssl config,
> > the new private key file is encrypted with _different_ pass phrase and
> > I restart Apache? Of course Apache cannot regain the terminal to ask
> > for the pass phrase. Is it correct? In this case will it fail or hang
> > in reading from an invisible terminal?
> 
> No, it'll not hang because we don't cache the pass phrase.  We cache the
> private key itself. So on restarts the private key (and certificate file) is
> _NOT_ reloaded from disk. It's provided to SSLeay again, yes - but from the
> cache. Because as we discussed some time ago, caching the pass phrase is more
> a security problem than directly caching the private key (because SSLeay
> caches the private key itself, too).
> 
> So we should not have any pass phrase handling problems here.

it means that if I want to change the private key, I have to shutdown
the server and start it again; it does not suffice to send a restart
signal. Right?

__
Apache Interface to SSLeay (mod_ssl)   www.engelschall.com/sw/mod_ssl/
Official Support Mailing List   [EMAIL PROTECTED]
Automated List Manager   [EMAIL PROTECTED]



Re: Win32: Apache-1.1.3 + mod_ssl 2.1b8 + mod_jserv

1998-11-09 Thread Trung Tran-Duc

On Mon, 09 Nov 1998 10:03:23 GMT,
  Ralf S. Engelschall <[EMAIL PROTECTED]> wrote:

> [...]
> This way we init SSLeay on every init under DSO/DLL situation but not under
> Unix/non-DSO. And the pass phrase handling is done only on the first init.

Rhetoric question: what would happen if I change the mod_ssl config,
the new private key file is encrypted with _different_ pass phrase and
I restart Apache? Of course Apache cannot regain the terminal to ask
for the pass phrase. Is it correct? In this case will it fail or hang
in reading from an invisible terminal?

> 
> Can you verify that this code variant works under Win32, too?

Yes.

-trung

__
Apache Interface to SSLeay (mod_ssl)   www.engelschall.com/sw/mod_ssl/
Official Support Mailing List   [EMAIL PROTECTED]
Automated List Manager   [EMAIL PROTECTED]



Re: Win32: Apache-1.1.3 + mod_ssl 2.1b8 + mod_jserv

1998-11-06 Thread Trung Tran-Duc

On Fri, 06 Nov 1998 15:59:30 GMT,
  Ralf S. Engelschall <[EMAIL PROTECTED]> wrote:

> [...]
> Also apache crashes on NT
> > when I try to restart it (apache.exe -k restart). It's inside ssleay.
> > I'm going to debug it...
> 
> Perhaps we have to actually shutdown SSLeay in some way (at the restart)
> before we can re-init it (at the new startup)? Perhaps Tim Hudson has some
> hints for us. Tim? 
> 
> >From the Apache side it's easy: We can do this inside Apache with a callback
> function configured via ap_register_cleanup(). Or inside the new remove_module
> hook of the Extended API. We just have to know what SSLeay functions we have
> to call on server restart time.

No, it's something else. I've solved it. From src/main/http_main.c

--8<--
5568:do { /* restart-pending */

[cut]
ap_init_modules(pconf, server_conf);
[cut]
++generation;
5693:} while (restart_pending);
--8<--

It's run in the master process. I don't know how restart is done on
UNIX, init_module is run in each restart. The master process is the
same. We must be very careful to init everything, especially we cannot
rely on global vars are init'ed to zero and such. On Windoze there is
no fork(), no detach, etc. (We've run into this before, do you
remember?) ssl_ModConfig->nInitCount can be million. We must init
ssleay each time.

-trung

P.S. I'm going to print Apache source to have some reading over the
weekend :-(

Here is the diff

*** ssl_engine_init.c~  Wed Nov 04 13:03:10 1998
--- ssl_engine_init.c   Fri Nov 06 17:21:53 1998
***
*** 137,152 
   *  Ok, now try to solve this totally ugly situation...
   */
  
  if (ssl_ModConfig->nInitCount == 1) {
  ssl_init_SSLeay(s);
  ssl_pphrase_Handle(s, p);
- #ifndef WIN32
  return;
- #endif
  }
  if (ssl_ModConfig->nInitCount == 2) {
  ssl_init_SSLeay(s);
  }
  
  /*
   * Warn the user that he should use the session cache.
--- 137,155 
   *  Ok, now try to solve this totally ugly situation...
   */
  
+ #ifndef WIN32
  if (ssl_ModConfig->nInitCount == 1) {
  ssl_init_SSLeay(s);
  ssl_pphrase_Handle(s, p);
  return;
  }
  if (ssl_ModConfig->nInitCount == 2) {
  ssl_init_SSLeay(s);
  }
+ #else /* WIN32 */
+ ssl_init_SSLeay(s);
+ ssl_pphrase_Handle(s, p);
+ #endif /* !WIN32 */
  
  /*
   * Warn the user that he should use the session cache.


__
Apache Interface to SSLeay (mod_ssl)   www.engelschall.com/sw/mod_ssl/
Official Support Mailing List   [EMAIL PROTECTED]
Automated List Manager   [EMAIL PROTECTED]



Re: ANNOUNCE: mod_ssl 2.1b7 (DSO support!)

1998-10-30 Thread Trung Tran-Duc

On Fri, 30 Oct 1998 16:48:26 GMT,
  Ralf S. Engelschall <[EMAIL PROTECTED]> wrote:

> PS: Trung or others: It should be now possible to also build mod_ssl
> as a .DLL under Win32. I've no experiences here, so I hope you
> contribute a few patches to me which allows us to build mod_ssl
> the same way other Apache modules are build.

Done.


I'm going to make DLL the default for Win32, just like the other
modules. The name is ApacheModuleSSL.DLL. Okay?

Please, wait until Monday. I clean it up a little and send you a diff.
(I've just added a few export declarations and modified the Makefile)

-trung

__
Apache Interface to SSLeay (mod_ssl)   www.engelschall.com/sw/mod_ssl/
Official Support Mailing List   [EMAIL PROTECTED]
Automated List Manager   [EMAIL PROTECTED]



Re: Patch for Win32

1998-10-30 Thread Trung Tran-Duc

On Fri, 30 Oct 1998 12:26:21 GMT,
  Ralf S. Engelschall <[EMAIL PROTECTED]> wrote:

> On Fri, Oct 30, 1998, Dave Paris wrote:
> 
> > Email over the exe and I'll create a self-extracting exe for you.  Just let
> > me know where it should default (expand) to.
> 
> Oh, I was not precise enough. What I actually want is not only a
> self-extracting program. My favorite would be that when I run patch.exe it
> extracts itself (in memory on in current working dir) and immediately runs
> itself. So I can use the packed patch.exe similar to the unpacked patch.exe.
> At least under my C64 times the years ago this was common practice.  Exists
> such stuff for Windows NT? Or did I misunderstand you and you mean exactly
> this? Then it should unpack into the current working directory because this is
> maximum portable, IMHO.

Ralf, I don't see your point here. Why do you want to compress the
patch.exe file? The tarball distribution is a compressed file itself.
Do you have difficulty putting binary file into CVS?

I notice you have patch's source files in ./etc and compile and run it
for UNIX platforms. Can we do the same for Win32? The user must have
the C compiler in any case. I can prepare the makefile and modify
Configure.bat accordingly.

-trung

P.S. Info-ZIP can (almost) do what you want: compress the file, add a
small executable stub to that. The resultant file is a self-extracting
file, which extracts itself in a working dir. The catch is that the
stub is of fixed size; for small files (like patch.exe), it's too big.


patch.exe (~120K) -> patch_exe.zip (~60K) ...

 unzipsfx.exe + patch_exe.zip
...  > patch_exe_zip.exe (~150K)


Not good.


__
Apache Interface to SSLeay (mod_ssl)   www.engelschall.com/sw/mod_ssl/
Official Support Mailing List   [EMAIL PROTECTED]
Automated List Manager   [EMAIL PROTECTED]



Re: Patch faild on WINNT4.0

1998-10-20 Thread Trung Tran-Duc

On Tue, 20 Oct 1998 13:43:04 GMT,
  Ralf S. Engelschall <[EMAIL PROTECTED]> wrote:

> In article <> you wrote:
> 
> > Yes. The beta version are  suposed to work on NT.  I found the problem was
> > in the pathing program.  I found another port of GNU patch (2.1) and it
> > worked.  Now I have it build on NT 4.0 (apache 1.3.3 and mod_ssl 2.1b6)
> > with a few warning messages.  I don't know how serious these warning are.
> > But I'll find out soon.
> 
> FYI: I used patch 2.5 from CygWin32's B19 package. Trung used a native
> compiled patch 2.5. 

I use a Win32 port of patch 2.5 avail. from NTEmacs website

http://www.cs.washington.edu/homes/voelker/ntemacs/contrib/patch-2.5.zip

This version has troubles with LF-only lines in a patchfile. You can

a) either convert LF's in ssl.patch/apache.patch to CR-LF's before
running configure.bat

b) or modify configure.bat to add the switch --binary for the patch
utility.

-trung

__
Apache Interface to SSLeay (mod_ssl)   www.engelschall.com/sw/mod_ssl/
Official Support Mailing List   [EMAIL PROTECTED]
Automated List Manager   [EMAIL PROTECTED]



Re: Installing mod_ssl, error with configure script

1998-10-13 Thread Trung Tran-Duc

"Lin" <[EMAIL PROTECTED]> writes:

> I had the same problem with WINDOWS NT. But I thought that was due to the
> utility incompatibiliies.  Like to know why, too.

For Windows NT you need mod_ssl mod_ssl 2.1b

-trung

__
Apache Interface to SSLeay (mod_ssl)   www.engelschall.com/sw/mod_ssl/
Official Support Mailing List   [EMAIL PROTECTED]
Automated List Manager   [EMAIL PROTECTED]



Re: ANNOUNCE: mod_ssl 2.1b5-1.3.2 (Win32 port)

1998-10-07 Thread Trung Tran-Duc

"Ralf S. Engelschall" <[EMAIL PROTECTED]> writes:

> [...]
> > dll - I build a shared-library version, i.e. at the end I get
> > ssleay32.dll and libeay32.dll. What is linked into ApacheCore.dll and
> > ApacheModuleProxy.dll is the _import_ libraries of those DLLs with
> > symbol refs to the DLLs. To run apache you need the DLLs. I've also
> > built mod_ssl with the static-library version of SSLeay, without any
> > problem. The upside is you don't need those two DLLs. The downside is
> > the SSLeay code is duplicated in ApacheCore.dll and also in
> > ApacheModuleProxy.dll
> 
> Wait, either you or I misunderstood the initial poster. I thought he built
> *mod_ssl* as a .DLL instead of a .LIB. That's why I wondered myself how this
> works.

I also wonder, but I can imagine it. You probably can create
mod_ssl.dll or something, which gets loaded when apache.exe starts.
I'm not sure about the purpose of this approach though.

You definitely cannot build ApacheModuleSSL.dll and use LoadModule in
config file. 

>  What you mean is whether SSLeay is built as .DLL and/or .LIB. Here
> I thing a .DLL is useful, too. Hmmm... about what we're now
> speaking?

I'm talking about SSLeay statically/dynamically linked into
ApacheCore.dll and ApacheModuleProxy.dll. To quote the original poster

 On Sun, Oct 04, 1998, Michael Lechner wrote:

Michael Lechner> My first feedback: it runs (and has some crashes due to Microsofts
Michael Lechner> handling of allocations in DLLS - it worked after I linked SSL
Michael Lechner> statically)- I'll send you some suggestions later.

> 
> >[...]
> > btw. I noticed that mod_proxy on win32 can crash Apache if the browser
> > cancel the transfer. The bug is on the Apache bug DB. I've got a quick
> > (and dirty) fix for that. Runs okay since then.
> 
> I only read about a hack where an existing "Listen" directive
> should solve the problem. Is this your fix or do you have another?

It's another one, which fix the PR#2083:

Win32

When accessing a file through the mod_proxy, clicking Stop in
your browser will cause the proxy module to crash. However this does
not crash the Apache server and a new proxy module is spawned.

The bug has something to do with null pointer dereference. The diff is
attached at the end of this mail. (I don't know how to submit fixes
like this to apache.org)

Btw. I looked in the source of mod_proxy a little and I don't like the
way how the cache-related info (temp file name, file descriptor,) is
handled. I'm not surprised that there is such a bug can happen.

Anyway, it seems working now.

-trung


diff -Ncr ../apache_1.3.2/src/modules/proxy/proxy_util.c 
./src/modules/proxy/proxy_util.c
*** ../apache_1.3.2/src/modules/proxy/proxy_util.c  Mon Aug 31 21:51:59 1998
--- ./src/modules/proxy/proxy_util.cWed Oct 07 19:20:44 1998
***
*** 591,598 
   (c->len * c->cache_completion < total_bytes_rcv);
  
  if (! ok) {
! ap_pclosef(c->req->pool, c->fp->fd);
! c->fp = NULL;
  unlink(c->tempfile);
c = NULL;
  }
--- 591,600 
   (c->len * c->cache_completion < total_bytes_rcv);
  
  if (! ok) {
! if (c->fp != NULL) { /* <= trung */
! ap_pclosef(c->req->pool, c->fp->fd);
! c->fp = NULL;
! }
  unlink(c->tempfile);
c = NULL;
  }

__
Apache Interface to SSLeay (mod_ssl)   www.engelschall.com/sw/mod_ssl/
Official Support Mailing List   [EMAIL PROTECTED]
Automated List Manager   [EMAIL PROTECTED]



Re: ANNOUNCE: mod_ssl 2.1b5-1.3.2 (Win32 port)

1998-10-07 Thread Trung Tran-Duc

"Ralf S. Engelschall" <[EMAIL PROTECTED]> writes:

> On Mon, Oct 05, 1998, Michael Lechner wrote:
> 
> >[...]
> > That was my approach too - however you should change your
> > installation instructions:
> > >>  o Create the all-in-one SSLeay Makefile for building under Win32:
> > >>$ perl util\mk1mf.pl no-asm dll VC-WIN32 > makefile.win32
> >^
> 
> What's wrong here? These are the arguments Trung used.
> You mean we can allow assembler stuff, right? Yes, why not.
> But I'll ask Trung why he used "no-asm" initially...

no-asm - I don't have MASM (the MS Assembler) on my machine (Some code
in SSLeay has an assembler version for speed reason) If you have MASM
you can leave the switch out.

dll - I build a shared-library version, i.e. at the end I get
ssleay32.dll and libeay32.dll. What is linked into ApacheCore.dll and
ApacheModuleProxy.dll is the _import_ libraries of those DLLs with
symbol refs to the DLLs. To run apache you need the DLLs. I've also
built mod_ssl with the static-library version of SSLeay, without any
problem. The upside is you don't need those two DLLs. The downside is
the SSLeay code is duplicated in ApacheCore.dll and also in
ApacheModuleProxy.dll

In any case you need to compile with the /MD flags, meaning your
program and its DLLs use C runtime in MSVCRT.DLL. No other option
here, because the same flag is used for Apache and at least Perl.

Mixing static and dynamic C runtimes in different DLLs in the same
process can lead to big problems (I think)

> 
> > No! You can use ".EXP"-(export)-tables so these restrictions are not
> > on WIN32.  
> 
> Ah, nice. Let us know details when available, i.e. patches ;-)

I do not understand what the .EXP file is for.

-trung

btw. I noticed that mod_proxy on win32 can crash Apache if the browser
cancel the transfer. The bug is on the Apache bug DB. I've got a quick
(and dirty) fix for that. Runs okay since then.


__
Apache Interface to SSLeay (mod_ssl)   www.engelschall.com/sw/mod_ssl/
Official Support Mailing List   [EMAIL PROTECTED]
Automated List Manager   [EMAIL PROTECTED]