Discussion:
A GnuTLS-Problem - problems fetchin emails using RISC OS
(too old to reply)
Alexander Ausserstorfer
2018-12-16 15:25:46 UTC
Permalink
People complaining that

http://home.chiemgau-net.de/ausserstorfer/Computer/POP3S16April2016GnuTLS3-4.zip
(840 kB) doesn't work on older machines (Risc PC).

I don't know what exactly the problem is. It may be that the ported
GnuTLS3.4 isn't compatible to the 26 bit instruction set. I don't know.

http://www.riscos.info/packages/LibraryDetails.html

I compile it using the commands

gcc -O3 -static POP3S16Dec2018.c -o!RunImagePOP3S -ILibGNUTLS:
-LLibGMP: -lgmp -LLibGNUTLS: -lgnutls -LLibGPGError: -lgpg-error
-LLibNettle: -lhogweed -lnettle -LLibTASN1: -ltasn1 -LZlib1g: -lz
-LLibGetText: -lintl

Some people cannot fetch their emails anymore using POP3S with an older
version of GnuTLS or !Hermes from Web.de here in Germany. May be that
the supported cipher suites are too old.

Thanks for your help!

Alex
--
http://home.chiemgau-net.de/ausserstorfer/
Mein Gott, warum hast du mich verlassen?
Ron
2018-12-16 22:32:21 UTC
Permalink
Post by Alexander Ausserstorfer
People complaining that
http://home.chiemgau-net.de/ausserstorfer/Computer/POP3S16April2016GnuTLS3-4.zip
(840 kB) doesn't work on older machines (Risc PC).
I don't know what exactly the problem is. It may be that the ported
GnuTLS3.4 isn't compatible to the 26 bit instruction set. I don't know.
http://www.riscos.info/packages/LibraryDetails.html
I compile it using the commands
-LLibGMP: -lgmp -LLibGNUTLS: -lgnutls -LLibGPGError: -lgpg-error
-LLibNettle: -lhogweed -lnettle -LLibTASN1: -ltasn1 -LZlib1g: -lz
-LLibGetText: -lintl
Some people cannot fetch their emails anymore using POP3S with an older
version of GnuTLS or !Hermes from Web.de here in Germany. May be that
the supported cipher suites are too old.
Thanks for your help!
Alex
Something similar happened to me while using !POP3S with gmail.
I rebuilt the autobuilder gnutls with the latest source available then
rebuilt on my Iyonix your source code and everything is still working to
this day.
Probably checking your version of gnutls, and maybe the autobuilder
could be fixed to a newer version than the default if necessary.
It could be that a newer version just has not been put in the
downloads area for too long? is that the one you are using?

The default GCCSDK builds for architecture V3 which should be fine for
older machines, I think there was little difference between v2 and v3 so
should be OK for older than Architecture V3 also.
Arch V3 started with A540/A5000 era, Arch V4 started with StrongArm
RiscPC, probably also the RISCOS 6 hardware?

Alan has uploaded OpenSSL1.1.1 to the autobuilder.
This version drops ssl3 and anything else insecure.

It comes with assembler routines for armv4 and newer.
So there is a boost for machines of x2 over default v3
The arm6 vfp version is faster again.

Running the optional testsuite:
Iyonix with armv3 650 seconds
Iyonix with armv4 (asm) 339 seconds
PiZero with arm6zk vfp 216 seconds

I have built my fetchmail port and an ssl version of curl without
problems so far.
A quick look on riscos.info and openssl1.1.1 isn't available as a
download yet.
I can put the versions up on my google drive for download if you wish
to try them?

Cheers, RonM.
Alexander Ausserstorfer
2018-12-16 23:25:25 UTC
Permalink
Post by Ron
I rebuilt the autobuilder gnutls with the latest source available then
rebuilt on my Iyonix your source code and everything is still working to
this day.
Sorry. What is the autobuilder? I just have running both GCC and
DDE here.
Post by Ron
I can put the versions up on my google drive for download if you wish
to try them?
That would be nice! Can you send me a link? Many thanks!

Ciao,

Alex
--
http://home.chiemgau-net.de/ausserstorfer/
Beachte bitte auch die Rückseite dieses Schreibens!
Ron
2018-12-17 00:25:50 UTC
Permalink
Post by Alexander Ausserstorfer
Post by Ron
I rebuilt the autobuilder gnutls with the latest source available then
rebuilt on my Iyonix your source code and everything is still working to
this day.
Sorry. What is the autobuilder? I just have running both GCC and
DDE here.
Post by Ron
I can put the versions up on my google drive for download if you wish
to try them?
That would be nice! Can you send me a link? Many thanks!
Ciao,
Alex
Ok I will start with just the !POP3S !Runfile I built with a later
gnutls.
If you say this works I will find the library I used and upload that.
If that does not work, I will have to try building a newer gnutls.

Will organise the 3 libssl versions over the next day also.

The link for the RISC_OS google drive directory is
https://drive.google.com/open?id=1TGAXW98WOXOjF5NSPKc2CelduSTxHvwx

I'm new to GoogleDrive, I think you need a javascript browser.
It will be interesting to see if I can add things to the folder
without needing to generate a new link.

Cheers RonM.
Alexander Ausserstorfer
2018-12-17 17:45:48 UTC
Permalink
Post by Ron
Ok I will start with just the !POP3S !Runfile I built with a later
gnutls.
If you say this works I will find the library I used and upload that.
It works fine on the Raspberry Pi here
Post by Ron
If that does not work, I will have to try building a newer gnutls.
but not on the Risc PC:

