Dear Sirs:

There is a problem with windows .asm modules in version 0.9.8a when runing
on XP x64 under WOW64 in a .dll.
The openssl .asm logic pages are marked as non-executable so the
application faults.  This is not a problem
with .asm logic in 0.9.7d.  A quick check will show the segment statement
generated by crypto\perlasm\x86ms.pl
has changed (and not documented in CHANGES).  I reversed the changes as
shown below and now the .asm
runs without problem on XP pro,  XP x64, and Vista 64.

Some details about our tools and tests:
- the application was compiled and linked with Microsoft Visual Studio 6
on XP pro.
- the link map for a .dll or .exe show the openssl .asm logic in segment 4
(ie address 0004:....) and class DATA.
- an .exe with openssl .asm runs without fault on XP x64 only .asm logic
in a .dll has the non-executable page problem.



crypto\perlasm\x86ms.pl changes - remove .model and change _TEXT$ to _TEXT


        TITLE   $file.asm
           .386
<  .model FLAT
-> ;.model FLAT XPx64
   EOF
        push(@out,$tmp);
        }

   sub main'function_begin
        {
        local($func,$extra)[EMAIL PROTECTED];

        push(@labels,$func);

        local($tmp)=<<"EOF";
<  _TEXT\$      SEGMENT PAGE 'CODE'
-> _TEXT        SEGMENT PAGE 'CODE'             ;XPx64
   PUBLIC       _$func
   $extra
   _$func PROC NEAR
        push    ebp
        push    ebx
        push    esi
        push    edi
   EOF
        push(@out,$tmp);
        $stack=20;
        }

   sub main'function_begin_B
        {
        local($func,$extra)[EMAIL PROTECTED];

        local($tmp)=<<"EOF";
<  _TEXT\$      SEGMENT PAGE 'CODE'
-> _TEXT        SEGMENT PAGE 'CODE'             ;XPx64
   PUBLIC       _$func
   $extra
   _$func PROC NEAR
   EOF
        push(@out,$tmp);
        $stack=4;
        }

   sub main'function_end
        {
        local($func)[EMAIL PROTECTED];

        local($tmp)=<<"EOF";
        pop     edi
        pop     esi
        pop     ebx
        pop     ebp
        ret
   _$func ENDP
<  _TEXT\$      ENDS
-> _TEXT        ENDS                            ;XPx64
   EOF
        push(@out,$tmp);
        $stack=0;
        %label=();
        }

   sub main'function_end_B
        {
        local($func)[EMAIL PROTECTED];

        local($tmp)=<<"EOF";
   _$func ENDP
<  _TEXT\$      ENDS
-> _TEXT        ENDS                            ;XPx64
   EOF
        push(@out,$tmp);
        $stack=0;
        %label=();
        }


David Elm
Software Developer
Storage Management

Beta Systems Software of Canada Inc.
Business Line DCI
Suite 600, 736 Eighth Ave SW
Calgary, Alberta, Canada, T2P 1H4
Phone: (403) 231 - 9879
Fax: (403) 266 - 6767
[EMAIL PROTECTED]
www.betasystems.com



[This message is confidential. It may also be privileged or otherwise protected 
by work product immunity or other legal rules. If you have received it by 
mistake please let us know by reply and then delete it from your system; you 
should not copy it or disclose its contents to anyone. All messages sent to and 
from Beta Systems may be monitored to ensure compliance with internal policies 
and to protect our business. Emails are not secure and cannot be guaranteed to 
be error free as they can be intercepted, amended, lost or destroyed, or 
contain viruses. Anyone who communicates with us by email is taken to accept 
these risks.]
______________________________________________________________________
OpenSSL Project                                 http://www.openssl.org
Development Mailing List                       [email protected]
Automated List Manager                           [EMAIL PROTECTED]

Reply via email to