浏览器 输入网址 发生什么

It’s commonplace. We type a web address into the browser and hit Enter. With modern internet connections the page loads almost instantaneously. We’re at the site we wanted, reading or shopping, and don’t give the inner workings a second thought. But if you aim for a career in tech you need to know how to answer this common question: What happens when you type an address in your browser and press Enter?

这很平常。 我们在浏览器中Enter网址,然后Enter 。 使用现代的Internet连接,页面几乎可以立即加载。 我们在想要的网站上阅读或购物,请勿再犹豫内部工作。 但是,如果您打算从事技术职业,则需要知道如何回答这个常见问题:在浏览器中键入地址并按Enter时会发生什么?

First, your browser is a client in the client-server model.

首先,您的浏览器是client-server模型中的客户端

The client-server model describes how a server provides resources and services to one or more clients. Examples of servers include web servers, mail servers, and file servers. Each of these servers provide resources to client devices, such as desktop computers, laptops, tablets, and smartphones. Most servers have a one-to-many relationship with clients, meaning a single server can provide resources to multiple clients at one time. –Client-Server Model

客户端-服务器模型描述了服务器如何向一个或多个客户端提供资源和服务。 服务器的示例包括Web服务器,邮件服务器和文件服务器。 这些服务器中的每一个都为客户端设备(例如台式机,笔记本电脑,平板电脑和智能手机)提供资源。 大多数服务器与客户端具有一对多关系,这意味着单个服务器可以一次为多个客户端提供资源。 – 客户端-服务器模型

You’re the user, the tool you’re using to request information is the client. The requests are answered by the server. There are many steps in this process.

您是用户,用于请求信息的工具是客户端。 服务器答复请求。 这个过程有很多步骤。

域名解析 (DNS)

The Domain Name System (DNS) is the largest distributed database in the world and has been an essential component of the functionality of the Internet since 1985. It is used to translate web addresses to the respective IP addresses (we’ll get to those later). Computers have no trouble with numbers, but humans are more likely to remember words such as “Google.com”. DNS helps connect the two, and it does much more along the way.

域名系统(DNS)是世界上最大的分布式数据库,自1985年以来一直是Internet功能的重要组成部分。它用于将网址转换为相应的IP地址(我们将在后面介绍) )。 计算机没有数字上的麻烦,但是人们更容易记住“ Google.com”之类的词。 DNS有助于将两者连接起来,并且在此过程中做得更多。

A DNS request is often the first step when you hit that Enter button. I say “often” because the browser will check it’s own stored information (cache) and as the operating system (OS) to do the same before a DNS request is formally made. If that fails, a resolver is needed. Your resolver server is usually your Internet Service Provider (ISP). The OS requests the resolver and asks for the IP associated with the web address you’ve entered. At this time, the resolver checks it’s own cache just in case it already has the information handy. If it doesn’t, it will ask the root server.

当您按下Enter键时,DNS请求通常是第一步。 我之所以说“经常”,是因为浏览器会在正式发出DNS请求之前检查其自身存储的信息(缓存),并作为操作系统(OS)进行同样的操作。 如果失败,则需要解析器。 您的解析器服务器通常是Internet服务提供商(ISP)。 操作系统请求解析器,并要求与您输入的网址关联的IP。 这时,解析器检查它自己的缓存,以防万一它已经掌握了信息。 如果没有,它将询问根服务器。

The root server will direct the resolver to the .COM Top-level Domain (TLD) server. We need the .COM TLD server if the URL (Uniform Resource Locator) you enter ends in “.com”. As you can guess, there are many other possible TLD servers. The IP we need is still a few steps away, though, because the TLD only directs the resolver to the Authoritative Name Servers (ANS) associated with your URL. These are given to the TLD system when the domain is first created and just for this purpose.

根服务器会将解析器定向到.COM顶级域(TLD)服务器。 如果您输入的URL(统一资源定位符)以“ .com”结尾,则我们需要.COM TLD服务器。 您可以猜测,还有许多其他可能的TLD服务器。 但是,由于TLD仅将解析器定向到与您的URL关联的权威名称服务器(ANS),因此我们所需的IP仍在几步之遥。 这些是在首次创建域时(仅出于此目的)提供给TLD系统的。

