You are not logged in.

#1 2020-04-29 12:12:40

zandana
Member
Registered: 2020-04-29
Posts: 16

How exactly Arch Linux handles http requests to localhost?

What are all steps in details that Arch Linux takes to handle a http request from one system process to REST API running on the localhost?

Last edited by zandana (2020-04-29 12:16:41)

Offline

#2 2020-04-29 12:57:31

V1del
Forum Moderator
Registered: 2012-10-16
Posts: 25,381

Re: How exactly Arch Linux handles http requests to localhost?

It opens a  http connection to the specified port on which a relevantly registered service will react to.

This smells like a huge XY Problem. What is that you actually want to do? What doesn't work?

Offline

#3 2020-04-29 13:08:29

zandana
Member
Registered: 2020-04-29
Posts: 16

Re: How exactly Arch Linux handles http requests to localhost?

Hi V1del, I don't actually have a problem, I want to just know how the OS opens a http connection and how handles the data that flows. I'm not sure where I can find a resources that explain how exactly such things work under-the-hood.

Last edited by zandana (2020-04-29 13:09:00)

Offline

#4 2020-04-29 13:34:35

Zod
Member
From: Hoosiertucky
Registered: 2019-03-10
Posts: 636

Re: How exactly Arch Linux handles http requests to localhost?

https://tools.ietf.org/html/rfc2616

Edit: Akshully, this is a better place to start. All the things have an RFC.
https://www.rfc-editor.org/search/rfc_search.php

Last edited by Zod (2020-04-29 13:50:18)

Offline

#5 2020-04-29 13:40:59

Trilby
Inspector Parrot
Registered: 2011-11-29
Posts: 30,519
Website

Re: How exactly Arch Linux handles http requests to localhost?

But your initial question seemed to be specific to localhost.  There's really nothing special about localhost connections except that the "server" and "client" are on the same machine (that and it doesn't need to go through any router or firewall).

Last edited by Trilby (2020-04-29 14:20:20)


"UNIX is simple and coherent" - Dennis Ritchie; "GNU's Not Unix" - Richard Stallman

Offline

#6 2020-04-29 14:07:59

seth
Member
From: Won't reply 2 private help req
Registered: 2012-09-03
Posts: 77,822

Re: How exactly Arch Linux handles http requests to localhost?

There's no generic answer to the question "how does OS http" because the protocol has no specific demands to the lower layers (you can have it on a unix stream socket instead of tcp)
Also, as pointed out the host is irrelevant and the API just specifies certain http patterns - neither nor the protocol itself in any way shape or form related to the OS.

If you want to inspect a specific connection, you can wireshark it.
Otherwise please be more specific about the topic at hand - there's no generic answer.

Offline

Board footer

Powered by FluxBB