Web Application Basics
Web Application BasicsURLScheme:often httpsUser(rare)Host/Domain:website addresstyposquatting:mimic a website to trick people into giving up sensitive info.Port:usually 80-http,443-httpsPath:file pathQuery String:have ?—Modify-ableFragment—Modify-ableHTTP Request:start line(methods/url path/http version)request headers(host,user-agent,- - - web browserreferer,- - -such as www.google.com,the web where the request comefromcookies,content-type,content-length…)Request Body- - 4kinds:Url encoded(application/x-www-form-urlencoded) ;keyvalueform-data表格数据(multipart/form-data) ;boundary----WebKitFormBoundary7MA4YWxkTrZu0gW- - - 之后为生成的分割头部)json(application/json); { “username”“” }xml(application/xml) ;just like htmlHTTP ResponseThe first linein every HTTP response is called the Status Line. It gives you three key pieces of info:HTTP Version: This tells you which version of HTTP is being used.Status Code: A three-digit number showing the outcome of your request.Reason Phrase: A short message explaining the status code in human-readable terms.Since we already covered HTTP Versions in Task 5, let’s focus on the Status Codes and Reason Phrases here.Status Codes and Reason PhrasesThe Status Code is the number that tells you if the request succeeded or failed, while the Reason Phrase explains what happened. These codes fall into five main categories:Informational Responses (100-199)These codes mean the server has received part of the request and is waiting for the rest. It’s a “keep going” signal.Successful Responses (200-299)These codes mean everything worked as expected. The server processed the request and sent back the requested data.Redirection Messages (300-399)These codes tell you that the resource you requested has moved to a different location, usually providing the new URL.Client Error Responses (400-499)These codes indicate a problem with the request. Maybe the URL is wrong, or you’re missing some required info, like authentication.Server Error Responses (500-599)These codes mean the server encountered an error while trying to fulfil the request. These are usually server-side issues and not the client’s fault.Common Status CodesHere are some of the most frequently seen status codes:100 (Continue)The server got the first part of the request and is ready for the rest.200 (OK)The request was successful, and the server is sending back the requested resource.301 (Moved Permanently)The resource you’re requesting has been permanently moved to a new URL. Use the new URL from now on.404 (Not Found)The server couldn’t find the resource at the given URL. Double-check that you’ve got the right address.500 (Internal Server Error)Something went wrong on the server’s end, and it couldn’t process your request.Response Headerjust headersSecurity Headers1.CSPContent-Security-Policy: default-src ‘self’; script-src ‘self’ https://cdn.tryhackme.com; style-src ‘self’2.HSTSStrict-Transport-Security: max-age63072000; includeSubDomains; preload3.X-Content-Type-OptionsX-Content-Type-Options: nosniff4.Referrer-PolicyThis header controls the amount of information sent to the destination web server when a user is redirected from the source web server, such as when they click a hyperlink. The header is available to allow a web administrator to control what information is shared. Here are some examples of Referrer-Policy:Referrer-Policy: no-referrerReferrer-Policy: same-originReferrer-Policy: strict-originReferrer-Policy: strict-origin-when-cross-originHere’s a breakdown of the Referrer-Policy header by directives:no-referrerThis completely disables any information being sent about the referrersame-originThis policy will only send referrer information when the destination is part of the same origin. This is helpful when you want referrer information passed when hyperlinks are within the same website but not outside to external websites.strict-originThis policy only sends the referrer as the origin when the protocol stays the same. So, a referrer is sent when an HTTPS connection goes to another HTTPS connection.strict-origin-when-cross-originThis is similar to strict-origin except for same-origin requests, where it sends the full URL path in the origin header.THANKS FOR VIEWING!

相关新闻

文件读写全套易错笔记

文件读写全套易错笔记

一、语法类错误(错误代码修正代码) 错误1:fopen不做空指针判断 错误代码 FILE* fp fopen("test.txt","r"); fputc(a,fp); // 打开失败fpNULL,直接崩溃问题:文件打开失败不会捕获,后续…

2026/7/19 15:27:07阅读更多 →
vla学习笔记(2) lerobot配置gazebo

vla学习笔记(2) lerobot配置gazebo

