Is JIRA server blocking file:// protocol?
Currently, I'm developing an application made with Electron and Angular. Basically, with Electron, the application is under file:// protocol.
Now, I asked this question because when I tried to submit worklog using JIRA REST API. It gives me an error "Expected authority at index 7: file://". Other APIs with GET method work fine though.
Based on observation, GET method doesn't have Origin on the request header while, POST method has it. Origin is "file://"
With this, I suspected that JIRA is blocking file:// protocol.
Is there anything I can do to make this work? I should be able to submit worklog.
My issue has already been resolved but I still think that Jira server is rejecting request with file:// protocol on its origin header.
I say this because the way I resolved my issue is just changing the value of the origin header from file:// to my Jira base url - https://xxyyzz.atlassian.net
It's not "blocking" anything. Your data was telling it to use the wrong protocol.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
It's not "JIRA blocking", more that REST is usually implemented only over http/https, as file:// is not particularly useful for REST calls, and you'd have to write a whole other interface layer to expose it, rather than just go with the existing http(s) that comes automatically when running a web-service.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi mate,
What I mean is that, the application is not running on any server. Basically, it's not on http/https protocol. It's just reading the html file on my local machine so that why it's under file:// protocol.
However, the JIRA REST API that I'm trying to call is "https://xxyyzz.atlassian.net/rest/api/latest/issue/<Issue>/worklog" with POST method.
While my application is running under file:// protocol and then tried to call the API mentioned above, I get an error "Expected authority at index 7: file://". I think that when JIRA server received the request my application sent and found out that the origin is from file:// and not from http/https, it then rejected the request.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
No, the REST API is simply a service that you call. You're using an https POST to connect. How you're doing that or where from is utterly irrelevant.
I suspect you're simply posting data in the wrong format.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.