Is JIRA server blocking file:// protocol?

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.

2 answers

0 votes

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.

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 "<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.

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.

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 -

It's not "blocking" anything.  Your data was telling it to use the wrong protocol.

Suggest an answer

Log in or Sign up to answer
Community showcase
Published Jan 08, 2019 in Jira

How to Jira for designers

I’m a designer on the Jira team. For a long time, I’ve fielded questions from other designers about how they should be using Jira Software with their design team. I’ve also heard feedback from other ...

1,023 views 4 9
Read article

Atlassian User Groups

Connect with like-minded Atlassian users at free events near you!

Find a group

Connect with like-minded Atlassian users at free events near you!

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you