• decode_subfield()

    From andrew clarke@3:633/267 to Michael Pierce on Friday, February 19, 2021 07:20:46
    On 2021-02-17 14:14:36, Michael Pierce (1:105/81) wrote to andrew clarke:

    still not out of the woods yet though - now getting a different error

    hpt toss scan pack
    SMAPI ERROR: wrongly sized subfield occured!

    There's definitely NQR in the JAM code in the OW2.0 version on Windows:

    H:\tmp\hpt>hpt scan
    1 07:18:16 Start
    1 07:18:16 Start scanning...
    1 07:18:16 EchoTossLogFile not found -> Scanning all areas
    1 07:18:16 Scanning area: jamtest
    Assertion Failed: subfieldNext->Buffer <= (byte *)*subfield + subfield[0]->arraySize, function decode_subfield, file ../src/structrw.c, line 961.
    ABNORMAL TERMINATION

    H:\tmp\hpt>hptlink
    hptlink/w32-wc 1.9.0-cur 2021-02-17

    F 07:18:42 hptlink/w32-wc 1.9.0-cur 2021-02-17
    C 07:18:42 No ImportLog file, linking all Areas
    3 07:18:42 linking area netmail...
    A 07:18:42 Could not open area netmail
    3 07:18:42 linking area jamtest...
    Assertion Failed: subfieldNext->Buffer <= (byte *)*subfield + subfield[0]->arraySize, function decode_subfield, file ../src/structrw.c, line 961.
    ABNORMAL TERMINATION

    I'm unfamiliar with the JAM format and don't really understand the code there. The code in structrw.c is supposed to be portable, but evidently not.

    The good news is OW2.0 HPT doesn't seem to be writing corrupt data, since the MSVC port of HPT (from husky-all-1.9-w32msvc6dll-perl510-hptzip-20201211.zip) can still read JAMTEST:

    H:\tmp\hpt>hpt-msvc scan
    1 07:28:38 Start
    1 07:28:38 Start scanning...
    1 07:28:38 EchoTossLogFile not found -> Scanning all areas
    1 07:28:38 Scanning area: jamtest
    D 07:28:38 Statistics
    D 07:28:38 areas: 1 msgs: 5
    D 07:28:38 exported: 0
    E 07:28:38 Areas summary:
    1 07:28:38 End

    And GoldED doesn't throw any errors reading it.

    --- GoldED+/BSD 1.1.5-b20180707
    * Origin: Blizzard of Ozz, Melbourne, Victoria, Australia (3:633/267)
  • From Michael Pierce@1:105/81 to andrew clarke on Thursday, February 18, 2021 14:18:44
    On 2021-02-17 14:14:36, Michael Pierce (1:105/81) wrote to andrew
    clarke:

    still not out of the woods yet though - now getting a different
    error

    hpt toss scan pack
    SMAPI ERROR: wrongly sized subfield occured!

    There's definitely NQR in the JAM code in the OW2.0 version on
    Windows:

    I'm unfamiliar with the JAM format and don't really understand the
    code there. The code in structrw.c is supposed to be portable, but evidently not.

    The good news is OW2.0 HPT doesn't seem to be writing corrupt data,
    since the MSVC port of HPT (from husky-all-1.9-w32msvc6dll-perl510-hptzip-20201211.zip) can still read JAMTEST:

    And GoldED doesn't throw any errors reading it.

    for some reason, I can not get hpt to "see" any sort of packets?
    I have unzipped the packets in to inbound folder, and hpt does do anything with
    them, even reduced it down to 1 packet. no error from hpt, nor in hpt.log, and tparser is worthless, it does not show any sort of error

    I have hpt in c:\ele (elebbs) so my config is in there as well
    I have tried with the \\ and on this config, it does complain when using \\

    what am I missing?

    below is my current hpt config

    === Cut ===
    # main fidoconfig file
    name Mike's Point
    sysop Michael Pierce
    location Portland, Oregon
    address 1:105/105
    inbound C:\ELE\FIDO\INB\UNSECURE\
    protinbound C:\ELE\FIDO\INB\
    outbound c:\bink\outb
    tempinbound c:\ele\fido\tmp\inb\
    tempoutbound c:\ele\fido\tmp\outb\
    logfiledir c:\ele\log\
    dupehistorydir c:\ele\fido\dupebase\
    msgbasedir c:\ele\msgs\
    echotosslog c:\ele\log\toss.log
    importlog c:\ele\log\import.log
    # Nodelist Section
    nodelist NODELIST.999
    nodelistdir c:\ele\fido\
    FullUpdate c:\ele\fido\NODELIST
    DefaultZone 1
    FidoUserList FIDOUSER.LST
    NodelistFormat standard

    linkwithimportlog kill
    separatebundles yes
    disablepid yes
    disabletid yes
    # hptperlfile c:\ele\fido\lib\hptfunctions.pl
    pack zip "zip -9 -j -q $a $f"
    #pack zip 7z $a$f
    unpack "unzip -j -Loqq $a $f -d $p" 0 504b0304
    # unpack "arc eno $a $p'*.*'" 0 1a

    robotsarea NETMAIL

    robot default
    killrequests yes
    reportsattr loc pvt k/s npd

    robot areafix
    fromname Areafix robot
    robotorigin Areafix robot
    linkdefaults begin
    allowemptypktpwd secure
    packer zip
    areafixautocreate on
    areafixautocreatedefaults -b jam -dupecheck del -dupehistory 14
    echomailflavour direct
    forwardrequests off
    linkdefaults end

    include c:\ele\fido\links
    include c:\ele\fido\route

    netmailarea NETMAIL c:\ele\msgs\netmail -b msg
    badarea BAD c:\ele\msgs\bad -b msg
    dupearea DUPE c:\ele\msgs\dupe -b msg
    localarea PERSONAL.MAIL c:\ele\msgs\personal -b msg

    include c:\ele\fido\areasfido
    netmailflag c:\ele\fido\netmail.out
    === Cut ===


    Michael


    --- GoldED+/LNX 1.1.5-b20180707
    * Origin: Our Awesome Net - Portland, OR - awesome.abon.us (1:105/81)
  • From andrew clarke@3:633/267 to Michael Pierce on Sunday, February 21, 2021 07:59:54
    On 2021-02-19 07:20:46, andrew clarke (3:633/267) wrote to Michael Pierce:

    There's definitely NQR in the JAM code in the OW2.0 version on Windows:

    H:\tmp\hpt>> hpt scan
    1 07:18:16 Start
    1 07:18:16 Start scanning...
    1 07:18:16 EchoTossLogFile not found -> Scanning all areas
    1 07:18:16 Scanning area: jamtest
    Assertion Failed: subfieldNext->Buffer <= (byte *)*subfield + subfield[0]->arraySize, function decode_subfield, file
    ../src/structrw.c, line 961. ABNORMAL TERMINATION

    To my surprise I got this error on FreeBSD too.

    Turns out it was an upstream bug in structrw.c, introduced on 2021-02-14, that affected all platforms.

    old:

    - len = sizeof(JAMSUBFIELD2LIST) + count *
    - (sizeof(JAMSUBFIELD2) - JAM_SF_HEADER_SIZE + 1) + *SubfieldLen;

    new:

    + len = offsetof(JAMSUBFIELD2LIST, subfield) + count *
    + (sizeof(JAMSUBFIELD2) - JAM_SF_HEADER_SIZE + 1) + (size_t)*SubfieldLen;

    Evidently these two things don't do the same thing. :)

    I've reverted the change in the zoomosis/smapi repo, which will hopefully be reverted upstream shortly.

    --- GoldED+/BSD 1.1.5-b20180707
    * Origin: Blizzard of Ozz, Melbourne, Victoria, Australia (3:633/267)
  • From Michael Pierce@1:105/81 to andrew clarke on Saturday, February 20, 2021 16:08:42
    Hello andrew!


    LogLevels 12345789ACDEFGHIJKLMNPQRSTVWX
    ScreenLogLevels 12345789ACDEFGHIJKLMNPQRSTVWX
    LogEchoToScreen On

    I have hpt in c:\ele (elebbs) so my config is in there as well
    I have tried with the \\ and on this config, it does complain
    when using \\

    \ is fine

    set levels to what you posted... it does not generate any error of any kind, I tried with msg format, nothing no errors, it just does not seem to see the packet or open it.. this has also been re-produced by Rick Smith as well

    so what else could be missing?



    Michael


    --- GoldED+/LNX 1.1.5-b20180707
    * Origin: Our Awesome Net - Portland, OR - awesome.abon.us (1:105/81)
  • From andrew clarke@3:633/267 to Michael Pierce on Sunday, February 21, 2021 14:10:40
    On 2021-02-20 16:08:42, Michael Pierce (1:105/81) wrote to andrew clarke:

    LogLevels 12345789ACDEFGHIJKLMNPQRSTVWX
    ScreenLogLevels 12345789ACDEFGHIJKLMNPQRSTVWX
    LogEchoToScreen On

    I have hpt in c:\ele (elebbs) so my config is in there as well
    I have tried with the \\ and on this config, it does complain
    when using \\

    \ is fine

    set levels to what you posted... it does not generate any error of any kind, I tried with msg format, nothing no errors, it just does not seem
    to see the packet or open it.. this has also been re-produced by Rick Smith as well

    so what else could be missing?

    Nothing springs to mind.

    Do you get any output at all? Make sure those LogLevels etc commands come first
    in your HPT.CFG, because HPT processes the config file commands in order.

    If still nothing, post a minimal config file here with the error so I can replicate it.

    You could also run it through a debugger.

    --- GoldED+/BSD 1.1.5-b20180707
    * Origin: Blizzard of Ozz, Melbourne, Victoria, Australia (3:633/267)