POP3S - E-Mail-fetcher with TLS for RISC OS
Developer Version
09. July 2014

pop3.web.de

Fatal signal received: Illegal Instruction

Stack backtrace:

Running thread 0x194208
( 1bfff30) pc: 150e9c lr: 151340 sp: 1bfff34 __write_backtrace()
( 1bfffa0) pc: 150fb4 lr: 12c2b8 sp: 1bfffa4 __unixlib_raise_signal()
( 1bfffb0) pc: 12c1bc lr: d5164 sp: 1bfe51c __h_cback()

Register dump at 01bfffb4:

a1: 1b09b3 a2: 1b09b4 a3: 1bfe51c a4: 0
v1: 1d v2: 1b09b3 v3: 1b09b3 v4: 1d
v5: dec1c52e v6: 19002c sl: 1bfe208 fp: 1bfe584
ip: cab7e4bc sp: 1bfe51c lr: 800d5164 pc: 600e492c
Mode USR, flags set: nZCvif

000e4918 : .@`å : e5604001 : STRB R4,[R0,#-1]!
000e491c : .0Sâ : e2533001 : SUBS R3,R3,#1
000e4920 : ùÿÿ. : 1afffff9 : BNE &000E490C
000e4924 : ð.½è : e8bd0df0 : LDMIA R13!,{R4-R8,R10,R11}
000e4928 : .ÿ/á : e12fff1e : BX R14
000e492c : ***@qå : e5714001 : LDRB R4,[R1,#-1]!
000e4930 : .Prå : e5725001 : LDRB R5,[R2,#-1]!
000e4934 : .P%à : e0255004 : EOR R5,R5,R4
000e4938 : .P`å : e5605001 : STRB R5,[R0,#-1]!

( 1bfe584) pc: d50b8 lr: b4800 sp: 1bfe588 nettle_salsa20r12_crypt()
( 1bfe62c) pc: b4614 lr: 14510 sp: 1bfe630 wrap_nettle_rnd()
( 1bfe69c) pc: 143d0 lr: 195a8 sp: 1bfe6a0 send_client_hello()
( 1bfe6c8) pc: 1845c lr: 9200 sp: 1bfe6cc gnutls_handshake()
( 1bfefec) pc: 8f04 lr: 139cb4 sp: 1bfeff0 main()

*

So we have with your version exactly the same problem as with the latest
one on my website which includes GnuTLS 3.4. My question is why this is
happen. With GnuTLS 2.12 it was working also on the Risc PC but this
version seems to not work with accounts of web.de anymore.
Post by Ron
Will organise the 3 libssl versions over the next day also.
The link for the RISC_OS google drive directory is
https://drive.google.com/open?id=1TGAXW98WOXOjF5NSPKc2CelduSTxHvwx
Thanks for the files. It doesn't work with !NetSurf here. It works also
very slow on my Asus Eee PC. I don't understand the sense of Google
drive. It produces a lot of traffic. A direct link like

http://home.chiemgau-net.de/ausserstorfer/Temp/2018-12-17/libgnutls-dev_3.5.8-1.zip
(2507 kB)

http://home.chiemgau-net.de/ausserstorfer/Temp/2018-12-17/pop3s_runimage.zip
(789 kB)

http://home.chiemgau-net.de/ausserstorfer/Temp/2018-12-17/smtps_runimage.zip
(788 kB)

would have been enough. These are your files so everybody can download
it now by just one click. It is so easy to do that. If it is a problem
for you, I will delete the files.

Thanks,

Alex
--
http://home.chiemgau-net.de/ausserstorfer/
Der Geist ist die Freiheit. (Frei.Wild)
Ron
2018-12-17 20:27:49 UTC
Permalink
Post by Alexander Ausserstorfer
Post by Ron
Ok I will start with just the !POP3S !Runfile I built with a later
gnutls.
If you say this works I will find the library I used and upload that.
It works fine on the Raspberry Pi here
Post by Ron
If that does not work, I will have to try building a newer gnutls.
It is odd that those !Runfiles are working on my Iyonix but not on the
RiscPC, I have seen a small C language mistake work OK on the Iyonix but
error on the Raspberry Pi once.
It is like the Iyonix is more tolerant.
I have not tried the libgnutls28_3.5.8-1.zip I uploaded.
I built it last night from debian stable but it is likely to be newer
than what I built my runfiles with. Could be worth trying building your
apps with it. The only other thing I can think of is to update the other
libraries in use, the backtrace shows a crash near a call to nettle or
crypt I think gnutls pulls in an external libcrypt so might be a problem
for all of the gnutls builds (new or old)

I dont mind you hosting the files, they'll have to be updated when we
fix them. Might have to label the current Runfiles 'Iyonix and newer'
but it sounds like they are no improvement over what you have anyway.

Re Google Drive,
Yes it's a bitch with Netsurf as it not only hides the shared folder but
also presents a login which acyually has nothing to do with what is
freely available when using javascript.
It is allowing me to upload files to the allready shared folder so for
public use, a bookmark of the link should always work.

Will rebuild crypt nettle with new stable then build libgnutls28 again.

Cheers RonM
Ron
2018-12-17 23:03:28 UTC
Permalink
Post by Ron
Will rebuild crypt nettle with new stable then build libgnutls28 again.
Cheers RonM
OK I started from scratch and built all the libraries that are pulled in
by the libraries that are used in !POP3S
They are all from the current stable/stretch repository.
Should be at the same google drive link.

It is worth trying a bigger wimpslot when unixlib aborts, newer stuff
often gets bigger.
Another idea would be to try the RiscPC using gcc without the optimise
flag.

Let us know if compiling with those libraries improves things.
Note that the gnutls28 is renewed/rebuilt also.

Cheers RonM.
Alexander Ausserstorfer
2018-12-19 17:57:51 UTC
Permalink
Post by Ron
Post by Ron
Will rebuild crypt nettle with new stable then build libgnutls28 again.
Cheers RonM
OK I started from scratch and built all the libraries that are pulled in
by the libraries that are used in !POP3S
They are all from the current stable/stretch repository.
Should be at the same google drive link.
It is worth trying a bigger wimpslot when unixlib aborts, newer stuff
often gets bigger.
Another idea would be to try the RiscPC using gcc without the optimise
flag.
Let us know if compiling with those libraries improves things.
Note that the gnutls28 is renewed/rebuilt also.
Thank you very much for your help, support, work & time!

Here is what we got after starting the !Runimage file of

mail_applications -> armv3(all) -> pop3s-18th-dec.zip on a Risc PC 700
with StrongARM:

| POP3S - E-Mail-fetcher with TLS for RISC OS
| Developer Version 16. April 2016
| GnuTLS version 3.5.8
|
| pop3.web.de
|
| Fatal signal received: Illegal Instruction
|
| Stack backtrace:
|
| Running thread 0x1fba98 (Main Thread)
| ( 1bfff30) pc: 181838 lr: 181ce4 sp: 1bfff34 __write_backtrace()
| ( 1bfffa0) pc: 181958 lr: 15c408 sp: 1bfffa4 __unixlib_raise_signal()
| ( 1bfffb0) pc: 15c30c lr: f3e88 sp: 1bfe508 __h_cback()
|
| Register dump at 01bfffb4:
|
| a1: 2185db a2: 2185dc a3: 1bfe508 a4: 0
| v1: 1d v2: 2185db v3: 2185db v4: 1d
| v5: 1720a31a v6: 1f7808 sl: 1bfe208 fp: 1bfe570
| ip: f76da8e4 sp: 1bfe508 lr: 800f3e88 pc: 600f2e40
| Mode USR, flags set: nZCvif
|
| 000f2e2c : .@`å : e5604001 : STRB R4,[R0,#-1]!
| 000f2e30 : .0Sâ : e2533001 : SUBS R3,R3,#1
| 000f2e34 : ùÿÿ. : 1afffff9 : BNE &000F2E20
| 000f2e38 : ð.½è : e8bd0df0 : LDMIA R13!,{R4-R8,R10,R11}
| 000f2e3c : .ÿ/á : e12fff1e : BX R14
| 000f2e40 : ***@qå : e5714001 : LDRB R4,[R1,#-1]!
| 000f2e44 : .Prå : e5725001 : LDRB R5,[R2,#-1]!
| 000f2e48 : .P%à : e0255004 : EOR R5,R5,R4
| 000f2e4c : .P`å : e5605001 : STRB R5,[R0,#-1]!
|
| ( 1bfe570) pc: f3ddc lr: b9594 sp: 1bfe574 nettle_salsa20r12_crypt()
| ( 1bfe5bc) pc: b9528 lr: b994c sp: 1bfe5c0 wrap_nettle_rnd_nonce.isra.0()
| ( 1bfe5cc) pc: b9928 lr: 37be0 sp: 1bfe5d0 wrap_nettle_rnd()
| ( 1bfe5f0) pc: 37b6c lr: 14d7c sp: 1bfe5f4 gnutls_rnd()
| ( 1bfe684) pc: 14c20 lr: 1ae0c sp: 1bfe688 send_client_hello()
| ( 1bfe6b0) pc: 19c58 lr: 9668 sp: 1bfe6b4 gnutls_handshake()
| ( 1bfefec) pc: 9380 lr: 16a230 sp: 1bfeff0 main()
|
| *

I have now idea why this is happen and what's going on. It seems to run
properly on my Raspberry Pi, though.

Alex
--
http://home.chiemgau-net.de/ausserstorfer/
Humanitas sit lex suprema.
Ron
2018-12-19 20:10:48 UTC
Permalink
Post by Alexander Ausserstorfer
Post by Ron
Post by Ron
Will rebuild crypt nettle with new stable then build libgnutls28 again.
Cheers RonM
OK I started from scratch and built all the libraries that are pulled in
by the libraries that are used in !POP3S
They are all from the current stable/stretch repository.
Should be at the same google drive link.
It is worth trying a bigger wimpslot when unixlib aborts, newer stuff
often gets bigger.
Another idea would be to try the RiscPC using gcc without the optimise
flag.
Let us know if compiling with those libraries improves things.
Note that the gnutls28 is renewed/rebuilt also.
Thank you very much for your help, support, work & time!
Here is what we got after starting the !Runimage file of
mail_applications -> armv3(all) -> pop3s-18th-dec.zip on a Risc PC 700
| POP3S - E-Mail-fetcher with TLS for RISC OS
| Developer Version 16. April 2016
| GnuTLS version 3.5.8
|
| pop3.web.de
|
| Fatal signal received: Illegal Instruction
|
|
| Running thread 0x1fba98 (Main Thread)
| ( 1bfff30) pc: 181838 lr: 181ce4 sp: 1bfff34 __write_backtrace()
| ( 1bfffa0) pc: 181958 lr: 15c408 sp: 1bfffa4 __unixlib_raise_signal()
| ( 1bfffb0) pc: 15c30c lr: f3e88 sp: 1bfe508 __h_cback()
|
|
| a1: 2185db a2: 2185dc a3: 1bfe508 a4: 0
| v1: 1d v2: 2185db v3: 2185db v4: 1d
| v5: 1720a31a v6: 1f7808 sl: 1bfe208 fp: 1bfe570
| ip: f76da8e4 sp: 1bfe508 lr: 800f3e88 pc: 600f2e40
| Mode USR, flags set: nZCvif
|
| 000f2e30 : .0Sâ : e2533001 : SUBS R3,R3,#1
| 000f2e34 : ùÿÿ. : 1afffff9 : BNE &000F2E20
| 000f2e38 : ð.½è : e8bd0df0 : LDMIA R13!,{R4-R8,R10,R11}
| 000f2e3c : .ÿ/á : e12fff1e : BX R14
| 000f2e44 : .Prå : e5725001 : LDRB R5,[R2,#-1]!
| 000f2e48 : .P%à : e0255004 : EOR R5,R5,R4
| 000f2e4c : .P`å : e5605001 : STRB R5,[R0,#-1]!
|
| ( 1bfe570) pc: f3ddc lr: b9594 sp: 1bfe574 nettle_salsa20r12_crypt()
| ( 1bfe5bc) pc: b9528 lr: b994c sp: 1bfe5c0 wrap_nettle_rnd_nonce.isra.0()
| ( 1bfe5cc) pc: b9928 lr: 37be0 sp: 1bfe5d0 wrap_nettle_rnd()
| ( 1bfe5f0) pc: 37b6c lr: 14d7c sp: 1bfe5f4 gnutls_rnd()
| ( 1bfe684) pc: 14c20 lr: 1ae0c sp: 1bfe688 send_client_hello()
| ( 1bfe6b0) pc: 19c58 lr: 9668 sp: 1bfe6b4 gnutls_handshake()
| ( 1bfefec) pc: 9380 lr: 16a230 sp: 1bfeff0 main()
|
| *
I have now idea why this is happen and what's going on. It seems to run
properly on my Raspberry Pi, though.
Alex
It still /appears/ to be a problem with nettle/gcrypt but I'm no good at
interpreting the machine code above that. Any advice from Druck?
Would running Armalyser on the libraries show any incompatible code?

The Dec18 !Runimage's are OK on my Iyonix also.
If you dont have a Strongarm machine at home it will be hard to try
different things. I might pull my one out of storage over the holidays.

There may be gcc options (suggestions anyone?) that could be tried. It
doesn't take long to compile each time, which is good.

It doesn't look like using different versions of the libraries has
helped, but at least the set at my google drive are all current stable
libs and not a mix of different eras.

The RiscPC does use a different memory system to RISC OS 5 but as long
as the wimpslot is big enough it shouldn't matter.
The !RunImage is over 2MB now.
I noticed if the wimpslot is close to the edge, it can fail when large
emails come through, just give it plenty (while testing anyway).

Ronald(NZ time)
druck
2018-12-20 08:11:21 UTC
Permalink
Post by Ron
Post by Alexander Ausserstorfer
| 000f2e3c : .ÿ/á : e12fff1e : BX R14
I have now idea why this is happen and what's going on. It seems to run
properly on my Raspberry Pi, though.
Alex
It still /appears/ to be a problem with nettle/gcrypt but I'm no good at
interpreting the machine code above that. Any advice from Druck?
Would running Armalyser on the libraries show any incompatible code?
You can see the incompatible code right there, its the BX instruction.
It was originally a Thumb instruction, but is also in Thumb 2, which is
supported by the ARMv6 and later processors in the Raspberry Pi, but not
by processors in earlier machines such as the Risc PC and Iyonix.

The code needs to be recompiled to target ARMv3, to work with all Risc
PCs and later, or ARMv4 for the StrongARM and later.

---druck
n***@sprow.co.uk
2018-12-20 08:00:04 UTC
Permalink
Post by Alexander Ausserstorfer
mail_applications -> armv3(all) -> pop3s-18th-dec.zip on a Risc PC 700
| POP3S - E-Mail-fetcher with TLS for RISC OS
| Developer Version 16. April 2016
| GnuTLS version 3.5.8
| 000f2e30 : .0Sâ : e2533001 : SUBS R3,R3,#1
| 000f2e34 : ùÿÿ. : 1afffff9 : BNE &000F2E20
| 000f2e38 : ð.½è : e8bd0df0 : LDMIA R13!,{R4-R8,R10,R11}
| 000f2e3c : .ÿ/á : e12fff1e : BX R14
I have now idea why this is happen and what's going on. It seems to run
properly on my Raspberry Pi, though.
This is the same problem (even the same instruction!) as I reported to you by email on 13-Aug-2018. BX R14 is an ARMv5 instruction, but the Risc PC is ARMv4 (if StrongARM) or ARMv3 (if ARM610/710), so you get an undefined instruction fault.

I'm afraid I can't help figuring out which combination of switches to GCC (or maybe the linker?) will solve that, but that's the problem,
Sprow.
Alexander Ausserstorfer
2018-12-20 18:03:43 UTC
Permalink
On Wednesday, 19 December 2018 17:58:43 UTC, Alexander Ausserstorfer
Post by Alexander Ausserstorfer
mail_applications -> armv3(all) -> pop3s-18th-dec.zip on a Risc PC 700
| POP3S - E-Mail-fetcher with TLS for RISC OS
| Developer Version 16. April 2016
| GnuTLS version 3.5.8
| 000f2e30 : .0Sâ : e2533001 : SUBS R3,R3,#1
| 000f2e34 : ùÿÿ. : 1afffff9 : BNE &000F2E20
| 000f2e38 : ð.½è : e8bd0df0 : LDMIA R13!,{R4-R8,R10,R11}
| 000f2e3c : .ÿ/á : e12fff1e : BX R14
I have now idea why this is happen and what's going on. It seems to run
properly on my Raspberry Pi, though.
This is the same problem (even the same instruction!) as I reported to
you by email on 13-Aug-2018. BX R14 is an ARMv5 instruction, but the
Risc PC is ARMv4 (if StrongARM) or ARMv3 (if ARM610/710), so you get
an undefined instruction fault.
I'm afraid I can't help figuring out which combination of switches to
GCC (or maybe the linker?) will solve that, but that's the problem,
Thanks. I'm aware of that. I'm afraid that I cannot find your email
anymore.

Is the problem, that we (Ron, myself) compiled the code on the Iyonix PC
or on the Raspberry Pi? Because I cannot find any switches in the way I
compiled the code here to the time I compiled it on the Risc PC.
Nowadays, I have no Risc PC anymore to try it to compile it there. Does
!GCC recognize the machine it runs on and optimise automatically the
code to it?

A.
--
http://home.chiemgau-net.de/ausserstorfer/
Der Geist ist die Freiheit. (Frei.Wild)
David Higton
2018-12-20 19:52:07 UTC
Permalink
Post by Ron
Post by Ron
Will rebuild crypt nettle with new stable then build libgnutls28 again.
Cheers RonM
OK I started from scratch and built all the libraries that are pulled in
by the libraries that are used in !POP3S
They are all from the current stable/stretch repository.
Should be at the same google drive link.
It is worth trying a bigger wimpslot when unixlib aborts, newer stuff
often gets bigger.
Another idea would be to try the RiscPC using gcc without the optimise
flag.
Let us know if compiling with those libraries improves things.
Note that the gnutls28 is renewed/rebuilt also.
What is the reason for trying to build POP3S? Is it simply to be able
to collect email from a server that requires SSL/TLS? Because if
that's all, you could instead use the current build of AntiSpam.

AS doesn't /have/ to delete anything; it can be used simply as a
transport. Recent builds support SSL/TLS using the beta AcornSSL
module available from ROOL.

There is a companion app to send email via SMTP using SSL/TLS.

All free of charge.

Dave
Ronald
2018-12-20 20:58:50 UTC
Permalink
Post by David Higton
Post by Ron
Post by Ron
Will rebuild crypt nettle with new stable then build libgnutls28 again.
Cheers RonM
OK I started from scratch and built all the libraries that are pulled in
by the libraries that are used in !POP3S
They are all from the current stable/stretch repository.
Should be at the same google drive link.
It is worth trying a bigger wimpslot when unixlib aborts, newer stuff
often gets bigger.
Another idea would be to try the RiscPC using gcc without the optimise
flag.
Let us know if compiling with those libraries improves things.
Note that the gnutls28 is renewed/rebuilt also.
What is the reason for trying to build POP3S? Is it simply to be able
to collect email from a server that requires SSL/TLS? Because if
that's all, you could instead use the current build of AntiSpam.
AS doesn't /have/ to delete anything; it can be used simply as a
transport. Recent builds support SSL/TLS using the beta AcornSSL
module available from ROOL.
There is a companion app to send email via SMTP using SSL/TLS.
All free of charge.
Dave
That may be, but if the GCCSDK is putting out wrongly we want to know
why if possible for future use.
Druck and Sprow have simplified the task at hand
A grep built with regex used like
grep -obUaP "\xe1\x2f\xff\x1e" /some/binary
reportedly works,and might help look through some libraries on the
cross compiler environment to see how widespread it is or point to
where the error is coming from.

I dont know if all the generic gcc arm switches are available in
GCCSDK gcc, there is genericly
-maps26 and -march=strongarm110 -mtune=strongarm110 type of thing
but the default of archv4 has been OK in the past.

Found my no 1 RiscPC SA last night but it has been 4-5 years,
and will take a bit of getting everything connected.

Ronald
Ronald
2018-12-21 00:28:07 UTC
Permalink
Post by Ronald
grep -obUaP "\xe1\x2f\xff\x1e" /some/binary
reportedly works,and might help look through some libraries on the
cross compiler environment to see how widespread it is or point to
where the error is coming from.
I dont know if all the generic gcc arm switches are available in
GCCSDK gcc, there is genericly
-maps26 and -march=strongarm110 -mtune=strongarm110 type of thing
the arch is already v4 so that would be -mcpu=strongarm110
Post by Ronald
but the default of archv4 has been OK in the past.
Found my no 1 RiscPC SA last night but it has been 4-5 years,
and will take a bit of getting everything connected.
I think the requirement for the BX instruction to be present
would be E12FFF or to be sure not to be caught out by byte order
also FF2FE1
Neither returned hits in the static !RunImage, reducing down to
combinations of \xe1 and \x2f provided a few hits to show the grep
method does work.

I guess disassembling the !RunImage and text searching for BX
might also verify that there is no such instruction.
Puzzling then, where does the BX come from, the result of unixlib or
32bit library runtime? Getting my own RiscPC going will be an important
next step.

Ronald
n***@sprow.co.uk
2018-12-21 08:39:38 UTC
Permalink
Post by Ronald
I think the requirement for the BX instruction to be present
would be E12FFF or to be sure not to be caught out by byte order
also FF2FE1
Neither returned hits in the static !RunImage [...]
Puzzling then, where does the BX come from
Then that search technique doesn't work. Dropping the !RunImage onto StrongEd and searching for "BX" gives 6 hits (of E12FFF1E),
Sprow.
Ronald
2018-12-21 10:29:05 UTC
Permalink
Post by n***@sprow.co.uk
Post by Ronald
I think the requirement for the BX instruction to be present
would be E12FFF or to be sure not to be caught out by byte order
also FF2FE1
Neither returned hits in the static !RunImage [...]
Puzzling then, where does the BX come from
Then that search technique doesn't work. Dropping the !RunImage onto StrongEd and searching for "BX" gives 6 hits (of E12FFF1E),
Sprow.
OK I will try that, text search on the binary and it works?
I have built libnettle using --disable-assembler and the !RunImage is
working on my SA RiscPC.
Alex, I have uploaded it and it looks like it will work until the
problem is found in the assembler routines.
Looking at nettle6 in the autobuilder, it could do with some work, It
builds common objects for both static and shared libs which means the
solibs objects aren't built with -fPIC.

Ronald
Alexander Ausserstorfer
2018-12-22 03:11:40 UTC
Permalink
Post by Ronald
Post by n***@sprow.co.uk
Post by Ronald
I think the requirement for the BX instruction to be present
would be E12FFF or to be sure not to be caught out by byte order
also FF2FE1
Neither returned hits in the static !RunImage [...]
Puzzling then, where does the BX come from
Then that search technique doesn't work. Dropping the !RunImage onto
StrongEd and searching for "BX" gives 6 hits (of E12FFF1E), Sprow.
OK I will try that, text search on the binary and it works?
I have built libnettle using --disable-assembler and the !RunImage is
working on my SA RiscPC.
The problem was the library libnettle? I never ported anything to RISC
OS. Just used what there is.
Post by Ronald
Alex, I have uploaded it and it looks like it will work until the
problem is found in the assembler routines.
Looking at nettle6 in the autobuilder, it could do with some work, It
builds common objects for both static and shared libs which means the
solibs objects aren't built with -fPIC.
Many thanks, it is working now! Not the whole software, but the part of
TLS/SSL!!!

Hei konei ra,

Alex
--
http://home.chiemgau-net.de/ausserstorfer/
Beachte bitte auch die Rückseite dieses Schreibens!
Ronald
2018-12-22 11:37:04 UTC
Permalink
In message <***@eclipso.at>
Alexander Ausserstorfer <***@eclipso.at> wrote:
<snip>
Post by Alexander Ausserstorfer
The problem was the library libnettle? I never ported anything to RISC
OS. Just used what there is.
Yes Libnettle has arm assembler routines but they may only support
a minimum of archv5, so there is an option to use C routines that
are compiled to the gcc default of archv3. The gcc assembler
obviously just assembles what it is told to without warnings.

The openSSL library has assembler routines that support archv4
and the curl I compiled with this library works on the SA RiscPc,
one step further back than Nettle, like Nettle it has a no-asm option
to just use C routines for older hardware.
Post by Alexander Ausserstorfer
Post by Ronald
Alex, I have uploaded it and it looks like it will work until the
problem is found in the assembler routines.
Looking at nettle6 in the autobuilder, it could do with some work, It
builds common objects for both static and shared libs which means the
solibs objects aren't built with -fPIC.
Many thanks, it is working now! Not the whole software, but the part of
TLS/SSL!!!
I also uploaded the RiscPC(and older) safe libnettle.a so you can build
your own RunImage if you need to.

When I upgraded my fetchmail to openssl1.1.1 there were changes
required in the config but I found examples to help.
It stops ssl3 from being used. (no sslx support in openssl1.1.1)

Ronald
Alexander Ausserstorfer
2018-12-22 03:16:54 UTC
Permalink
Post by David Higton
Post by Ron
Post by Ron
Will rebuild crypt nettle with new stable then build libgnutls28 again.
Cheers RonM
OK I started from scratch and built all the libraries that are pulled in
by the libraries that are used in !POP3S
They are all from the current stable/stretch repository.
Should be at the same google drive link.
It is worth trying a bigger wimpslot when unixlib aborts, newer stuff
often gets bigger.
Another idea would be to try the RiscPC using gcc without the optimise
flag.
Let us know if compiling with those libraries improves things.
Note that the gnutls28 is renewed/rebuilt also.
What is the reason for trying to build POP3S? Is it simply to be able
to collect email from a server that requires SSL/TLS? Because if
that's all, you could instead use the current build of AntiSpam.
I wasn't aware about it. Is it this here:

http://kasoft.com.au/Documentation/AnSpam.html
Post by David Higton
AS doesn't /have/ to delete anything; it can be used simply as a
transport. Recent builds support SSL/TLS using the beta AcornSSL
module available from ROOL.
I cannot find the AcornSSL module. Where can I find it? Is there a link
anywhere?

A.
--
http://home.chiemgau-net.de/ausserstorfer/
Der Geist ist die Freiheit. (Frei.Wild)
Martin
2018-12-22 11:34:31 UTC
Permalink
[Snip]
Post by Alexander Ausserstorfer
Post by David Higton
What is the reason for trying to build POP3S? Is it simply to be
able to collect email from a server that requires SSL/TLS?
Because if that's all, you could instead use the current build of
AntiSpam.
http://kasoft.com.au/Documentation/AnSpam.html
No - that is a web page linking to a *very* old version. You want

https://aconet.org/antispam/
Post by Alexander Ausserstorfer
Post by David Higton
AS doesn't /have/ to delete anything; it can be used simply as a
transport. Recent builds support SSL/TLS using the beta AcornSSL
module available from ROOL.
I cannot find the AcornSSL module. Where can I find it? Is there a
link anywhere?
See long discussion about it on the ROOL website at
https://www.riscosopen.org/forum/forums/8/topics/11950

Martin
--
Martin Avison
Note that unfortunately this email address will become invalid
without notice if (when) any spam is received.
David Higton
2018-12-22 17:16:25 UTC
Permalink
Post by Alexander Ausserstorfer
http://kasoft.com.au/Documentation/AnSpam.html
No. (I wasn't even aware of the existence of his variant of what
appears to be a very old version of my old app.)

You need:

https://aconet.org/antispam/
Post by Alexander Ausserstorfer
Post by David Higton
AS doesn't /have/ to delete anything; it can be used simply as a
transport. Recent builds support SSL/TLS using the beta AcornSSL
module available from ROOL.
I cannot find the AcornSSL module. Where can I find it? Is there a link
anywhere?
It has been discussed extensively, and is hosted on, the RISC OS
Open web site. The current link (at time of posting) is:

https://www.riscosopen.org/zipfiles/beta/TCP-IP_Beta5.zip

Dave
Ronald
2018-12-22 20:54:14 UTC
Permalink
Post by David Higton
Post by Alexander Ausserstorfer
http://kasoft.com.au/Documentation/AnSpam.html
No. (I wasn't even aware of the existence of his variant of what
appears to be a very old version of my old app.)
https://aconet.org/antispam/
Post by Alexander Ausserstorfer
Post by David Higton
AS doesn't /have/ to delete anything; it can be used simply as a
transport. Recent builds support SSL/TLS using the beta AcornSSL
module available from ROOL.
I cannot find the AcornSSL module. Where can I find it? Is there a link
anywhere?
It has been discussed extensively, and is hosted on, the RISC OS
https://www.riscosopen.org/zipfiles/beta/TCP-IP_Beta5.zip
Dave
I find it odd that it is in 350.Modules, My Network folder has only been
in 310.modules in the past. Does this mean it will not work in older
OS's than RISC OS 3.5?
Ronald
David Higton
2018-12-22 21:23:59 UTC
Permalink
Post by Ronald
I find it odd that it is in 350.Modules, My Network folder has only been
in 310.modules in the past. Does this mean it will not work in older
OS's than RISC OS 3.5?
Good question. The discussion is in the "Bounties -> TCP/IP bounty
beta release" thread in the ROOL forum.

But who expects anything earlier than 3.5 to be supported anyway?
I, for one, don't.

Dave
David Higton
2018-12-23 20:12:13 UTC
Permalink
Post by David Higton
Post by Ronald
I find it odd that it is in 350.Modules, My Network folder has only been
in 310.modules in the past. Does this mean it will not work in older
OS's than RISC OS 3.5?
Good question. The discussion is in the "Bounties -> TCP/IP bounty
beta release" thread in the ROOL forum.
... where it has been pointed out that the new AcornSSL module uses
Dynamic Areas, which definitely rules out anything earlier than 3.5.

Dave
druck
2018-12-22 21:59:47 UTC
Permalink
Post by Ronald
I find it odd that it is in 350.Modules, My Network folder has only been
in 310.modules in the past. Does this mean it will not work in older
OS's than RISC OS 3.5?
Ronald
I haven't checked the code with ARMalyser, but its likely it's 32 bit
neutral code using MRS/MSR instructions, which are only on the ARM6 and
later, hence RISC OS 3.5 minimum.

You can do 32bit neutral which is also compatible with the ARM2/3, but
its larger and slower, and more ghastly - and as someone said - largely
pointless (and yes I know one person is still using an ARM3 A4 laptop).

---druck
Ronald
2018-12-22 22:50:50 UTC
Permalink
Post by druck
Post by Ronald
I find it odd that it is in 350.Modules, My Network folder has only been
in 310.modules in the past. Does this mean it will not work in older
OS's than RISC OS 3.5?
Ronald
I haven't checked the code with ARMalyser, but its likely it's 32 bit
neutral code using MRS/MSR instructions, which are only on the ARM6 and
later, hence RISC OS 3.5 minimum.
You can do 32bit neutral which is also compatible with the ARM2/3, but
its larger and slower, and more ghastly - and as someone said - largely
pointless (and yes I know one person is still using an ARM3 A4 laptop).
---druck
I can recall software being released only for RiscPC and newer, probably
the same reason.
Another thing that is not so important, will it require a newer URL or
URI module so that it could work with Phoenix and maybe other browsers?

Ronald
Ronald
2018-12-23 01:35:53 UTC
Permalink
Post by Ronald
Post by druck
Post by Ronald
I find it odd that it is in 350.Modules, My Network folder has only been
in 310.modules in the past. Does this mean it will not work in older
OS's than RISC OS 3.5?
Ronald
I haven't checked the code with ARMalyser, but its likely it's 32 bit
neutral code using MRS/MSR instructions, which are only on the ARM6 and
later, hence RISC OS 3.5 minimum.
You can do 32bit neutral which is also compatible with the ARM2/3, but
its larger and slower, and more ghastly - and as someone said - largely
pointless (and yes I know one person is still using an ARM3 A4 laptop).
---druck
I can recall software being released only for RiscPC and newer, probably
the same reason.
I might have got the wrong idea about architectures somewhere too,
The Acorn32bitDev pdf states that machines before RiscPC including
A7500 are 26bit only architecture armv2.
RiscPC 610 and newer are armv3and both 26bit and 32bit capable.
The 32bit SharedCLib must play a part too, maybe it wasn't possible on
pre RiscPC, I can't remember.

I read that (generic) gcc v9 has dropped support for armv2 and armv3, no
mention of armv4 but Armv5T 5TE 5TEJ remain supported. At the moment
(gcc 4.7.4) we could possibly target the early architectures and cpu's
additionly using -maps26 if necessary.
I imagine the DDE would have some flexibility for compatibility too.

Ronald
druck
2018-12-23 14:22:18 UTC
Permalink
Post by Ronald
Post by druck
You can do 32bit neutral which is also compatible with the ARM2/3, but
its larger and slower, and more ghastly - and as someone said - largely
pointless (and yes I know one person is still using an ARM3 A4 laptop).
I might have got the wrong idea about architectures somewhere too,
The Acorn32bitDev pdf states that machines before RiscPC including
A7500 are 26bit only architecture armv2.
Archimedes, A3000s, and A5000s using the ARM2, ARM250 or ARM3, are all
26bit only. All Risc PCs and A7000 using the ARM7500 are both 26bit and
32bit capable.
Post by Ronald
RiscPC 610 and newer are armv3and both 26bit and 32bit capable.
Yes, and that's the point Acorn should have moved to a 32bit OS. All the
developers were still around, and everything could have been converted
during the long testing period before the RPC launch.

Another opportunity would have been the introduction of the Strong ARM,
although the original SA110 supported 26bit mode, it was clear when this
mode was deleted from the SA1100 a short time later, that there would be
no more 26bit mode chips.

Both those occasions required new software to take advantage of the new
hardware or to address incompatibilities, which customers were more than
willing to purchase. 32bit conversion could have been slipped in, and
hardly anyone would have even been aware there was an issue.
Post by Ronald
The 32bit SharedCLib must play a part too, maybe it wasn't possible on
pre RiscPC, I can't remember.
The 32bit SCL was available for RISC OS 3.1

Most 32bit software was written to be neutral, so it will run in either
26bit or 32bit mode, by not relying on the easy flag preserving nature
of 26bit.

However to work on the ARM2 and ARM3, some extra hoops have to be jumped
through to cater for the lack of the status register manipulation
instructions (MSR/MRS) which are on the ARM6 and later. This is why you
might find software works in 26bit mode, but is RISC OS 3.5 (ARM6) and
later.
Post by Ronald
I read that (generic) gcc v9 has dropped support for armv2 and armv3, no
mention of armv4 but Armv5T 5TE 5TEJ remain supported. At the moment
(gcc 4.7.4) we could possibly target the early architectures and cpu's
additionly using -maps26 if necessary.
I'm not surprised, not only is no one using 26bit mode, but most code
written for 32bit ARMs doesn't uses the Thumb2 mode (a mix of 16 & 32
wide instructions), for increased code density. Unlike the very limited
original 16 bit only Thumb1 instructions, Thumb2 can take full advantage
of all processors registers and facilities, I don't like it though.

These days the completely different ARMv8 64 bit instruction set is all
the range. I've just been on a course on the Cortex A53 for Zynq (SOC
featuring a Xilinx FPGA), and it is very much "it's ARM Jim, but not as
we know it".
Post by Ronald
I imagine the DDE would have some flexibility for compatibility too.
Norcroft CC in DDE still supports ARM2 to XScale, I'm not sure if it
knows anything later than ARMv5TE.

---druck
n***@sprow.co.uk
2018-12-23 20:56:18 UTC
Permalink
Post by druck
Post by Ronald
I imagine the DDE would have some flexibility for compatibility too.
Norcroft CC in DDE still supports ARM2 to XScale, I'm not sure if it
knows anything later than ARMv5TE.
At least a smattering, based on:
* I've seen it emit UXTH and UXTB for narrowing casts which are ARMv6
(I assume SXTH and SXTB for signed values too but haven't looked that hard).
* The change log for cc 5.74 mentions MLS being used for expressions of the form
a = b - (c * d)
and that's ARMv6T2.
* The change log for cc 5.69 mentions Cortex-A8 scheduling rules, so while that
might just be the same instructions as before, it's modelling the pipeline
in an ARMv7.

Far from complete given the eye watering number of extra instructions that appeared in ARMv6, but compatible with ARMv2 to ARMv8 and shades in between,
Sprow.
Matthew Phillips
2018-12-28 20:28:42 UTC
Permalink
Another thing that is not so important, will it require a newer URL or URI
module so that it could work with Phoenix and maybe other browsers?
It does require a new URL module, but not URI.

The updated URL fetcher module and an updated AcornHTTP module have been in
the nightly builds for a few months now: I think they were released in May.
--
Matthew Phillips
Durham
Ronald
2018-12-28 23:10:21 UTC
Permalink
Post by Matthew Phillips
Another thing that is not so important, will it require a newer URL or URI
module so that it could work with Phoenix and maybe other browsers?
It does require a new URL module, but not URI.
The updated URL fetcher module and an updated AcornHTTP module have been in
the nightly builds for a few months now: I think they were released in May.
Thanks, great news, and Phoenix appears to be working flawlessly on https
I logged into riscosopen ,posted and logged out again without issues.

Druck said
Post by Matthew Phillips
You can do 32bit neutral which is also compatible with the ARM2/3, but
its larger and slower, and more ghastly - and as someone said - largely
pointless (and yes I know one person is still using an ARM3 A4 laptop).
Playing with !GCC 4.7.4 a bit and it looks like it is locked to aps-32.
I think it also ignores -march=armv2, the output was an identical size.
!GCC 3.x can probably do it, It is likely lacking in support for some
functions compared to 4.7.4 and be a bit more work.
Ronald

Loading...