bangbang93 / openbmclapi

BMCLAPI@Home
https://bmclapidoc.bangbang93.com
MIT License
336 stars 31 forks source link

没法上线,不知道是我的问题还是服务器寄了HTTPError: Response code 403 (Forbidden) #82

Closed mcxiaochenn closed 3 months ago

mcxiaochenn commented 3 months ago

大致过程: 因为是家里云所以每天晚上会重启,节点离线时间是2024-08-06 21:41:38差不多刚好是我手动重启的时间,当时莫名其妙忽然就掉拨号,后来电信打电话说我被打了(ddos)他们那边主动切断我的拨号了,24小时后恢复,然后我就没在意这件事,到刚才进后台加硬盘升级阵列关机的时候才发现报了一堆错误,日志如下,已尝试换端口,重新下载源码编译,重置SECRET都没有用,所以是验证节点挂了吗还是我的问题,嘉兴电信,dns用的是223.5.5.5和114.114.114.114

日志: PS E:\openbmclapi> node dist/index.js [2024-08-09 04:48:35.468 +0800] INFO (24016): booting openbmclapi 1.11.0 [2024-08-09 04:48:35.587 +0800] INFO (24016): 浣跨敤瀛樺偍绫诲瀷: file HTTPError: Response code 403 (Forbidden) at Request. (file:///E:/openbmclapi/node_modules/got/dist/source/as-promise/index.js:86:42) at Object.onceWrapper (node:events:634:26) at Request.emit (node:events:531:35) at Request._onResponseBase (file:///E:/openbmclapi/node_modules/got/dist/source/core/index.js:604:22) at process.processTicksAndRejections (node:internal/process/task_queues:95:5) at async Request._onResponse (file:///E:/openbmclapi/node_modules/got/dist/source/core/index.js:646:13) { input: undefined, code: 'ERR_NON_2XX_3XX_RESPONSE', timings: { start: 1723150115596, socket: 1723150115596, lookup: 1723150115597, connect: 1723150115605, secureConnect: 1723150115617, upload: 1723150115617, response: 1723150115638, end: 1723150115639, error: undefined, abort: undefined, phases: { wait: 0, dns: 1, tcp: 8, tls: 12, request: 0, firstByte: 21, download: 1, total: 43 } }, options: { request: undefined, agent: { http: undefined, https: Agent { _events: [Object: null prototype], _eventsCount: 2, _maxListeners: undefined, defaultPort: 443, protocol: 'https:', options: [Object: null prototype], requests: [Object: null prototype] {}, sockets: [Object: null prototype] {}, freeSockets: [Object: null prototype], keepAliveMsecs: 1000, keepAlive: true, maxSockets: Infinity, maxFreeSockets: 256, scheduling: 'lifo', maxTotalSockets: Infinity, totalSocketCount: 1, maxCachedSessions: 100, _sessionCache: [Object],

    [Symbol(kCapture)]: false
  },
  http2: undefined
},
h2session: undefined,
decompress: true,
timeout: {
  connect: 10000,
  lookup: undefined,
  read: undefined,
  request: 300000,
  response: 10000,
  secureConnect: undefined,
  send: undefined,
  socket: undefined
},
prefixUrl: '',
body: undefined,
form: undefined,
json: undefined,
cookieJar: undefined,
ignoreInvalidCookies: false,
searchParams: undefined,
dnsLookup: undefined,
dnsCache: undefined,
context: {},
hooks: {
  init: [],
  beforeRequest: [ [AsyncFunction (anonymous)] ],
  beforeError: [],
  beforeRedirect: [],
  beforeRetry: [],
  afterResponse: []
},
followRedirect: true,
maxRedirects: 10,
cache: Map(0) { namespace: 'cacheable-request' },
throwHttpErrors: true,
username: '',
password: '',
http2: false,
allowGetBody: false,
headers: {
  'user-agent': 'openbmclapi-cluster/1.11.0',
  accept: 'application/json',
  'accept-encoding': 'gzip, deflate, br',
  authorization: 'Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpZCI6IjY2YTY0Njk0MGIxYmVmNWI1MDk3NTgyMCIsInR5cGUiOiJ0b2tlbiIsImlhdCI6MTcyMzE1MDExNSwiZXhwIjoxNzIzMjM2NTE1fQ.YlqrAWuRq0H5lSeAsKHUWUzKIeYbc7_r19G20FMZ6YE'
},
methodRewriting: false,
dnsLookupIpVersion: undefined,
parseJson: [Function: parse],
stringifyJson: [Function: stringify],
retry: {
  limit: 2,
  methods: [ 'GET', 'PUT', 'HEAD', 'DELETE', 'OPTIONS', 'TRACE' ],
  statusCodes: [
    408, 413, 429, 500,
    502, 503, 504, 521,
    522, 524
  ],
  errorCodes: [
    'ETIMEDOUT',
    'ECONNRESET',
    'EADDRINUSE',
    'ECONNREFUSED',
    'EPIPE',
    'ENOTFOUND',
    'ENETUNREACH',
    'EAI_AGAIN'
  ],
  maxRetryAfter: undefined,
  calculateDelay: [Function: calculateDelay],
  backoffLimit: Infinity,
  noise: 100
},
localAddress: undefined,
method: 'GET',
createConnection: undefined,
cacheOptions: {
  shared: undefined,
  cacheHeuristic: undefined,
  immutableMinTimeToLive: undefined,
  ignoreCargoCult: undefined
},
https: {
  alpnProtocols: undefined,
  rejectUnauthorized: undefined,
  checkServerIdentity: undefined,
  certificateAuthority: undefined,
  key: undefined,
  certificate: undefined,
  passphrase: undefined,
  pfx: undefined,
  ciphers: undefined,
  honorCipherOrder: undefined,
  minVersion: undefined,
  maxVersion: undefined,
  signatureAlgorithms: undefined,
  tlsSessionLifetime: undefined,
  dhparam: undefined,
  ecdhCurve: undefined,
  certificateRevocationLists: undefined
},
encoding: undefined,
resolveBodyOnly: false,
isStream: false,
responseType: 'json',
url: URL {
  href: 'https://openbmclapi.bangbang93.com/openbmclapi/configuration', 
  origin: '[https://openbmclapi.bangbang93.com',](https://openbmclapi.bangbang93.com&/#39;,) 
  protocol: 'https:',
  username: '',
  password: '',
  host: 'openbmclapi.bangbang93.com',
  hostname: 'openbmclapi.bangbang93.com',
  port: '',
  pathname: '/openbmclapi/configuration',
  search: '',
  searchParams: URLSearchParams {},
  hash: ''
},
pagination: {
  transform: [Function: transform],
  paginate: [Function: paginate],
  filter: [Function: filter],
  shouldContinue: [Function: shouldContinue],
  countLimit: Infinity,
  backoff: 0,
  requestLimit: 10000,
  stackAllItems: false
},
setHost: true,
maxHeaderSize: undefined,
signal: undefined,
enableUnixSockets: false

},

} 工作进程 1 异常退出,code: 1, signal: null,1秒后重启

