jasper icon indicating copy to clipboard operation
jasper copied to clipboard

Cannot use https github enterprise

Open elanciel opened this issue 8 years ago • 16 comments

Hi I cannot use the https github enterprise github mode...

Is it normal or a bug ?

Regards.

Richard.

elanciel avatar Aug 17 '16 15:08 elanciel

Allo?

elanciel avatar Sep 07 '16 12:09 elanciel

Sorry for late reply.

Jasper supports https GHE. Please tell me your configuration.

h13i32maru avatar Sep 07 '16 13:09 h13i32maru

I found the issue: Jasper does not handle cert files.

elanciel avatar Dec 09 '16 01:12 elanciel

Please check v0.2.4-beta.1 https://jasperapp.io/beta.html

h13i32maru avatar Jan 03 '17 11:01 h13i32maru

I'm tried and get failed to use Jasper app with GitHub enterprise.

Configure the GitHub enterprise host, input the personal access token, click the OK button, then I get only invalid setting message from Jasper app.

What can I do to use the app?

My environment:

  • Jasper app 0.2.5
  • OS X 10.12.3
  • GitHub enterprise
    • with self-signed certificates

aereal avatar Mar 14 '17 05:03 aereal

I have met similar issue. Launch jaspmer and forever loading....

  • Jasper app 0.2.5
  • OS X 10.10.6
  • GitHub enterprise: http

I've tried run jasper by electron command and see following error output.

$ npm i -g electron
$ electron /Applications/Jasper.app/Contents/Resources/app.asar
[N] [2017-03-22T10:44:50.632Z] [index.js:52:23] user data path: /Users/user/Library/Application Support/jasper
[N] [2017-03-22T10:44:50.638Z] [index.js:53:23] app data path: /Users/user/Library/Application Support
[N] [2017-03-22T10:44:50.639Z] [index.js:54:23] config path: /Users/user/Library/Application Support/jasper/io.jasperapp/config.json
2017-03-22 10:45:13.357 Electron Helper[64464:8552993] Couldn't set selectedTextBackgroundColor from default ()
[N] [2017-03-22T10:45:24.353Z] [GitHubClient.js:143:29] [request] /user
{ Error: connect ECONNREFUSED xx.xx.xxx.xx:443
    at Object.exports._errnoException (util.js:1022:11)
    at exports._exceptionWithHostPort (util.js:1045:20)
    at TCPConnectWrap.afterConnect [as oncomplete] (net.js:1090:14)
  code: 'ECONNREFUSED',
  errno: 'ECONNREFUSED',
  syscall: 'connect',
  address: 'xx.xx.xxx.xx',
  port: 443 }

I've used http:// url, but jasper access to https?

azu avatar Mar 22 '17 01:03 azu

jasper works fine with http and https, the main issue is when you needs certificates to be trusted on your github enterprise landscape. I found a work around that inject the certificates (2 lines of code) but we really need a proper development on the top of it.

Hope jasper developers will read this :)

elanciel avatar Mar 22 '17 15:03 elanciel

@azu

but jasper access to https?

Jasper uses the following code.

      const options = {
        hostname: this._host,
        port: this._https ? 443 : 80,
        path: requestPath,
        headers: {
          'User-Agent': this._userAgent,
          'Authorization': `token ${this._accessToken}`
        }
      };

      const httpModule = this._https ? https : http;

      this._log(path, query);
      const req = httpModule.request(
        options,
        this._onResponse.bind(this, resolve, reject)
      ).on('error', (e)=> reject(e));

I think that other cause in this bug.

h13i32maru avatar Apr 22 '17 01:04 h13i32maru

@elanciel Thanks for the comment.

I found a work around that inject the certificates (2 lines of code)

Could you tell me the code?

h13i32maru avatar Apr 22 '17 01:04 h13i32maru

Maybe, this is other issue.

I've set GHE setting and launched jasper, then loading forever.

image

Does jasper use rate_limit api? I've noticed that some GHE enviroment has disabled rate_limit feature. If Rate Limit feature have been disabaled, get 404 response.

  • https://github.com/kohsuke/github-api/issues/273#issuecomment-238005230%E2%98%9D%EF%B8%8F
  • https://github.com/azu/faao/pull/41

azu avatar Jul 03 '17 02:07 azu

I'm trying Jasper under the similar situation as follows, but I can't.

  • Jasper app 0.3.1
  • Windows10
  • GitHub enterprise
    • with self-signed certificates
  • Coporate Proxy
    • with authentication

I also tried with electron command with --proxy-server and --ignore-certificate-errors options, but Jasper said as 'invalid setting.' In the console, following message is shown. [E] [2017-07-04T09:42:12.779Z] [rpc-server.js:249:18] self signed certificate

Is it possible to avoid the error?

hiroshis avatar Jul 04 '17 00:07 hiroshis

Finally, I could connect in my environment.

All things what I did as follows:

  1. Add the following code before Jasper throws requests to GitHub.
    process.env.NODE_TLS_REJECT_UNAUTHORIZED = "0";
  2. Re-packing apps.asar file.
  3. Run Jasper as usual.
  4. In the 'GitHub Enterprise' configuration screen, set api/v3 as 'pathPrefix'.
    (Default value is /api/v3)

I hope this will help.

hiroshis avatar Aug 02 '17 05:08 hiroshis

@azu Jasper fixed to work on http GHE. Please update to v0.4.0 👍

h13i32maru avatar Aug 20 '17 13:08 h13i32maru

@h13i32maru Has this been fixed? https://github.com/jasperapp/jasper/issues/20#issuecomment-286327373

I'm in the same problem. When I click OK button, it seems to do not send request. (I used proxy to check it.) So the problem occurs before sending request, I think.

Is there any validation rule for host format?

My environment:

Jasper app 0.5.0 OS X 10.13.3 GitHub enterprise with self-signed certificates

niwatako avatar Mar 12 '18 02:03 niwatako

I'm on 0.9.2, and this still doesn't work. Pity.

tborychowski avatar Jul 10 '20 09:07 tborychowski

I just downloaded and I'm also having this issue. version 1.0.7

sfrankle avatar Mar 01 '22 21:03 sfrankle