Http Using parameters in a Restlet Client Request

I have: Request request = new Request(Method.GET, "https://www.awebsite.com/login"); Client client = new Client(Protocol.HTTPS); Response response = client.handle(request); ... response.getEntity().write(System.out); But I don't know how to set the login parameters... I want code that does the escaping etc can switch between get/post easily Being a REST-based platform, I'm thinking I might need to use some parameter "representation" but that seems a bit strange. I'd think it would be

When do you initially get assigned your unique http cookies when visiting a website?

When do you initially get assigned your unique http cookies when visiting a website? I'm asking this in the sense of when creating a gui auth login from a website. Do you get your cookies the moment you visit the website? If so, if you don't visit the website by homepage and go straight to the http://website.com/login.php form, do you initially also get your cookies there if you haven't received them yet?

Http Unexpected "100 continue"

I have 2 servers that communicates using .Net remoting. For some architectural reasons, I have a proxy between those 2 servers, that removes the "Expect: 100-continue" header from the request that is sent from one server to another. The problem is, that when the proxy sends the message to the second server without this header, the destination server responses with "100 continue". This behavior causes us many problems, since the proxy discards the whole http conversation, when it gets "100 contin

HTTP 303 redirect is not working for my browsers

My jersey resource is sending this to the client browsers namely (safari & chrome) but the browsers are not redirecting. Is there anything wrong with my HTTP response below ? HTTP/1.1 303 See Other Date: Thu, 12 Nov 2009 10:17:23 GMT Location: http://twitter.com/oauth/authenticate?oauth_token=KNHo4mcLMJG Content-Length: 0 Server: Jetty(6.1.14)

Dealing with HTTP content in HTTPS pages

We have a site which is accessed entirely over HTTPS, but sometimes display external content which is HTTP (images from RSS feeds, mainly). The vast majority of our users are also stuck on IE6. I would ideally like to do both of the following Prevent the IE warning message about insecure content (so that I can show a less intrusive one, e.g. by replacing the images with a default icon as below) Present something useful to users in place of the images that they can't otherwise see; if there w

Http form submit in a non secure page

I would like someone to answer this and if possible provide some reference links to back it up (if possible). Need to prove to someone its not secure. If I have a form with the post method on a non-secure page, but the action attribute is pointing to a secure URL, is the submitted form secure?

Is https makes panel slower or lazy loading?

Previously I am using the http://domainname.com, I got some security issue so the I moved to the https://domainname.com. Previously the panel was loading very quickly after converted to https:// panel is very slow, Is there any problem with the http and https. Please give me some suggestion on this. Thanks

HTTP response to invalid proxy authentication?

If a proxy server requires authorization it returns an HTTP 407 ("Proxy Authentication Required") status code. However, what happens if a proxy server is provided authorization which is invalid? Does it return another HTTP 407 or an HTTP 401 ("Unauthorized") or ...? (A use-case might be where System.Net.WebClient from .NET uses the "default proxy credentials" which happen to be invalid.) I wouldn't mind some "steps to try it out myself", but my HTTP-foo is weak and I have no such proxy server

HTTP server and its directories

I have a custom HTTP web server, whenever I browse to it, let say: http://hotname:port it redirects to this: http://hotname:port/base The server runs from: /home/user/app_web/bin/start.pl I have a directory of HTMLs listed in: /home/user/app_web/static while the server is running, one of the request I send to him is an HTML with a body having this img: <img src="../static/page.html"> this page loads fine, but of the images in it, doesnt, which is in: "/home/user/app_web/static/image

Http Why does a telnet to port 80 seem to hit a different server than Firefox?

I'm new to low-level HTTP stuff and am not sure what to make of what I am seeing. If I go to a particular internet web server (let's call it www.someserver.com for now... I'll give the real one if it's really needed), Firefox happily pulls up its home page. If, however, I do a telnet www.someserver.com 80 GET / HTTP/1.0 ...what I get returned appears to be the Apache default "It works" page. Trying to GET another page on the server that Firefox will happily pull up receives a 404 from telnet

