DocumentServer icon indicating copy to clipboard operation
DocumentServer copied to clipboard

meet with some problem on ssl

Open Terryisthebest opened this issue 6 months ago • 3 comments

This issue is unique.

  • [X] I have used the search tool and did not find an issue describing my bug.

Operating System of DocumentServer

Docker

Version information

7.2

Expected Behavior

I want to preview the files in my Alist.

Actual Behavior

it said it failed to download.

Reproduction Steps

here's the log:

[2024-07-30T14:55:28.820] [ERROR] nodeJS - error downloadFile:url=http://www.terryliu.top:2505/p/文件共享平台/高中学习资料/来自0740/2022年上海教育考试院版《高考英语词汇手册》新增考纲词汇pdf_1.pdf?sign=Jlgeatx0lOViXzAuxhJwzgSY5EzZ0-LZ2PnTQKGkwZ8=:0;attempt=3;code:null;connect:null;(id=214135645731db79bbd6) Error: Error response: statusCode:400; headers:{"date":"Tue, 30 Jul 2024 14:55:28 GMT","server":"Apache/2.4.55 (Unix) OpenSSL/1.1.1t","content-length":"362","connection":"close","content-type":"text/html; charset=iso-8859-1"}; body:

400 Bad Request

Bad Request

Your browser sent a request that this server could not understand.
Reason: You're speaking plain HTTP to an SSL-enabled server port.
Instead use the HTTPS scheme to access this URL, please.

at Request._callback (/snapshot/server/build/server/Common/sources/utils.js:0:0)
at Request.init.self.callback (/snapshot/server/build/server/Common/node_modules/request/request.js:185:22)
at Request.emit (events.js:198:13)
at Request.<anonymous> (/snapshot/server/build/server/Common/node_modules/request/request.js:1154:10)
at Request.emit (events.js:198:13)
at IncomingMessage.<anonymous> (/snapshot/server/build/server/Common/node_modules/request/request.js:1076:12)
at Object.onceWrapper (events.js:286:20)
at IncomingMessage.emit (events.js:203:15)
at endReadableNT (_stream_readable.js:1145:12)
at process._tickCallback (internal/process/next_tick.js:63:19)

My downloading url should begin with https, but it's http. I viewed the js file(https://www.terryliu.top:2581/web-apps/apps/api/documents/api.js),and found this:

customerId: , region: // can be 'en-us' or lang code

            user: {
                id: 'user id',
                name: 'user name',
                group: 'group name' // for customization.reviewPermissions parameter
            },
            recent: [
                {
                    title: 'document title',
                    url: 'document url',
                    folder: 'path to document',
                },
                ...
            ],
            templates: [
                {
                    title: 'template name', // name - is deprecated
                    image: 'template icon url',
                    url: 'http://...'
                },
                ...
            ],
            customization: {
                logo: {
                    image: url,
                    imageEmbedded: url,
                    url: http://...
                },
                customer: {
                    name: 'SuperPuper',
                    address: 'New-York, 125f-25',
                    mail: '[email protected]',
                    www: 'www.superpuper.com',
                    info: 'Some info',
                    logo: ''
                },
                about: true,
                feedback: {
                    visible: false,
                    url: http://...
                },
                goback: {
                    url: 'http://...',
                    text: 'Go to London',
                    blank: true,
                    requestClose: false // if true - goback send onRequestClose event instead opening url
                },
                reviewPermissions: {
                    "Group1": ["Group2"], // u

all of them are http. I don't know whether that's the problem...

Additional information

I'm just a student. I'm using Qnap Container Station to run the program. Could any one help me???

Terryisthebest avatar Jul 30 '24 15:07 Terryisthebest