一、写gazebo.launch.py 直接复制下列文件,并且修改对应的文件名称import os from launch import LaunchDescription from launch.actions import ExecuteProcess, RegisterEventHandler, TimerAction from launch_ros.actions import Node from launch_ros.substit…

2026/7/19 15:27:07阅读更多 →
如何用BepInEx为游戏注入新生命:插件框架终极指南

如何用BepInEx为游戏注入新生命:插件框架终极指南

如何用BepInEx为游戏注入新生命:插件框架终极指南 【免费下载链接】BepInEx Unity / XNA game patcher and plugin framework 项目地址: https://gitcode.com/GitHub_Trending/be/BepInEx 想不想让你最喜欢的游戏变得更有趣?想不想为Unity游戏添加…

2026/7/19 15:25:07阅读更多 →
终于搞懂 Kueue:5 个核心对象一次讲透

终于搞懂 Kueue:5 个核心对象一次讲透

很多人刚接触 Kueue 时最大的困惑,不是 YAML 怎么写,而是看着一堆 CRD:ResourceFlavor、ClusterQueue、LocalQueue、Cohort、Workload,不知道它们之间到底是什么关系。本文不会逐个照着 API 文档介绍字段,而是把这五个…

2026/7/19 23:47:01阅读更多 →
ThinkingCap-Qwen3.6-27B-mlx-6Bit模型深度解析:6位量化如何实现高效AI推理

ThinkingCap-Qwen3.6-27B-mlx-6Bit模型深度解析:6位量化如何实现高效AI推理

ThinkingCap-Qwen3.6-27B-mlx-6Bit模型深度解析:6位量化如何实现高效AI推理 【免费下载链接】ThinkingCap-Qwen3.6-27B-mlx-6Bit 项目地址: https://ai.gitcode.com/hf_mirrors/mlx-community/ThinkingCap-Qwen3.6-27B-mlx-6Bit ThinkingCap-Qwen3.6-27B-ml…

2026/7/19 23:47:01阅读更多 →
ExusData:机器人触觉感知数据集完全指南

ExusData:机器人触觉感知数据集完全指南

ExusData:机器人触觉感知数据集完全指南 【免费下载链接】ExusData 项目地址: https://ai.gitcode.com/psibot-ai/ExusData ExusData是psibot-ai项目下的机器人触觉感知数据集,专为机器人触觉相关研究和开发提供高质量数据支持。它包含了丰富的触…

2026/7/19 23:47:01阅读更多 →
衡量AI时代真实价值:OpenAI “每美元有效智能“ 评分框架深度解读

衡量AI时代真实价值:OpenAI “每美元有效智能“ 评分框架深度解读

衡量AI时代真实价值:OpenAI "每美元有效智能" 评分框架深度解读 原文:A scorecard for the AI age | OpenAI,作者 Sarah Friar,2026年7月17日笔记整理日期:2026年7月 核心观点 OpenAI CFO Sarah Friar 提出…

2026/7/19 23:47:01阅读更多 →
如何快速部署Inkling-mlx-2bit:Apple Mac分布式推理实战教程

如何快速部署Inkling-mlx-2bit:Apple Mac分布式推理实战教程

如何快速部署Inkling-mlx-2bit:Apple Mac分布式推理实战教程 【免费下载链接】Inkling-mlx-2bit 项目地址: https://ai.gitcode.com/hf_mirrors/mlx-community/Inkling-mlx-2bit Inkling-mlx-2bit是一款基于MLX框架的2比特量化模型,专为Apple Ma…

2026/7/19 23:47:01阅读更多 →
Unlock-Music:浏览器内一键解锁加密音乐文件的终极解决方案

Unlock-Music:浏览器内一键解锁加密音乐文件的终极解决方案

Unlock-Music:浏览器内一键解锁加密音乐文件的终极解决方案 【免费下载链接】unlock-music 在浏览器中解锁加密的音乐文件。原仓库: 1. https://github.com/unlock-music/unlock-music ;2. https://git.unlock-music.dev/um/web 项目地址: …

2026/7/19 23:45:00阅读更多 →
Go语言静态资源打包方案对比与实践指南

Go语言静态资源打包方案对比与实践指南

