Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
  • Loading branch information
stardustman committed Oct 6, 2024
1 parent b8e3184 commit 3873284
Show file tree
Hide file tree
Showing 26 changed files with 122 additions and 55 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
<!doctype html><html lang=en><head><meta charset=utf-8><meta http-equiv=x-ua-compatible content="IE=edge,chrome=1"><title>What-happens-type-url-into-browser-and-press-enter - stardustman</title><meta name=renderer content="webkit"><meta name=viewport content="width=device-width,initial-scale=1,maximum-scale=1"><meta http-equiv=cache-control content="no-transform"><meta http-equiv=cache-control content="no-siteapp"><meta name=theme-color content="#f8f5ec"><meta name=msapplication-navbutton-color content="#f8f5ec"><meta name=apple-mobile-web-app-capable content="yes"><meta name=apple-mobile-web-app-status-bar-style content="#f8f5ec"><meta name=author content="stardust"><meta name=description content="dns query get the ip of the target domain browser cache firefox(about:networking#dns) /etc/hosts os cache macos 查看 dns 请求日志 sudo log stream &amp;ndash;predicate &amp;lsquo;process == &amp;ldquo;mDNSResponder&amp;rdquo;&amp;rsquo; &amp;ndash;info dns resolver /etc/resolv.conf arp -a 查看有没有 dns 服务器的 mac 地址 ARP request for the nameserver send dns query to get the ip of the domain arp 获取 gateway 的 mac"><meta name=keywords content="Hugo,theme,even"><meta name=generator content="Hugo 0.119.0 with theme even"><link rel=canonical href=http://stardustman.github.io/2021/09/11/what-happens-type-url-into-browser-and-press-enter/><link rel=apple-touch-icon sizes=180x180 href=/apple-touch-icon.png><link rel=icon type=image/png sizes=32x32 href=/favicon-32x32.png><link rel=icon type=image/png sizes=16x16 href=/favicon-16x16.png><link rel=manifest href=/manifest.json><link rel=mask-icon href=/safari-pinned-tab.svg color=#5bbad5><link href=/sass/main.min.f92fd13721ddf72129410fd8250e73152cc6f2438082b6c0208dc24ee7c13fc4.css rel=stylesheet><link rel=stylesheet href=https://cdn.jsdelivr.net/npm/@fancyapps/[email protected]/dist/jquery.fancybox.min.css integrity="sha256-7TyXnr2YU040zfSP+rEcz29ggW4j56/ujTPwjMzyqFY=" crossorigin=anonymous><meta property="og:title" content="What-happens-type-url-into-browser-and-press-enter"><meta property="og:description" content="dns query get the ip of the target domain browser cache firefox(about:networking#dns) /etc/hosts os cache macos 查看 dns 请求日志 sudo log stream &ndash;predicate &lsquo;process == &ldquo;mDNSResponder&rdquo;&rsquo; &ndash;info dns resolver /etc/resolv.conf arp -a 查看有没有 dns 服务器的 mac 地址 ARP request for the nameserver send dns query to get the ip of the domain arp 获取 gateway 的 mac"><meta property="og:type" content="article"><meta property="og:url" content="http://stardustman.github.io/2021/09/11/what-happens-type-url-into-browser-and-press-enter/"><meta property="article:section" content="post"><meta property="article:published_time" content="2021-09-11T16:21:12+08:00"><meta property="article:modified_time" content="2021-09-11T16:21:12+08:00"><meta itemprop=name content="What-happens-type-url-into-browser-and-press-enter"><meta itemprop=description content="dns query get the ip of the target domain browser cache firefox(about:networking#dns) /etc/hosts os cache macos 查看 dns 请求日志 sudo log stream &ndash;predicate &lsquo;process == &ldquo;mDNSResponder&rdquo;&rsquo; &ndash;info dns resolver /etc/resolv.conf arp -a 查看有没有 dns 服务器的 mac 地址 ARP request for the nameserver send dns query to get the ip of the domain arp 获取 gateway 的 mac"><meta itemprop=datePublished content="2021-09-11T16:21:12+08:00"><meta itemprop=dateModified content="2021-09-11T16:21:12+08:00"><meta itemprop=wordCount content="98"><meta itemprop=keywords content="network,interrput,dns,"><meta name=twitter:card content="summary"><meta name=twitter:title content="What-happens-type-url-into-browser-and-press-enter"><meta name=twitter:description content="dns query get the ip of the target domain browser cache firefox(about:networking#dns) /etc/hosts os cache macos 查看 dns 请求日志 sudo log stream &ndash;predicate &lsquo;process == &ldquo;mDNSResponder&rdquo;&rsquo; &ndash;info dns resolver /etc/resolv.conf arp -a 查看有没有 dns 服务器的 mac 地址 ARP request for the nameserver send dns query to get the ip of the domain arp 获取 gateway 的 mac"><!--[if lte IE 9]><script src=https://cdnjs.cloudflare.com/ajax/libs/classlist/1.1.20170427/classList.min.js></script><![endif]--><!--[if lt IE 9]><script src=https://cdn.jsdelivr.net/npm/[email protected]/dist/html5shiv.min.js></script>
<script src=https://cdn.jsdelivr.net/npm/[email protected]/dest/respond.min.js></script><![endif]--></head><body><div id=mobile-navbar class=mobile-navbar><div class=mobile-header-logo><a href=/ class=logo>keep writing</a></div><div class=mobile-navbar-icon><span></span>
<span></span>
<span></span></div></div><nav id=mobile-menu class="mobile-menu slideout-menu"><ul class=mobile-menu-list><a href=/><li class=mobile-menu-item>Home</li></a><a href=/post/><li class=mobile-menu-item>Archives</li></a><a href=/tags/><li class=mobile-menu-item>Tags</li></a><a href=/categories/><li class=mobile-menu-item>Categories</li></a><a href=/2022/03/27/about/><li class=mobile-menu-item>About</li></a></ul></nav><div class=container id=mobile-panel><header id=header class=header><div class=logo-wrapper><a href=/ class=logo>keep writing</a></div><nav class=site-navbar><ul id=menu class=menu><li class=menu-item><a class=menu-item-link href=/>Home</a></li><li class=menu-item><a class=menu-item-link href=/post/>Archives</a></li><li class=menu-item><a class=menu-item-link href=/tags/>Tags</a></li><li class=menu-item><a class=menu-item-link href=/categories/>Categories</a></li><li class=menu-item><a class=menu-item-link href=/2022/03/27/about/>About</a></li></ul></nav></header><main id=main class=main><div class=content-wrapper><div id=content class=content><article class=post><header class=post-header><h1 class=post-title>What-happens-type-url-into-browser-and-press-enter</h1><div class=post-meta><span class=post-time>2021-09-11</span>
<span class=more-meta>98 words</span>
<span class=more-meta>1 min read</span></div></header><div class=post-toc id=post-toc><h2 class=post-toc-title>Contents</h2><div class="post-toc-content always-active"><nav id=TableOfContents><ul><li><ul><li><a href=#dns-query>dns query</a><ul><li><a href=#browser-cache>browser cache</a></li><li><a href=#etchosts>/etc/hosts</a></li><li><a href=#os-cache>os cache</a></li><li><a href=#dns-resolver>dns resolver</a></li></ul></li><li><a href=#arp-获取-gateway-的-mac-地址>arp 获取 gateway 的 mac 地址</a></li><li><a href=#references>References</a></li></ul></li></ul></nav></div></div><div class=post-content><h2 id=dns-query>dns query</h2><p>get the ip of the target domain</p><h3 id=browser-cache>browser cache</h3><p>firefox(about:networking#dns)</p><h3 id=etchosts>/etc/hosts</h3><h3 id=os-cache>os cache</h3><ol><li>macos 查看 dns 请求日志 sudo log stream &ndash;predicate &lsquo;process == &ldquo;mDNSResponder&rdquo;&rsquo; &ndash;info</li></ol><h3 id=dns-resolver>dns resolver</h3><p>/etc/resolv.conf</p><ol><li>arp -a 查看有没有 dns 服务器的 mac 地址</li><li>ARP request for the nameserver</li><li>send dns query to get the ip of the domain</li></ol><h2 id=arp-获取-gateway-的-mac-地址>arp 获取 gateway 的 mac 地址</h2><h2 id=references>References</h2><ol><li><a href=http://www.science.smith.edu/~nhowe/262/oldlabs/keyboard.html>keyborad-interrput</a></li><li><a href=https://www.zhihu.com/question/560616439/answer/2722866208>Chrome 是怎么判断地址栏输入的东西是不是网址? -omnibox</a></li><li><a href=about:networking#dns>firefox dns</a></li><li><a href=https://www.fortinet.com/resources/cyberglossary/what-is-arp>ARP</a></li></ol></div><div class=post-copyright><p class=copyright-item><span class=item-title>Author</span>
<span class=item-content>stardust</span></p><p class=copyright-item><span class=item-title>LastMod</span>
<span class=item-content>2021-09-11</span></p><p class=copyright-item><span class=item-title>Markdown</span>
<span class=item-content><a class=link-to-markdown href=http://stardustman.github.io/2021/09/11/what-happens-type-url-into-browser-and-press-enter/index.md target=_blank>The Markdown version »</a></span></p></div><footer class=post-footer><div class=post-tags><a href=/tags/network/>network</a>
<a href=/tags/interrput/>interrput</a>
<a href=/tags/dns/>dns</a></div><nav class=post-nav><a class=prev href=/2021/11/28/k8s-deploy-container-using-yaml/><i class="iconfont icon-left"></i>
<span class="prev-text nav-default">k8s-deploy-container-using-yaml</span>
<span class="prev-text nav-mobile">Prev</span></a>
<a class=next href=/2021/09/11/what-happens-when-you-type-google.com-into-your-browser-and-press-enter/><span class="next-text nav-default">What-happens-when-you-type-google.com-into-your-browser-and-press-enter</span>
<span class="next-text nav-mobile">Next</span>
<i class="iconfont icon-right"></i></a></nav></footer></article></div><script src=https://utteranc.es/client.js repo=stardustman/comments issue-term=pathname theme=github-light crossorigin=anonymous async></script><noscript>Please enable JavaScript to view the <a href=https://github.com/utterance>comments powered by utterances.</a></noscript></div></main><footer id=footer class=footer><div class=social-links><a href=mailto:[email protected] class="iconfont icon-email" title=email></a>
<a href=https://stackoverflow.com/users/9112817/cloud-young class="iconfont icon-stack-overflow" title=stack-overflow></a>
<a href=https://github.com/stardustman class="iconfont icon-github" title=github></a>
<a href=http://stardustman.github.io/index.xml type=application/rss+xml class="iconfont icon-rss" title=rss></a></div><div class=copyright><span class=power-by>Powered by <a class=hexo-link href=https://gohugo.io>Hugo</a></span>
<span class=division>|</span>
<span class=theme-info>Theme -
<a class=theme-link href=https://github.com/olOwOlo/hugo-theme-even>Even</a></span>
<span class=copyright-year>&copy;
2019 -
2024<span class=heart><i class="iconfont icon-heart"></i></span><span>stardust</span></span></div></footer><div class=back-to-top id=back-to-top><i class="iconfont icon-up"></i></div></div><script src="/lib/highlight/highlight.pack.js?v=20171001"></script>
<script src=https://cdn.jsdelivr.net/npm/[email protected]/dist/jquery.min.js integrity="sha256-hwg4gsxgFZhOsEEamdOYGBf13FyQuiTwlAQgxVSNgt4=" crossorigin=anonymous></script>
<script src=https://cdn.jsdelivr.net/npm/[email protected]/dist/slideout.min.js integrity="sha256-t+zJ/g8/KXIJMjSVQdnibt4dlaDxc9zXr/9oNPeWqdg=" crossorigin=anonymous></script>
<script src=https://cdn.jsdelivr.net/npm/@fancyapps/[email protected]/dist/jquery.fancybox.min.js integrity="sha256-XVLffZaxoWfGUEbdzuLi7pwaUJv1cecsQJQqGLe7axY=" crossorigin=anonymous></script>
<script type=text/javascript src=/js/main.min.4ae89da218555efa0e7093a20b92017d2e1202b66fff9fc2edf4cb8d44b44c6e.js></script></body></html>
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@