Any ANS that answers the resolver has the IP because it holds the “A Records” for the domain: in this case our address is linked to the IP “34.234.197.104”. Before we move on, it’s important to note that as part of the process the resolver records and holds onto the information it gathers to save time in the future. What a beautiful system!

任何回答解析器的ANS都有IP,因为它拥有域的“ A记录”:在这种情况下,我们的地址链接到IP“ 34.234.197.104”。 在继续进行之前,重要的是要注意,作为解析过程的一部分,解析器会记录并保留所收集的信息,以节省将来的时间。 多么漂亮的系统!

什么是IP? (What’s an IP?)

I’ve mentioned Internet Protocol addresses but haven’t explained what they are. Above, we followed a resolver as it searched for the address that matched the URL you entered. Why?

我已经提到了Internet协议地址,但没有说明它们是什么。 上方,我们跟随一个解析器,它搜索与您输入的URL匹配的地址。 为什么?

An Internet Protocol address (IP address) is a numerical label assigned to each device connected to a computer network that uses the Internet Protocol for communication. An IP address serves two main functions: host or network interface identification and location addressing.–Wikipedia

Internet协议地址 ( IP地址 )是分配给连接到使用Internet协议进行通信的计算机网络的每个设备的数字标签。 IP地址具有两个主要功能:主机或网络接口标识和位置寻址。– Wikipedia

Not only does the server for the site you’re trying to reach have an IP address, you have one too. Yours can change depending on how you connect to the internet, but it’s there to identify you so that your interactions online can be understood and interpreted with a set of protocols, Internet Protocols.

您要访问的站点的服务器不仅具有IP地址,而且也具有IP地址。 您的连接方式可能会有所变化,具体取决于您连接到Internet的方式,但是在那里可以识别您的身份,以便可以通过一组协议(Internet协议)来理解和解释在线交互。

An IP address is very much a sequence of numbers, such as 34.234.197.104 in IPv4, and 2001:db8:0:1234:0:567:8:1 in IPv6. (We need more numbers now, so we’re getting a larger set with IPv6). The complex mapping system used for IP addresses is, well, complex.

IP地址实际上是一个数字序列,例如IPv4中的34.234.197.104和IPv6中的2001:db8:0:1234:0:567:8:1 。 (我们现在需要更多的数字,因此使用IPv6将获得更大的数字)。 用于IP地址的复杂映射系统非常复杂。

https://xkcd.com/195/https://xkcd.com/195/

IP is not the only type of protocol used on the Internet. The Internet Protocol Suite is often referred to as TCP/IP (Transmission Control Protocol), and it also contains other types of protocols. TCP/IP is a set of rules that control how servers and clients interact over a network and how data is transferred, broken into packets, and received.

IP不是Internet上使用的唯一协议类型。 Internet协议套件通常被称为TCP / IP(传输控制协议),并且它还包含其他类型的协议。 TCP / IP是一组规则,用于控制服务器和客户端如何通过网络进行交互以及如何传输,拆分和接收数据。

The resolver heads back to your browser with the IP address, but the process is far from over.

解析器使用IP地址返回您的浏览器,但是此过程远未结束。

防火墙 (Firewalls)

Servers are often equipped with one or more firewalls to protect themselves from malicious attacks. A firewall is software that allows the owner to set rules about what information can enter or leave any part of a network. When your browser asks for the site at 34.234.197.104, your request is processed by a firewall which decides if you are a threat to the security of the server. Even your own browser can have a firewall to protect your system from malicious IPs.

服务器通常配备一个或多个防火墙,以保护自己免受恶意攻击。 防火墙是一种软件,允许所有者设置有关哪些信息可以进入或离开网络任何部分的规则。 当浏览器在34.234.197.104处请求该站点时,防火墙将处理您的请求,该防火墙确定您是否威胁到服务器的安全性。 甚至您自己的浏览器也可以具有防火墙,以保护系统免受恶意IP的侵害。

HTTPS / SSL (HTTPS/SSL)

When we type out web addresses, we often leave off an important bit.

当我们输入网址时,我们通常会忽略一些重要的内容。

What does https mean?
https是什么意思?