来自kimiai的解释: 从您提供的错误日志来看,您的 Node.js 应用程序在尝试请求 https://openbmclapi.bangbang93.com/openbmclapi/configuration 时遇到了 HTTP 403 错误,即“禁止访问”。这通常意味着服务器理解了请求,但拒绝执行它。这可能是由于多种原因造成的,包括但不限于:

  1. 权限问题:请求的资源可能需要特定的权限或身份验证凭据。
  2. API 限制:可能存在请求频率限制或IP限制。
  3. 错误的请求:可能是请求的 URL、方法或头信息不正确。
  4. 服务器配置:服务器可能有特定的访问控制列表(ACL)或其他配置,阻止了您的请求。

以下是一些解决此问题的建议步骤:

另外,错误日志中提到“工作进程 1 异常退出,code: 1, signal: null”,这表明应用程序因为遇到错误而异常退出。这可能是由于上述 HTTP 403 错误导致的,也可能是其他问题。您可能需要检查应用程序的逻辑,确保在捕获异常时有适当的错误处理和日志记录机制。

如果问题仍然无法解决,您可能需要更详细地检查应用程序的日志文件,或者使用调试工具来进一步诊断问题。

bangbang93 commented 3 months ago

24小时内上线失败超过100次被临时封禁了。 你不在qq群里吗

mcxiaochenn commented 3 months ago

在群里但是免打扰[笑哭]我关掉等24小时再上线就行是吧 ---- 回复的原邮件 ---- 发件人 @.> 日期 2024年08月09日 10:33 收件人 @.> 抄送至 @.>@.> 主题 Re: [bangbang93/openbmclapi] 没法上线,不知道是我的问题还是服务器寄了HTTPError: Response code 403 (Forbidden) (Issue #82) 24小时内上线失败超过100次被临时封禁了。 你不在qq群里吗 — Reply to this email directly, view it on GitHub, or unsubscribe. You are receiving this because you authored the thread.Message ID: @.***>

mcxiaochenn commented 3 months ago

24小时内上线失败超过100次被临时封禁了。 你不在qq群里吗

已经过了24小时了,再尝试上线还是403,请问这个封禁时间具体是多久

bangbang93 commented 3 months ago

手动解的,你qq找我下