Questions tagged [http-headers]

In the Hypertext Transfer Protocol (HTTP), HTTP header fields contain the operating parameters of an HTTP request or response. With the request or response line (first line of message), they form the message header.

The header fields define various characteristics of the data transfer that is requested, or the data that is provided in the message body.

Header fields start with the field name, terminated with a colon character, followed by the field value. Field names and values may be any application-specific strings, but a core set of fields is standardized by the Internet Engineering Task Force (IETF) in RFC 2616 and other updates and extension documents (e.g. RFC 4229), and are commonly understood by all compliant protocol implementations.

Many parameters may be followed by a quality or 'q' value, giving a weight to use in content negotiation. The HTTP message header is separated from the message body by a blank line.

List of HTTP Header fields

11828 questions
5
votes
2 answers

How do I resolve resource was blocked, MIME type mismatch in Angular?

I am following Angular documentation attempting to try out a basic Web Worker sample. I built a basic Angular template app and it runs fine. I added a very basic component named RunnerComponent and then ran the command (as directed by docs): ng…
raddevus
  • 8,142
  • 7
  • 66
  • 87
5
votes
1 answer

How to configure CSP-headers with express/node.js?

I try to get the tags working in an express/node.js environment but somehow they always get blocked by the content security policy. I already tried using multiple node-modules like express-csp-header or csp-header but none of them did the trick. So…
5
votes
0 answers

How does Chrome determine a downloaded file's name on disk?

How does Chrome determine the name of the file being saved to disk when downloading a file? Whenever I download a file from a particular website I am working on (as a developer), Chrome is appending an underscore to the end of the file extension. …
Joel B
  • 801
  • 1
  • 11
  • 30
5
votes
0 answers

Content-Length is randomly null

I'm trying to download from a specific URL using this code: var requestUri = "https://github.com/gus33000/MSM8994-8992-NT-ARM64-Drivers/archive/master.zip"; using (var client = new HttpClient()) { using (var response = await…
SuperJMN
  • 13,110
  • 16
  • 86
  • 185
5
votes
1 answer

HTTP_X_HEADER, X_HEADER or X-Header with Ruby on Rails?

It looks like there are multiple ways of fetching headers using Rails. If the request has a header named X-Header, all of the three work: request.headers["HTTP_X_HEADER"] request.headers["X_HEADER"] request.headers["X-Header"] Which one should I…
vinibrsl
  • 6,563
  • 4
  • 31
  • 44
5
votes
2 answers

RestEASY Interceptor Not Being Called

I've created a RestEASY Interceptor to allow me to set header values on the HTTP response after my webservice call has completed. My code looks like this... @Provider @ServerInterceptor @Precedence("HEADER_DECORATORS") public class…
Shadowman
  • 11,150
  • 19
  • 100
  • 198
5
votes
3 answers

Manage HTTP Headers for Azure static website

There doesn't seem to be a clear and defined way to manage HTTP headers with an Azure static website. I know this feature is still in preview but my team and I are attempting to make this into a production ready web application. I think most people…
5
votes
0 answers

Use HTTP preload with EventSource/Server Sent Events?

I have a page that immediately starts streaming events upon load, via an EventSource. To speed up the start of that stream, I'd like to use HTTP preload meta tags. But when I add this to my page:
Alastair
  • 5,894
  • 7
  • 34
  • 61
5
votes
1 answer

meta http-equiv - is it sent as part of an HTTP header, or does the client parse the body for meta tags?

Wikipedia seems to imply that in a web page causes the server to update the response header, but that doesn't sound right to me since the server would have to parse the document before it's sent. That would be fugly. But, I'm…
Blue
  • 107
  • 1
  • 1
  • 7
5
votes
2 answers

Is it possible to change headers order using HttpWebRequest?

I need to change the order of headers, I'm using this: HttpWebRequest request = (HttpWebRequest)WebRequest.Create(URL); request.Method = context.Request.HttpMethod; request.UserAgent = context.Request.UserAgent; The output for that is: GET /*…
Tute
  • 6,943
  • 12
  • 51
  • 61
5
votes
1 answer

Prevent unauthorised access to Restful API

I had created an Android app that requests resources from the server using Rest APIs. Now how can I check on the server side that the request is from the app and its not from the Postman. For example, I am using the following endpoint to get data…
Amarjit Singh
  • 2,068
  • 19
  • 52
5
votes
2 answers

HTTPServer.run requires a BaseHTTPRequestHandler class instead an object

I have an own class derived from BaseHTTPRequestHandler, which implements my specific GET method. This works quite fine: from http.server import BaseHTTPRequestHandler, HTTPServer class MyHTTPRequestHandler(BaseHTTPRequestHandler): def…
tangoal
  • 724
  • 1
  • 9
  • 28
5
votes
4 answers

How to read the status from response in angular http?

I am facing some problem in reading the status code from response. I am calling api in service, return this.http.get( this.remoteServer + '/google.com/open', httpOptions); In my controller I have, open() { …
Anil
  • 1,748
  • 8
  • 32
  • 67
5
votes
3 answers

Send custom header with Angular 5

I am trying to send a custom HTTP Header from the front end app for it to interact with the gateway. This is my angular function: import {Http, Headers, Response, RequestOptions } from ‘@angular/http’; getXById(id :number){ let options = nee…
Auyer
  • 2,693
  • 3
  • 15
  • 32
5
votes
1 answer

Content-Disposition filename in Chinese not supported

I have been trying to download attachment with Chinese filename but somehow their encoding changes while downloading and some gibberish filename is saved where there are Chinese chararchters. Technology: Java Server: Apache Tomcat This is what I've…
1 2 3
99
100