HTTP 400 error when server fires a long http request to another server

I have a scenario where I hit a cacheRefresh.do URL from an HTTP Client. It reaches App Server A, A refreshes its own cache and then sends a request (I am using URLConnection) to App Server B,to refresh its cache. (I know its a bad design, but we are out of option) Now when my request is refresh small cache(small response time) , everything looks fine, I get a 200. But when my request is to refresh large cache, I get a 400. Server A and B do get refreshed in this case as well, but why do I g

Http Chrome & Expires Header - Image Caching

I have a web application that contains a few hundred small images, and is performing quite badly on load. To combat this, I would like to cache static files in the browser. Using a servlet filter on Tomcat 7, I now set the expires header correctly on static files, and can see that this is returned to Chrome: Accept-Ranges:bytes Cache-Control:max-age=3600 Content-Length:40284 Content-Type:text/css Date:Sat, 14 Apr 2012 09:37:04 GMT ETag:W/"40284-1333964814000" **Expires:Sat, 14 Apr 2012 10:3

Tomcat: Websocket broadcast in responce to http POST request

I need to broadcast messages via websocket, every time I get a specific POST request. The problem is that one servlet (extended HttpServlet) receives the POST request and the another one (extended WebSocketServlet) process the websocket connections. I can't use RequestDispatcher (if I properly understand it) because of different request types and because of I need further processing request in the POST-received servlet. I don't know if I can send ws-request from first servlet to second one, bu

Http Encoding.ASCII VS Encoding.UTF8 Bug

World! I'm writing simple HTML server using .Net Framework 4 System.Net.Sockets.TcpClient. I have HTML in StringBuilder html, wich contains some text. For example: <div id="RequestText"> GET / HTTP/1.1<br/>Host: localhost:90<br/>Connection: keep-alive<br/>Cache-Control: max-age=0<br/>User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/535.11 (KHTML, like Gecko) Chrome/17.0.963.56 Safari/535.11<br/>Accept: text/html,application/xhtml+xml,applicat

Http How to use a non-www domain with heroku?

I know they don't support it, but seriously, how to do it? Point A-records to an ip which only serves up a 301 to heroku? That sounds really dumb. Am I missing something? Is there a simpler workaround?

Http GWT: unable to access xml

I'm trying to access a XML file from client side in GWT. But it looks like the sendRequest method is not getting fired at all. I'm able to see the xml in the browser. Do I need to do any thing in the server side? Any help is appreciated. Here's my code String xmlurl = "http://localhost:8888/test.xml"; RequestBuilder builder = new RequestBuilder(RequestBuilder.GET, URL.encode(xmlurl)); try { Request request = builder.sendRequest(null, new RequestCallback() { public

Integrity of http using browser

How is it possible to check the integrity of http messages in a way browser can do ? Actually Digest authentication with "qop=auth-int" would work (because the md5 is also over the body) but unfortunately this is not supported by common webservers (like apache). Is there a way ?

Scala/Java HTTP parse POST data form-encoded arrays

I use Finatra. If I send POST data of the kind application/x-www-form-urlencoded; charset=UTF-8 where the data is of the kind options[0][name]:option1 options[0][value]:1 options[1][name]:option2 options[1][value]:2 what is a good way to get a List of (name, value) on the server?

nginx removes content length http header after proxy_pass

I have a problem that nginx removes the content-length header after the proxy pass. the application back-end sends a gzip stream but specifies the content length. NGINX changes the type content-type to chunked and removes the content length header. This is not acceptable for the app since it is read not by the browser but by an proprietary app that requires the content-legth to be specified. After specified chunked_transfer_encoding off; it stops adding the content type header but still re

Http How do I get response URI from a Jersey web response?