1. 项目背景与核心需求在Go语言开发中,我们经常需要处理静态资源文件的打包问题。无论是Web应用的模板文件、前端资源,还是配置文件、证书等,都需要随程序一起分发。传统做法是将这些文件与编译后的二进制文件放在同一目录下,但这…

2026/7/19 0:01:04阅读更多 →
Go语言实现高性能LDAP认证服务的架构与实践

Go语言实现高性能LDAP认证服务的架构与实践

1. 项目背景与核心价值LDAP(轻量级目录访问协议)作为企业级身份认证的黄金标准,已经服务了超过80%的财富500强公司。我在金融科技领域实施统一认证体系时,发现传统Java方案存在启动慢、内存占用高等痛点。而Go语言凭借其协程并发模…

2026/7/19 0:01:04阅读更多 →
【AI面试官实战指南】:用ChatGPT模拟10类高频技术岗面试,3天提升应答精准度92%

【AI面试官实战指南】:用ChatGPT模拟10类高频技术岗面试,3天提升应答精准度92%

更多请点击: https://intelliparadigm.com 第一章:AI面试官实战指南的核心价值与适用场景 AI面试官并非替代人类HR的“黑箱工具”,而是以可解释、可审计、可迭代的方式,赋能招聘全链路的关键基础设施。其核心价值在于将主观经验沉…

2026/7/19 0:01:04阅读更多 →
Go语言静态资源打包方案对比与实践指南

Go语言静态资源打包方案对比与实践指南

1. 项目背景与核心需求在Go语言开发中,我们经常需要处理静态资源文件的打包问题。无论是Web应用的模板文件、前端资源,还是配置文件、证书等,都需要随程序一起分发。传统做法是将这些文件与编译后的二进制文件放在同一目录下,但这…

2026/7/19 0:01:04阅读更多 →
Go语言实现高性能LDAP认证服务的架构与实践

Go语言实现高性能LDAP认证服务的架构与实践

1. 项目背景与核心价值LDAP(轻量级目录访问协议)作为企业级身份认证的黄金标准,已经服务了超过80%的财富500强公司。我在金融科技领域实施统一认证体系时,发现传统Java方案存在启动慢、内存占用高等痛点。而Go语言凭借其协程并发模…

2026/7/19 0:01:04阅读更多 →
【AI面试官实战指南】:用ChatGPT模拟10类高频技术岗面试,3天提升应答精准度92%

【AI面试官实战指南】:用ChatGPT模拟10类高频技术岗面试,3天提升应答精准度92%

更多请点击: https://intelliparadigm.com 第一章:AI面试官实战指南的核心价值与适用场景 AI面试官并非替代人类HR的“黑箱工具”,而是以可解释、可审计、可迭代的方式,赋能招聘全链路的关键基础设施。其核心价值在于将主观经验沉…

2026/7/19 0:01:04阅读更多 →
YOLOv8推理性能优化:从1.2FPS到35FPS的全链路加速实践

YOLOv8推理性能优化:从1.2FPS到35FPS的全链路加速实践

如果你在部署 YOLOv8 时,发现推理速度只有可怜的 1-2 FPS,而别人的演示视频却能跑到 30 FPS 以上,那么问题很可能不在模型本身,而在于你的整个处理链路。很多开发者拿到一个训练好的 YOLOv8 模型后,会直接使用官方示例…

2026/7/19 22:50:49阅读更多 →
Coze与Dify对比指南:低代码AI应用开发从入门到实战

Coze与Dify对比指南:低代码AI应用开发从入门到实战

1. 从零到一:为什么你需要了解 Coze 和 Dify?如果你对 AI 应用开发感兴趣,但一看到“大模型”、“智能体”、“工作流”这些词就头疼,觉得门槛太高,那这篇文章就是为你准备的。很多开发者,包括我自己&#…

2026/7/19 14:50:26阅读更多 →
AI生图工具怎么选?2026年6月版实测对比

AI生图工具怎么选?2026年6月版实测对比

做自媒体的朋友应该都有体会:配图一直是个让人头疼的问题。2026年,AI生图工具已经非常成熟了,但工具太多反而不知道怎么选。以下是截至2026年6月我对主流AI生图工具的实测对比。Midjourney V8.1:速度之王2026年6月11日&#xff0c…

2026/7/19 18:50:36阅读更多 →