## dns query

get the ip of the target domain

### browser cache

firefox(about:networking#dns)

### /etc/hosts

### os cache

1. macos 查看 dns 请求日志 sudo log stream --predicate 'process == "mDNSResponder"' --info


### dns resolver

/etc/resolv.conf

1. arp -a 查看有没有 dns 服务器的 mac 地址
2. ARP request for the nameserver
3. send dns query to get the ip of the domain

## arp 获取 gateway 的 mac 地址

## References

1. [keyborad-interrput](http://www.science.smith.edu/~nhowe/262/oldlabs/keyboard.html)
2. [Chrome 是怎么判断地址栏输入的东西是不是网址? -omnibox](https://www.zhihu.com/question/560616439/answer/2722866208)
3. [firefox dns](about:networking#dns)
4. [ARP](https://www.fortinet.com/resources/cyberglossary/what-is-arp)
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,8 @@
<span class=item-content>2021-09-11</span></p><p class=copyright-item><span class=item-title>Markdown</span>
<span class=item-content><a class=link-to-markdown href=http://stardustman.github.io/2021/09/11/what-happens-when-you-type-google.com-into-your-browser-and-press-enter/index.md target=_blank>The Markdown version »</a></span></p></div><footer class=post-footer><div class=post-tags><a href=/tags/network/>network</a>
<a href=/tags/interrput/>interrput</a>
<a href=/tags/dns/>dns</a></div><nav class=post-nav><a class=prev href=/2021/11/28/k8s-deploy-container-using-yaml/><i class="iconfont icon-left"></i>
<span class="prev-text nav-default">k8s-deploy-container-using-yaml</span>
<a href=/tags/dns/>dns</a></div><nav class=post-nav><a class=prev href=/2021/09/11/what-happens-type-url-into-browser-and-press-enter/><i class="iconfont icon-left"></i>
<span class="prev-text nav-default">What-happens-type-url-into-browser-and-press-enter</span>
<span class="prev-text nav-mobile">Prev</span></a>
<a class=next href=/2021/07/18/asm-java-jit/><span class="next-text nav-default">asm-java-jit</span>
<span class="next-text nav-mobile">Next</span>
Expand Down
2 changes: 1 addition & 1 deletion 2021/11/28/k8s-deploy-container-using-yaml/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@
<a href=/tags/deploy/>deploy</a></div><nav class=post-nav><a class=prev href=/2021/12/05/js-eventloop/><i class="iconfont icon-left"></i>
<span class="prev-text nav-default">js-eventloop</span>
<span class="prev-text nav-mobile">Prev</span></a>
<a class=next href=/2021/09/11/what-happens-when-you-type-google.com-into-your-browser-and-press-enter/><span class="next-text nav-default">What-happens-when-you-type-google.com-into-your-browser-and-press-enter</span>
<a class=next href=/2021/09/11/what-happens-type-url-into-browser-and-press-enter/><span class="next-text nav-default">What-happens-type-url-into-browser-and-press-enter</span>
<span class="next-text nav-mobile">Next</span>
<i class="iconfont icon-right"></i></a></nav></footer></article></div><script src=https://utteranc.es/client.js repo=stardustman/comments issue-term=pathname theme=github-light crossorigin=anonymous async></script><noscript>Please enable JavaScript to view the <a href=https://github.com/utterance>comments powered by utterances.</a></noscript></div></main><footer id=footer class=footer><div class=social-links><a href=mailto:[email protected] class="iconfont icon-email" title=email></a>
<a href=https://stackoverflow.com/users/9112817/cloud-young class="iconfont icon-stack-overflow" title=stack-overflow></a>
Expand Down
2 changes: 1 addition & 1 deletion index.xml

Large diffs are not rendered by default.

Loading

0 comments on commit 3873284

Please sign in to comment.