If I do: Response response = webTarget.request().get(); URI redirectUri = response.getLocation(); response.getLocation() will be null if Jersey does not need to follow a redirect or automatically follows a redirect. Only for manual, non automatic redirects will response.getLocation() be non-null. How do I tell if the Jersey Response followed an automatic redirect? How do I get that URL?

http bcrypt sending username and password

Is it safe to send a bcrypt encrypted username and password through a http post? I basically just want to set a server up for my friends with a username and password that is encrypted so they can access stuff on my server.

Passing in parameters to a http.HandlerFunc

I'm using Go's built in http server and pat to respond to some URLs: mux.Get("/products", http.HandlerFunc(index)) func index(w http.ResponseWriter, r *http.Request) { // Do something. } I need to pass in an extra parameter to this handler function - an interface. func (api Api) Attach(resourceManager interface{}, route string) { // Apply typical REST actions to Mux. // ie: Product - to /products mux.Get(route, http.HandlerFunc(index(resourceManager))) // ie: Product

HTTP codes & headers to determine behaviour

Can anyone give (or point to) a guide to various ways that http codes and headers are used to determine a response? I am interested in patterns used by app frameworks (e.g. Django), browser plugins or anything else which can conceivably handle a response. Do the currently specified codes and headers facilitate most needs, or are there interesting demands for new headers to be incorporated into the spec?

Is it necessary to check both '\r\n\r\n' and '\n\n' as HTTP Header/Content separator?

The accepted answer on this page says we should check HTTP server responses for both \r\n\r\n and \n\n as the sequence that separates the headers from the content. Like: HTTP/1.1 200 Ok\r\n Server: AAA\r\n Cache-Control: no-cache\r\n Date: Fri, 07 Nov 2014 23:20:27 GMT\r\n Content-Type: text/html\r\n Connection: close\r\n\r\n <-------------- or: HTTP/1.1 200 Ok\r\n Server: AAA\r\n Cache-Control: no-cache\r\n Date: Fri, 07 Nov 2014 23:20:27 GMT\r\n Content-Type: text/html\r\n Connection

IBM HTTP Server, routing calls to Websphere

Something I have been struggling with for a while, but I'm not able to come up with a proper solution. This is the situation: Host 1 - IBM HTTP Server, Customization Toolbox and WAS Plugins Host 2 - WAS + Application These are the steps I executed to configure the plugin and propagate it from Websphere: 1. I used the Customization Toolbox, selected the correct WAS Plugins directory and created a new Web Server Plugin 2. I copied the new configureSERVER.bat to my Application Server on Host

Measurement Protocol HTTP Batch event POST instead of POST per event?

I want to batch my requests to the Google Analytics Measurement Protocol POST /collect HTTP/1.1 Host: www.google-analytics.com payload_data I'm developing in Unity 3D, but mainly I was curious if anyone had ideas so I can reduce the number of http requests from the client. NOTE: I have no plans to use Googles Analytics SDK for Unity. Please do not suggest. I want to use the Measurement Protocol API. Thanks, NOTE: multipart/mixed might be a good solution, but I suspect the API needs to suppo

Http Generating SHA-2 certificate with ikeyman

Trying to move from SHA-1 SSL to SHA-2 SSL since SHA-1 certificates expiring as of Jan 2016. I am using ikeyman version 8.0.344 to generate a new SHA-2 cert. Couple of questions I have I am generating kdb, and under Create new Key and cert request I have selected: key Size: 2048, Sig. Algorithm: SHA2WithRSA Are these 2 values correct selections? 2.After created the cert. request, I viewed what I generated and seeing Fingerprint (SHA1 Digest): num:num:num... Signature Algorithm: SHA25

Http Difference between GET and PROPFIND in WebDAV

According to WebDAV specification (RFC 4918): The semantics of GET are unchanged when applied to a collection, since GET is defined as, "retrieve whatever information (in the form of an entity) is identified by the Request-URI" [RFC2616]. and PROPFIND retrieves properties defined on the resource identified by the Request-URI. So GET and PROPFIND more or less retrieve the information of a resource. In this sense, is there any major difference between GET and PROPFIND and when sho

Http How to remove Mule default headers and set Headers received from Third party API

Please help in setting HTTP Headers in mule. I want to remove default mule headers and send the HTTP headers received from third party API as response headers I tried by using following groovy code. But it didnt work. import org.json.JSONObject; import java.lang.String; import java.util.*; import java.util.Map; import java.util.Map.Entry; JSONObject cResponse = new JSONObject(payload); System.out.println("http.headers:"+message.getInboundProperty('http.headers')); Map<String, Object> he

Http Search Form generating the wrong URL request

I am trying to performed a Search Form using Simple_Form gem. I need to select a value from a collection, do some calculation and return a result. The controller works, if I manually write de URL it will work. If I generate it with the form, the URL construction is not doing what I am expecting. This is what I get: http://0.0.0.0:3000/nearestVehicle?nearestVehicle%5Baddrnr%5D=0001 This is what I need to get: http://0.0.0.0:3000/nearestVehicle?addrnr=0001 View: <%= simple_form_for :ne

Using HTTP Angular

I'm trying to make a simple HTTP request using Angular, but I keep getting this error: Property 'http' does not exist on type 'WorksService'. import {Injectable} from 'angular2/core'; import {Http, HTTP_PROVIDERS, Response} from 'angular2/http'; import {Observable} from 'rxjs/Observable'; export class Work { constructor(public id: number, public name: string) { } } @Injectable() export class WorksService { constructor (private http: Http) {} private _WorksUrl = 'api/proj

Http Downsides of 'Access-Control-Allow-Origin: *'?

I have a website with a separate subdomain for static files. I found out that I need to set the Access-Control-Allow-Origin header in order for certain AJAX features to work, specifically fonts. I want to be able to access the static subdomain from localhost for testing as well as from the www subdomain. The simple solution seeems to be Access-Control-Allow-Origin: *. My server uses nginx. What are the main reasons that you might not want to use a wildcard for Access-Control-Allow-Origin in you

how to log http redirects when using Safari

Safari seems not to log http redirects in the network inspector tool. I'm in a environment where I can't use http proxy (like Charles) so I'm wondering if there's any safari plugin able to do that. Thanks.

Http uri is too long when I try to send a base64 using xamarin forms

I am working with xamarin.forms and System.Net.Http; I am sending a photo using a post function which is this: public static async Task<String> PostImagemAsync(User user) { using (var client = new HttpClient()) { try { var values = new List<KeyValuePair<string, string>>(0); values.Add(new KeyValuePair<string, string>("email", user.usua_login)); values.Add(new KeyValuePair<str

HTTP/HTTPS content authentication

I could find any quick answer on google. Most probably the answer lies somewhere in RFC docs on http or https however I just couldn't (too time consuming ) get those information. So here is the question: Is the content of a webpage served through HTTP signed digitally by the server ? Same question for HTTPS. If yes, how does it work correctly when using a proxy ? In my opinion the proxy could tamper the data, sign the tampered data with it's own private key, and claim that the corresponding prox

Http Closing connections with github GraphQL API

When establishing connection with database it is good to close the db connection normally. Does the same apply for HTTP connections? I tried to send request to Github GraphQL API to get repositories and pull requests of each repository. I send requests separately by establishing end points. So is it good to close the connection? If so, what is the proper way to do it?

Http Prevent any caching in the browser

Which header(s) can I use to prevent any caching on the part of the browser? https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Cache-Control would it simply be: res.setHeader('cache-control','no-cache');

centos 7 - can ping http & https websites but not able to browse http sites in any browser

I messed up something in my centos 7 system. In terminal, i can ping http & https websites. But on any browser am not able to browse http sites. Eg: I can ping yopmail.com But in chrome, mozilla, firefox am not able to browse yopmail.com Basically no webpages will open in any browser if its http. But i can browse all https webpages. Unfortunately yopmail does not have https. A week back i tried to set up an ipsec vpn. Didn't go well. Am assuming i messed something up in the process. unfort

Http Hiding confidential text files on local server

I'm testing a website using a python http.server. I'm accessing the server via localhost. There are some direct object references. (e.g. if I head straight to the text file, localhost:8000/logs.txt) I am able to access the file. What's the best method to hiding the log file from the outside world? I'm currently encasing the txt in many folders using the technique security through obscurity. I was just wondering if there are any other methods to keep the file on the server, but hide it from

Flutter http request upload mp3 file

Im using this api to upload a mp3 file using this method Future<void> uploadRecord(String matchId, String filePath) async { Uri url = Uri.parse( Urls.baseurl + EndPoints.uploadRecordEndPoint + '${auth.token}'); final request = http.MultipartRequest('POST', url) ..fields['match_id'] = matchId ..files.add(http.MultipartFile.fromBytes( 'file', await File.fromUri(Uri(path: filePath)).readAsBytes(), contentType: MediaType('audio', 'mpeg'))

Http LinkedIn API People Search

I haven't seen any questions around this topic after 2019 so I've decided to ask some. The topic is LinkedIn v1 and v2 APIs. Are there any "GET" requests that let me get a list of people from a people search? Are there any other features that would let me send messages through LinkedIn's API? I'm working in python3 and: linkedin = OAuth2Session(client_id, redirect_uri=some_address, scope=scope) linkedin.fetch_token(token_url, client_secret=client_secret, include_clien

Http Unknown API function: "files/upload

I Am New TO dropbox api Today i tried to upload a file from https api but got error while uploading the file Unknown API function: "files/upload My code is function main() local oHTTP,cJSON,url setmode(25,80) ctoken := "<REDACTED>" * // cJSON = {"path": "hb_cwd()+"report.txt","mode": "add","autorename": true,"mute": false,"strict_conflict": false"} url := "https://content.dropboxapi.com/2/files/upload \" + ctoken cJSON := '{"c:\tmp\pdf\CKF1907319.pd

Http Using Self-Signed SSL certificate

I am developing an online-shop based on a Telegram Bot, and I need to host it on a VPS. What are the dangers if I use a self-signed SSL certificate? I found online that there's a MiTM attack threat, but I couldn't find a detailed explanation on how it can be avoided when using a self-signed SSL. For example, will it help if all requests are sent to/from a URL of type: www.example.com/?

Http So I made a music bot, but i don't know if this is a discord error

I wanted to make a livestream play in a vc! IT WORKED but now I get the following "error" [https @ 0xe5b5c0] Cannot reuse HTTP connection for different host: r2---sn-25ge7nsl.googlevideo.com:-1 != r4---sn-25ge7nsl.googlevideo.com:-1 [hls,applehttp @ 0xc06250] keepalive request failed for 'https://r4---sn-25ge7nsl.googlevideo.com/videoplayback/id/DWcJFNfaw9c.2/itag/96/source/yt_live_broadcast/expire/1603923091/ei/M5iZX4_VIMLUW57fiOAO/ip/2a01:cb00:39c:2900:835b:2f40:d2bf:7a5d/requiressl/

Http Usage of different ports by one email app

I am learning about TCP, HTTP, and ports, I am confused about how they are used. Say, I want to create a mobile app for sending and receiving emails. I know that e.g. port 80 is used for HTTP traffic, and port 25 for email, and port 22 for login. Will the mobile app use port 22 every time the user logs in in the app? If an email has a picture, will this picture be loaded via port 80 as HTTP traffic? For the actual email data, will the app use port 25? Another thing that really confuses me: I'v

  1    2   3   4   5   6  ... 下一页 最后一页 共 57 页