RaresAil / homebridge-daikin-smart-ac

A Homebridge plugin for Daikin Wifi Adapter AC using Local API
https://www.npmjs.com/package/homebridge-daikin-smart-ac
Apache License 2.0
4 stars 1 forks source link

Not supporting SSL / HTTPS. #3

Open prawnPANDI opened 1 year ago

prawnPANDI commented 1 year ago

Looks like the latest firmware only supports SSL / HTTPS connections. Does the plugin support HTTPS?

`[2/28/2023, 10:15:31 PM] [Daikin Smart ACs] AxiosError: connect ECONNREFUSED 192.168.1.26:80 at TCPConnectWrap.afterConnect [as oncomplete] (node:net:1487:16) { port: 80, address: '192.168.1.26', syscall: 'connect', code: 'ECONNREFUSED', errno: -111, config: { transitional: { silentJSONParsing: true, forcedJSONParsing: true, clarifyTimeoutError: false }, adapter: [Function: httpAdapter], transformRequest: [ [Function: transformRequest] ], transformResponse: [ [Function: transformResponse] ], timeout: 0, xsrfCookieName: 'XSRF-TOKEN', xsrfHeaderName: 'X-XSRF-TOKEN', maxContentLength: -1, maxBodyLength: -1, env: { FormData: [Function] }, validateStatus: [Function: validateStatus], headers: { Accept: 'application/json, text/plain, /', 'User-Agent': 'axios/0.27.2' }, method: 'get', url: 'http://192.168.1.26/common/basic_info', data: undefined }, request: <ref *1> Writable { _writableState: WritableState { objectMode: false, highWaterMark: 16384, finalCalled: false, needDrain: false, ending: false, ended: false, finished: false, destroyed: false, decodeStrings: true, defaultEncoding: 'utf8', length: 0, writing: false, corked: 0, sync: true, bufferProcessing: false, onwrite: [Function: bound onwrite], writecb: null, writelen: 0, afterWriteTickInfo: null, buffered: [], bufferedIndex: 0, allBuffers: true, allNoop: true, pendingcb: 0, constructed: true, prefinished: false, errorEmitted: false, emitClose: true, autoDestroy: true, errored: null, closed: false, closeEmitted: false,

},
_events: [Object: null prototype] {
  response: [Function: handleResponse],
  error: [Function: handleRequestError],
  socket: [Function: handleRequestSocket]
},
_eventsCount: 3,
_maxListeners: undefined,
_options: {
  maxRedirects: 21,
  maxBodyLength: 10485760,
  protocol: 'http:',
  path: '/common/basic_info',
  method: 'GET',
  headers: [Object],
  agent: undefined,
  agents: [Object],
  auth: undefined,
  hostname: '192.168.1.26',
  port: null,
  nativeProtocols: [Object],
  pathname: '/common/basic_info'
},
_ended: true,
_ending: true,
_redirectCount: 0,
_redirects: [],
_requestBodyLength: 0,
_requestBodyBuffers: [],
_onNativeResponse: [Function (anonymous)],
_currentRequest: ClientRequest {
  _events: [Object: null prototype],
  _eventsCount: 7,
  _maxListeners: undefined,
  outputData: [],
  outputSize: 0,
  writable: true,
  destroyed: false,
  _last: true,
  chunkedEncoding: false,
  shouldKeepAlive: false,
  maxRequestsOnConnectionReached: false,
  _defaultKeepAlive: true,
  useChunkedEncodingByDefault: false,
  sendDate: false,
  _removedConnection: false,
  _removedContLen: false,
  _removedTE: false,
  strictContentLength: false,
  _contentLength: 0,
  _hasBody: true,
  _trailer: '',
  finished: true,
  _headerSent: true,
  _closed: false,
  socket: [Socket],
  _header: 'GET /common/basic_info HTTP/1.1\r\n' +
    'Accept: application/json, text/plain, */*\r\n' +
    'User-Agent: axios/0.27.2\r\n' +
    'Host: 192.168.1.26\r\n' +
    'Connection: close\r\n' +
    '\r\n',
  _keepAliveTimeout: 0,
  _onPendingData: [Function: nop],
  agent: [Agent],
  socketPath: undefined,
  method: 'GET',
  maxHeaderSize: undefined,
  insecureHTTPParser: undefined,
  path: '/common/basic_info',
  _ended: false,
  res: null,
  aborted: false,
  timeoutCb: null,
  upgradeOrConnect: false,
  parser: null,
  maxHeadersCount: null,
  reusedSocket: false,
  host: '192.168.1.26',
  protocol: 'http:',
  _redirectable: [Circular *1],
  [Symbol(kCapture)]: false,
  [Symbol(kBytesWritten)]: 0,
  [Symbol(kEndCalled)]: true,
  [Symbol(kNeedDrain)]: false,
  [Symbol(corked)]: 0,
  [Symbol(kOutHeaders)]: [Object: null prototype],
  [Symbol(errored)]: null,
  [Symbol(kUniqueHeaders)]: null
},
_currentUrl: 'http://192.168.1.26/common/basic_info',
[Symbol(kCapture)]: false

} }`

RaresAil commented 1 year ago

Hey, does your AC have a password?

prawnPANDI commented 1 year ago

Nope. Disabled anywhere access.

Get Outlook for iOShttps://aka.ms/o0ukef


From: Nicolae-Rares Ailincai @.> Sent: Sunday, March 5, 2023 2:57:54 PM To: RaresAil/homebridge-daikin-smart-ac @.> Cc: prawnPANDI @.>; Author @.> Subject: Re: [RaresAil/homebridge-daikin-smart-ac] Not supporting SSL / HTTPS. (Issue #3)

Hey, does your AC have a password?

— Reply to this email directly, view it on GitHubhttps://github.com/RaresAil/homebridge-daikin-smart-ac/issues/3#issuecomment-1455007725, or unsubscribehttps://github.com/notifications/unsubscribe-auth/AQCCCF3XWB2MNUQDOE6BISLW2Q2PFANCNFSM6AAAAAAVKZDGFM. You are receiving this because you authored the thread.Message ID: @.***>

homoky commented 1 year ago

Have you get it working @prawnPANDI ?

prawnPANDI commented 1 year ago

I am using Home Assistant. Haven’t tried again with HomeBridge.

homoky commented 1 year ago

Ok. Thanks for info. Can here please link a integration that you use for Home Assistant?

prawnPANDI commented 1 year ago

https://www.home-assistant.io/integrations/daikin/

RaresAil commented 1 year ago

I will add a configuration option to switch to https