HTTPS stands for HyperText Transfer Protocol Secure, and is a more secure version of HTTP. This transfer protocol defines different types of requests and responses served to clients and servers over a network. This protocol defines how servers and clients make and fulfill requests. HTTP and HTTPS requests include GET, POST, and PUT. The HTTPS traffic is encrypted to ensure users that their data can’t be stolen or seen by third parties. We take advantage of this whenever we shop online or file taxes with TurboTax.

HTTPS代表“安全超文本传输​​协议”,是HTTP的更安全版本。 该传输协议定义了通过网络服务于客户端和服务器的不同类型的请求响应 。 该协议定义服务器和客户端如何发出和满足请求。 HTTP和HTTPS请求包括GET,POST和PUT。 HTTPS通信经过加密,以确保用户不会窃取或看到第三方的数据。 每当我们在线购物或通过TurboTax纳税时,我们都会利用这一优势。

Now let’s talk about the SSL certificate. SSL stands for Secure Sockets Layer (also known as TSL, Transport Layer Security). This certificate is issued and managed by trusted Certificate Authorities such as Let’s Encrypt. Public and private key pairs are issued and configured by the owner, and they are compared in a “handshake” every time a client requests access. If they don’t match, that request is revoked. On Firefox and other browsers you can check for secure connections in the address bar, and it is often represented by a small lock icon.

