|
2022-05-04
| ||
| 07:27 | http: tolerant again invalid reply header "content-encoding: UTF-8". Ticket [8eb64b1520] check-in: 8d92c72151 user: oehhar tags: trunk, main | |
| 07:18 | http: tolerant again invalid reply header "content-encoding: UTF-8". Ticket [8eb64b1520] check-in: fcffa8c46c user: oehhar tags: main | |
| 07:16 | http: tolerant again invalid reply header "content-encoding: UTF-8". Ticket [8eb64b1520] check-in: 054cc3002a user: oehhar tags: core-8-branch | |
| 07:13 | • Closed ticket [8eb64b1520]: http: invalid reply header "content-encoding: U... artifact: 29e48b193a user: oehhar | |
| 06:56 | http: tolerant again invalid reply header "content-encoding: UTF-8". Ticket [8eb64b1520] check-in: 1f5e1f5a49 user: oehhar tags: core-8-6-branch | |
|
2022-05-03
| ||
| 16:45 | • Ticket [8eb64b1520] http: invalid reply header "content-encoding: UTF-8&quo... artifact: f1643e173f user: oehhar | |
| 16:27 | • Ticket [8eb64b1520]: 4 changes artifact: ac956bceab user: oehhar | |
|
2021-12-03
| ||
| 12:07 | • Ticket [8eb64b1520]: 4 changes artifact: 28d7d80214 user: oehhar | |
| 11:07 | • New ticket [8eb64b1520]. artifact: 987dd03450 user: oehhar | |
http: invalid reply header "content-encoding: UTF-8" gives error, but may be tolerated
Content-Encoding: gzip | compress | deflate | br| identity
I have a server (SAP Production) where I do a post-call with JSON data. The response has:
Content-Encoding: UTF-8
Currently, http package 2.9.5 fails with the correct error:
unsupported content-encoding "UTF-8"
and writes the Log:
error doing decompression for token ::http::1: unsupported content-encoding "UTF-8"
Would it be a good idea here to be more tolerant, and fall back to identity ?
Apparently, others just ignore this...
Thanks for any opinion, Harald
8d92c72151http: tolerant again invalid reply header "content-encoding: UTF-8". Ticket [8eb64b1520] check-in2022-05-04 07:27:48fcffa8c46chttp: tolerant again invalid reply header "content-encoding: UTF-8". Ticket [8eb64b1520] check-in2022-05-04 07:18:43054cc3002ahttp: tolerant again invalid reply header "content-encoding: UTF-8". Ticket [8eb64b1520] check-in2022-05-04 07:16:111f5e1f5a49http: tolerant again invalid reply header "content-encoding: UTF-8". Ticket [8eb64b1520] check-in2022-05-04 06:56:12
Proposed implementation in branch [rfe-eb64b1520-http-content-encoding-tolerant] starting with commit [1198f073df].
Only the not implemented but correct content "br" errors out. Any other content is ignored.
Any opinions ?
Thank you all, Harald
I asked the customer again. The issue is in SAP PLM when a function is called using https and a JSON payload.
Are there any objections, that I merge the patch ?
Thank you all, Harald
May I add that make test with MS-VC6 in 32 bit Windows does not show any test errors in this field. The shown errors are listed below.
I would be glad to merge before the new apparently complex http ticket about web-sockets, so I avoid any merge conflicts.
Thank you, Harald
==== winFCmd-6.1 TclpRemoveDirectory: errno: EACCES FAILED
==== Contents of test case:
file mkdir td1
testchmod 0 td1
testfile rmdir td1
file exists td1
---- Test completed normally; Return code was: 0
---- Return code should have been one of: 1
==== winFCmd-6.1 FAILED
==== winFCmd-6.9 TclpRemoveDirectory: errno == EACCES FAILED
==== Contents of test case:
file mkdir td1
testchmod 0 td1
testfile rmdir td1
file exists td1
---- Test completed normally; Return code was: 0
---- Return code should have been one of: 1
==== winFCmd-6.9 FAILED
==== winFCmd-6.13 TclpRemoveDirectory: write-protected FAILED
==== Contents of test case:
file mkdir td1
testchmod 0 td1
testfile rmdir td1
file exists td1
---- Test completed normally; Return code was: 0
---- Return code should have been one of: 1
==== winFCmd-6.13 FAILED
==== winFCmd-9.3 TraversalDelete: DOTREE_PRED FAILED
==== Contents of test case:
file mkdir td1/td2
testchmod 0 td1
testfile rmdir -force td1
file exists td1
---- Test completed normally; Return code was: 0
---- Return code should have been one of: 1
==== winFCmd-9.3 FAILED
Fix merged with commit [1f5e1f5a49] to core-8-6-branch. The tests with ms-vc6 32 bit on win64 now give no reports in this field. The test failures in the env range are listed below.
I discussed again with the customer. The system is SAP-ME. It is a custom process and the error results probably due to a wrong customization. Nevertheless, we were clear, that:
- other http clients ignore the issue
- it is good to be strict on output and false-tolerant on input
THank you all, Harald
-----
TCL compiled with MS-VC6 32 bit on Windows 10 64 bit:
==== env-2.1 adding environment variables FAILED
==== Contents of test case:
getenv
---- Result was:
PROCESSOR_ARCHITEW6432=x86
---- Result should have been (exact matching):
==== env-2.1 FAILED
==== env-2.2 adding environment variables FAILED
==== Contents of test case:
set env(NAME1) "test string"
getenv
---- Result was:
NAME1=test string
PROCESSOR_ARCHITEW6432=x86
---- Result should have been (exact matching):
NAME1=test string
==== env-2.2 FAILED
==== env-2.3 adding environment variables FAILED
==== Contents of test case:
set env(NAME2) "more"
getenv
---- Result was:
NAME1=test string
NAME2=more
PROCESSOR_ARCHITEW6432=x86
---- Result should have been (exact matching):
NAME1=test string
NAME2=more
==== env-2.3 FAILED
==== env-2.4 adding environment variables FAILED
==== Contents of test case:
set env(XYZZY) "garbage"
getenv
---- Result was:
NAME1=test string
NAME2=more
PROCESSOR_ARCHITEW6432=x86
XYZZY=garbage
---- Result should have been (exact matching):
NAME1=test string
NAME2=more
XYZZY=garbage
==== env-2.4 FAILED
==== env-3.1 changing environment variables FAILED
==== Contents of test case:
set result [getenv]
unset env(NAME2)
set result
---- Result was:
NAME1=test string
NAME2=new value
PROCESSOR_ARCHITEW6432=x86
XYZZY=garbage
---- Result should have been (exact matching):
NAME1=test string
NAME2=new value
XYZZY=garbage
==== env-3.1 FAILED
==== env-4.1 unsetting environment variables FAILED
==== Contents of test case:
unset -nocomplain env(NAME2)
getenv
---- Result was:
NAME1=test string
PROCESSOR_ARCHITEW6432=x86
XYZZY=garbage
---- Result should have been (exact matching):
NAME1=test string
XYZZY=garbage
==== env-4.1 FAILED
==== env-4.3 setting international environment variables FAILED
==== Contents of test case:
set env(\ua7) \ub6
getenv
---- Result was:
PROCESSOR_ARCHITEW6432=x86
\u00a7=\u00b6
---- Result should have been (exact matching):
\u00a7=\u00b6
==== env-4.3 FAILED
==== env-4.4 changing international environment variables FAILED
==== Contents of test case:
set env(\ua7) \ua7
getenv
---- Result was:
PROCESSOR_ARCHITEW6432=x86
\u00a7=\u00a7
---- Result should have been (exact matching):
\u00a7=\u00a7
==== env-4.4 FAILED
==== env-4.5 unsetting international environment variables FAILED
==== Contents of test case:
set env(\ub6) \ua7
unset env(\ua7)
getenv
---- Result was:
PROCESSOR_ARCHITEW6432=x86
\u00b6=\u00a7
---- Result should have been (exact matching):
\u00b6=\u00a7
==== env-4.5 FAILED