现在让我们谈谈SSL证书。 SSL代表安全套接字层(也称为TSL,传输层安全性)。 该证书由可信的证书颁发机构(如Let's Encrypt )颁发和管理。 公钥和私钥对由所有者发布和配置,并且每次客户端请求访问时都会以“握手”方式对它们进行比较。 如果它们不匹配,则该请求将被撤消。 在Firefox和其他浏览器上,您可以在地址栏中检查安全连接,该地址通常由一个小的锁定图标表示。

多台服务器需要负载均衡器 (Multiple Servers need a Load Balancer)

We still haven’t loaded the web page in our browser. When the request was checked for security, it hit the first Firewall as well, and it’s likely that Firewall was protecting a server type called a Load Balancer. Load balancing is the process of distributing network traffic across multiple servers. The Load Balancing server doesn’t contain the data used to render the webpage. Instead, it directs traffic to a number of servers that do. A Load Balancing Server handles traffic so that downtime can be minimized in the event of maintenance or failure on the part of one of the servers. It’s often where the SSL handshake ends, but there can still be Firewalls ahead.

我们仍然没有在浏览器中加载网页。 当检查请求的安全性时,它也会同时攻击第一个防火墙,并且防火墙很可能正在保护称为负载均衡器的服务器类型。 负载平衡是在多个服务器之间分配网络流量的过程。 负载平衡服务器不包含用于呈现网页的数据。 相反,它将流量定向到许多这样做的服务器。 Load Balancing服务器处理流量,以便在一台服务器上进行维护或发生故障时可以将停机时间减至最少。 SSL握手通常在此结束,但是前面仍然有防火墙。

Web服务器和应用服务器 (Web Servers & Application Servers)

We’re almost there! Here are the servers, often behind more firewalls, that contain everything you need to render a the webpage. There can be many; they are usually carbon copies of one another for redundancy. Each server has an operating system (Let’s say Linux), Web Server software (Let’s say Apache), a database (Let’s say MySQL) , Application Server software or scripting for the codebase (Let’s say Python). I chose those options because they make up the LAMP stack, but other combinations working together or “stacks” are used as well.

我们快到了! 这些服务器通常位于更多防火墙之后,其中包含呈现网页所需的所有内容。 可以有很多; 它们通常是彼此的副本,以提供冗余。 每个服务器都有一个操作系统(比如说Linux),Web服务器软件(比如说Apache),一个数据库(比如说MySQL),应用服务器软件或代码库脚本(比如说Python)。 我之所以选择这些选项,是因为它们构成了LAMP堆栈,但是也可以使用其他组合在一起的组合或“堆栈”。

Of my example stack, I’ll explain a few:

在示例堆栈中,我将解释一些:

  • A web server is a software program that serves static content, like simple HTML pages, images, and plain text files.Web服务器是提供静态内容的软件程序,例如简单HTML页面,图像和纯文本文件。
  • An application server is a software program responsible for operating applications and communicating with the databases to serve dynamic content based on the request the client makes.应用程序服务器是一个软件程序,负责运行应用程序并与数据库进行通信以根据客户端的请求提供动态内容。
  • The database is a collection of data, and the Data Base Management System (DBMS) is the program that interacts with the database to retrieve, add, and modify data.

    数据库是数据的集合,数据库管理系统(DBMS)是与数据库交互以检索,添加和修改数据的程序。

最后,网页 (Finally, the web page)

Your requests and the subsequent responses travel around in complicated pathways until you’ve made it to the server. The web server software serves the static content, and if you log in or enter more information the application server works with the database to create dynamic content for you to view and interact with. This is how a a website works.

您的请求和随后的响应会以复杂的路径传播,直到到达服务器为止。 Web服务器软件提供静态内容,如果您登录或输入更多信息,则应用程序服务器将与数据库一起使用以创建动态内容供您查看和交互。 这就是网站的工作方式。

Everyday interactions on the internet don’t require you to know or understand any of this. But it is becoming increasingly more likely for “regular folk” to make their own websites or online shops, and a basic understanding of the inner workings can be helpful. Thanks for reading!

互联网上的日常互动不需要您了解或理解任何这些内容。 但是,“普通人”制作自己的网站或网上商店的可能性越来越高,对内部工作原理的基本了解可能会有所帮助。 谢谢阅读!

翻译自: https://medium.com/swlh/what-is-going-on-when-you-enter-a-url-into-a-browser-2610e1da32ac

浏览器 输入网址 发生什么


http://www.taodudu.cc/news/show-5580833.html

相关文章:

  • 加密数据机器学习_机器学习加密数据不再是幻想
  • 点击pv转化率_增加PV降低跳出率提高转化率
  • 税务合规软件的全球与中国市场2022-2028年:技术、参与者、趋势、市场规模及占有率研究报告
  • 关于DevOps你必须知道的11件事
  • kafka irs_如何使用IRS免费文件免费获取TurboTax或H&R Block
  • turbotax原理_使用OpenTaxSolver作为TurboTax的开源替代品
  • 算法竞赛入门【码蹄集进阶塔335题】(MT2026-2050)
  • 破解花式反爬之大众点评-中
  • C语言-取数组首地址
  • C语言 函数返回二维数组
  • C语言——函数和数组的简单介绍
  • c语言函数将如何返数组,声明一个C函数返回一个数组
  • [C语言] 初始函数 数组
  • C语言 函数返回数组和指针区别
  • c语言函数输出数组,如何让C语言函数返回一个二维数组
  • c语言函数的数组返回和指针返回
  • 关于C语言函数返回数组的问题【转】
  • auto.js之蚂蚁庄园自动化
  • 怎么关闭蚂蚁庄园_蚂蚁庄园账户如何注销
  • Python文件的基本操作和目录操作 笔记分享
  • 这位大佬辅导了近千人成功就业
  • 长远发展java还是cocos_聊聊 Cocos Creator 3D 的未来
  • 云端总汇
  • 文件的读写基础知识总结
  • Python文件及目录操作(基本文件操作篇)
  • 支付宝二维码可以抓包更改金额_用fiddler对手机上的app程序进行https抓包 - 365学习...
  • 零基础学Python--------第10章 文件及目录操作
  • 设计一个简单的UI框架,实现不同模块之间相互转换,使用单例实现。
  • Python中的文件及目录操作
  • 使用auto.js定时收取蚂蚁森林能量和积分

浏览器 输入网址 发生什么_在浏览器中输入网址时发生了什么相关推荐

  1. python中如何输入多行字符_在python中输入多行字符串有哪些方法

    在python中输入多行字符串有哪些方法 发布时间:2020-04-11 13:46:24 来源:亿速云 阅读:39 作者:小新 今天小编给大家分享的是在python中输入多行字符串有哪些方法,很多人 ...

  2. CAD入门攻略:CAD软件中动态输入坐标与在CAD命令行中输入坐标的区别

    浩辰CAD软件提供了动态输入功能,动态输入可以让我们将注意力集中到图面上,在绘制图纸的过程中不必经常看CAD命令行,从而提高绘图效率.但什么时候是相对坐标,什么时候是绝对坐标,对图纸绘制也是有所影响的 ...

  3. 手机火狐浏览器怎么设置电脑模式_手机浏览器pc版电脑模拟设置教程(图示)

    手机浏览器pc版电脑模拟设置教程(图示) 一.Chrome*浏览器 chrome模拟手机总共有四种方法,原理都一样,通过伪装User-Agent,将浏览器模拟成Android设备.以下标星的为推荐方法 ...

  4. java 异常处理发生异常_处理Java中的异常

    java 异常处理发生异常 每个程序员都希望编写一个完美的程序. 也就是说,程序运行时没有任何障碍. 好吧,如果希望是马,乞g就会骑. 除了程序员的所有愿望之外,有时还会发生无法预料的情况. 在Jav ...

  5. vs 启动调用的目标发生异常_协程中的取消和异常 | 取消操作详解

    在日常的开发中,我们都知道应该避免不必要的任务处理来节省设备的内存空间和电量的使用--这一原则在协程中同样适用.您需要控制好协程的生命周期,在不需要使用的时候将它取消,这也是结构化并发所倡导的,继续阅 ...

  6. javascript原型_在JavaScript中冻结原型时会发生什么

    javascript原型 Have you wondered what happens when you freeze the prototype of an object? Let's find o ...

  7. alv界面允许数字输入负号_在Excel中输入这些字符,我被虐哭了

    我们有时会需要在Excel中输入一些特殊字符,如果没有掌握一些小技巧,绝对会被虐哭! 1.输入 ± 符号 利用拼音输入法(zhengfuhao),如下图所示: PS:利用输入法输入±,数字会变成文本, ...

  8. 运放输入偏置电流方向_运放中输入偏置电流和输入失调电流的区别

    运放中输入偏置电流和输入失调电流的区别 运放的 输入偏置电流 : 为了使运放输入级放大器工作在线性区 , 所必须输入的一个直流电流 , 在双极晶体管输入的运放 , 偏置电流就是输入管的基极电流 , 在 ...

  9. 平面包装设计怎么制作_从平面文件中获取数据时如何避免包装设计缺陷

    平面包装设计怎么制作 As developers of SQL Server Integrations Services (SSIS) solutions, we have more than lik ...

最新文章

  1. R语言Logistic回归模型案例:低出生婴儿体重的影响因素分析(列线图、校准曲线)
  2. [Google Guava] 12-数学运算
  3. 通过Idea创建spring项目,没有spring Initializr选项的解决方法
  4. 系统业务逻辑书籍_咨询行业书籍推荐
  5. GMGDC专訪戴亦斌:具体解释QAMAster全面測试服务6大功能
  6. MFC添加自定义消息及重写消息过程
  7. 基于C#.NET的高端智能化网络爬虫
  8. 以下选项中python用于异常处理结构_《Python 程序设计》复习题
  9. @value获取不到值
  10. 即使是菜鸟,也能配置出一个网站
  11. go 公众号 关注 监听_golang微信公众平台之消息接入
  12. 阶段1 语言基础+高级_1-3-Java语言高级_08-JDK8新特性_第1节 常用函数接口_5_函数式接口作为方法的参数案例...
  13. 图灵机器人Web API
  14. 深击 | 阿里云故障“惊魂”1小时:难道我们是那0.1%?
  15. HDU - Shaolin(STL)
  16. Selenium面试问题及答案30题版
  17. 1009 - Back to Underworld(DFS)
  18. php微信公众点歌台,PHP实现微信公众平台音乐点播功能
  19. c语言如何小写转换为大写字母,c语言怎么将小写转换为大写
  20. ArduPilot飞行前检查——PreArm解析

热门文章

  1. golang三类加密算法
  2. Excel正课阶段Day1
  3. 字节跳动-2020秋招-笔试题剖析【5道算法题】
  4. Windows解决网速问题
  5. 打印机无法打印每次重启后才能访问打印文件
  6. 目标检测学习笔记——yolov5的坐标输出形式和损失函数计算
  7. Egg整合antd文件上传以及防踩坑指南
  8. Android Java开发中一些唬人的常用关键字用法,持续更新中。。。
  9. JS基本数据类型和Object
  10. 第1章 初识Photoshop