HTB 学习笔记 【中/英】《Web 应用 - 布局》P2


📌 这篇文章讲了什么?

  • 介绍了 Web 应用的架构和布局,包括不同的基础设施、组件、架构模式等。
  • 讲解了 常见的 Web 应用部署方式(单服务器、多服务器等),并分析了它们的安全性。
  • 介绍了 微服务架构(Microservices)无服务器架构(Serverless) 的概念及其优势。
  • 强调了 架构安全性 在 Web 渗透测试中的重要性,并举例说明常见的架构设计缺陷。

💡 需要记住的重点

1. Web 应用的三大主要部分
类别描述
Web 应用基础设施服务器、数据库、应用所需的核心组件
Web 应用组件前端(UI/UX)、客户端(浏览器)、服务器端(逻辑处理)
Web 应用架构不同组件之间的关系,如前端与后端的交互方式

2. 常见的 Web 应用架构
架构特点优缺点
客户端-服务器架构服务器处理请求,客户端(浏览器)交互常见架构,易部署
单服务器架构所有应用组件(包括数据库)都托管在一个服务器上简单但风险极高,一旦被攻击,全部数据都可能泄露
多服务器 - 单数据库多个 Web 服务器共享同一个数据库提高性能和冗余度,但数据库仍是单点故障
多服务器 - 多数据库每个应用有自己的独立数据库,或者使用多个数据库共享数据安全性和容错能力强,但管理复杂

📌 记住:单服务器架构风险最大,多服务器多数据库架构最安全但成本最高。


3. Web 应用的核心组件
  • 客户端 (Client):用户访问 Web 应用的方式(如浏览器)。
  • 服务器 (Server):负责处理请求并返回响应。
  • Web 服务器 (Web Server):例如 Apache、Nginx,负责处理 HTTP 请求。
  • Web 应用逻辑 (Application Logic):应用的核心功能,如登录、数据处理等。
  • 数据库 (Database):存储用户和应用数据。
  • 第三方集成 (3rd Party Integrations):如支付接口、API 等。
  • 微服务 (Microservices):独立的模块化组件,如支付、搜索、用户管理等。
  • 无服务器架构 (Serverless):如 AWS Lambda、GCP Functions,省去服务器管理,直接运行代码。

4. 微服务架构(Microservices)
  • 概念:将 Web 应用拆分为多个独立的微服务,每个微服务完成特定任务(如注册、支付、搜索等)。
  • 特点
    • 无状态通信(每次请求都是独立的)。
    • 不同微服务可以用不同语言开发
    • 扩展性强,开发速度快
  • 优点
    • 更灵活的部署和扩展
    • 易于维护和更新
    • 更快的产品迭代

5. 无服务器架构(Serverless)
  • 概念:无需管理服务器,代码在云端(如 AWS、Azure、GCP)自动执行。
  • 优点
    • 无需服务器维护,降低运营成本。
    • 自动扩展,根据需求动态分配资源。
    • 快速部署,适用于轻量级应用。

📌 记住:微服务架构适用于大型 Web 应用,无服务器架构适用于云端轻量级应用。


6. Web 应用架构安全性
  • 安全架构是渗透测试的重要部分,一个不安全的架构可能会导致严重的数据泄露风险。
  • 常见的架构安全漏洞
    • 访问控制错误 (RBAC, Role-Based Access Control)
      • 例如,普通用户可以访问管理员功能。
    • 数据库暴露
      • 服务器被攻破后,如果数据库和应用在同一台服务器上,攻击者可能获取所有数据。
    • 微服务安全
      • 微服务之间的通信需要认证,否则可能被滥用。

📌 记住:架构漏洞可能比代码漏洞更难修复,必须从设计阶段就考虑安全性。


🚫 不需要花太多时间看的部分

不同架构的详细技术实现(只需要理解它们的安全性差异)。
复杂的微服务和无服务器架构设计(了解概念即可,具体实现可以以后学习)。
Web 服务器的具体配置(Apache、Nginx 等)(如果不是安全方向,暂时不需要深入研究)。


✅ 接下来的行动建议

理解不同 Web 应用架构的安全性差异(特别是单服务器 vs. 多服务器架构)。
学习微服务架构和无服务器架构的安全性挑战
开始研究 Web 渗透测试,重点关注架构安全漏洞
掌握 Web 安全基础,逐步学习 OWASP Top 10 和实际漏洞利用

Web 安全不仅仅是代码漏洞,还涉及 架构设计、数据库防护、访问控制 等。掌握 Web 应用架构安全,将让你在网络安全领域更具竞争力!

Summary and Notes on "Web Application Layout"


📌 What Is This About?

  • Introduces web application architecture and layout, covering different infrastructure models, components, and architectures.
  • Explains common web application deployment methods (single server, multiple servers, etc.) and their security implications.
  • Discusses Microservices and Serverless architectures, highlighting their advantages.
  • Emphasizes architecture security in penetration testing and provides examples of common design flaws.

💡 Key Points to Memorize

1. Three Main Aspects of Web Application Architecture
CategoryDescription
Web Application InfrastructureDefines the structure of required components such as databases and servers.
Web Application ComponentsIncludes front-end (UI/UX), client-side processing, and server-side logic.
Web Application ArchitectureDescribes how different components interact and form the overall structure.

2. Common Web Application Architecture Models
ArchitectureCharacteristicsPros & Cons
Client-ServerServer hosts the app, clients access via browsers.Standard model, easy to implement.
Single ServerEntire app and database hosted on one server.Simple but highly insecure—if compromised, everything is exposed.
Multiple Servers - Single DatabaseMultiple web servers share a single database.Improves redundancy but still has a database as a single point of failure.
Multiple Servers - Multiple DatabasesEach web application has its own database, or multiple databases are used.High security and fault tolerance but complex management.

📌 Key Takeaway: Single-server models are the riskiest, while multi-server multi-database models offer better security at a higher cost.


3. Core Web Application Components
  • Client (Browser): The interface users interact with.
  • Server: Processes requests and returns responses.
  • Web Server: Software handling HTTP requests (e.g., Apache, Nginx).
  • Application Logic: Handles the core functionality (authentication, data processing, etc.).
  • Database: Stores application and user data.
  • Third-Party Integrations: External services like payment processors or APIs.
  • Microservices: Independent modules for tasks like authentication, payments, and search.
  • Serverless Functions: Code executed in the cloud without managing servers (e.g., AWS Lambda, GCP Functions).

4. Microservices Architecture
  • Concept: Decomposes a web application into independent services, each performing a specific function.
  • Example: An online store with separate services for registration, payments, search, and reviews.
  • Characteristics:
    • Stateless communication (each request is independent).
    • Services can be built using different programming languages.
    • Highly scalable and modular.
  • Benefits:
    • Faster development and deployment.
    • More flexible and scalable than monolithic applications.
    • Encourages innovation and faster delivery of new features.

5. Serverless Architecture
  • Concept: Applications run in the cloud without managing servers manually.
  • Benefits:
    • No server maintenance—fully managed by cloud providers (AWS, Azure, GCP).
    • Automatic scaling based on demand.
    • Lower operational costs for lightweight applications.

📌 Key Takeaway: Microservices are ideal for complex applications, while serverless architecture suits lightweight, cloud-based applications.


6. Web Application Architecture Security
  • Architecture security is critical in penetration testing, as design flaws can lead to major security risks.
  • Common Architecture Security Issues:
    • Access Control Flaws (RBAC, Role-Based Access Control)
      • Example: Regular users accessing admin functionalities.
    • Database Exposure
      • If a server is compromised, a poorly segmented architecture may expose the entire database.
    • Microservices Security
      • Each service should require authentication to prevent unauthorized access.

📌 Key Takeaway: Architecture-level vulnerabilities are harder to fix than coding errors, so security should be considered from the design phase.


🚫 What You Don’t Need to Focus On Too Much

Detailed implementation of different architectures (just understand security implications).
In-depth configurations of web servers (Apache, Nginx, etc.) (not essential for penetration testing at this stage).
Technical specifics of microservices and serverless models (focus on the concepts and security aspects).


✅ Next Steps & Action Plan

Understand the security differences between different web application architectures.
Learn the challenges of Microservices and Serverless security.
Begin studying Web Penetration Testing, focusing on architecture vulnerabilities.
Master Web Security Basics and gradually dive into OWASP Top 10 and real-world exploitations.

Web security is not just about code vulnerabilities—it also involves architecture design, database security, and access control. Mastering web application architecture security will set you apart in cybersecurity! 🚀

本文来自互联网用户投稿,该文观点仅代表作者本人,不代表本站立场。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如若转载,请注明出处:http://www.rhkb.cn/news/35310.html

如若内容造成侵权/违法违规/事实不符,请联系长河编程网进行投诉反馈email:809451989@qq.com,一经查实,立即删除!

相关文章

蓝牙系统的核心组成解析

一、硬件层:看得见的物理载体 1. 射频模块(Radio Frequency Module) 专业描述:工作在2.4GHz ISM频段,支持GFSK/π/4 DQPSK/8DPSK调制方式 功能类比:相当于人的"嘴巴"和"耳朵" 发射端…

LeRobot源码剖析——对机器人各个动作策略的统一封装:包含ALOHA ACT、Diffusion Policy、VLA模型π0

前言 过去2年多的深入超过此前7年,全靠夜以继日的勤奋,一天当两天用,抠论文 抠代码 和大模型及具身同事讨论,是目前日常 而具身库里,idp3、π0、lerobot值得反复研究,故,近期我一直在抠π0及l…

ISP--Gamma Correction

文章目录 现象Gamma产生的原因CRT属性导致人眼的亮度特性 gamma校正LUT法线性插值法模拟gamma法 现象 从上往下看左侧黑色块黑得越来越严重,对比度也在逐渐加深。此时灰阶的高亮区获得的数据位变少,暗区获得的数据位变多,暗区细节会更多。但是…

光谱相机识别瓶子材质的技术原理和应用案例

一、技术原理 ‌光谱特征差异识别‌ 不同材质的塑料(如PET、PP、PE等)因化学结构差异,在近红外或可见光波段会呈现独特的光谱反射曲线。例如,高光谱相机通过分析数百个窄波段的光谱数据,可生成每种材质的“光谱指纹”…

某快餐店用户市场数据挖掘与可视化

1、必要库的载入 import pandas as pd import matplotlib.pyplot as plt import seaborn as sns2、加载并清洗数据 # 2.1 加载数据 df pd.read_csv(/home/mw/input/survey6263/mcdonalds.csv)# 2.2 数据清洗 # 2.2.1 检查缺失值 print(缺失值情况:) print(df.isn…

MySQL 衍生表(Derived Tables)

在SQL的查询语句select …. from …中,跟在from子句后面的通常是一张拥有定义的实体表,而有的时候我们会用子查询来扮演实体表的角色,这个在from子句中的子查询会返回一个结果集,这个结果集可以像普通的实体表一样查询、连接&…

Electron使用WebAssembly实现CRC-16 MAXIM校验

Electron使用WebAssembly实现CRC-16 MAXIM校验 将C/C语言代码,经由WebAssembly编译为库函数,可以在JS语言环境进行调用。这里介绍在Electron工具环境使用WebAssembly调用CRC-16 MAXIM格式校验的方式。 CRC-16 MAXIM校验函数WebAssembly源文件 C语言实…

HTB 学习笔记 【中/英】《前端 vs. 后端》P3

📌 这篇文章讲了什么? 介绍了 前端(客户端) 和 后端(服务器端) 的区别。解释了 全栈开发(Full Stack Development),即前端后端开发。介绍了 前端和后端常用的技术。讨论…

SpringBoot集成ElasticSearch实现支持错别字检索和关键字高亮的模糊查询

文章目录 一、背景二、环境准备1.es8集群2.Kibana3.Canal 三、集成到SpringBoot1.新增依赖2.es配置类3.建立索引4.修改查询方法 四、修改前端 一、背景 我们在开发项目的搜索引擎的时候,如果当数据量庞大、同时又需要支持全文检索模糊查询,甚至你想做到…

麒麟系统使用-安装 SQL Developer

文章目录 前言一、基础准备1.基本环境2.相关包下载 二、进行相关配置1.配置JAVA2.配置SQL Developer 总结 前言 作为我国自主研发的操作系统,麒麟系统在使用时需要考虑安装相应的app。尽管麒麟系统是基于linux开发,可由于版本的一些差异,麒麟…

PrimeTime:timing_report_unconstrained_paths变量

相关阅读 PrimeTimehttps://blog.csdn.net/weixin_45791458/category_12900271.html?spm1001.2014.3001.5482 PrimeTime自Q-2019.12版本起引入了timing_report_unconstrained_paths变量(默认值为false),该变量控制是否在使用report_timing命…

洛谷 P1115 最大子段和(前缀和详解)c++

题目链接:P1115 最大子段和 - 洛谷 1.题目分析 2.算法原理 解法:利用前缀和 思考:如何求出以a[i]为结尾的所有子区间中最大的子段和 假设 i 等于5,以 a[ i ] 为结尾的区间一共是五段(黑色线条部分)&#…

JetBrains(全家桶: IDEA、WebStorm、GoLand、PyCharm) 2024.3+ 2025 版免费体验方案

JetBrains(全家桶: IDEA、WebStorm、GoLand、PyCharm) 2024.3 2025 版免费体验方案 前言 JetBrains IDE 是许多开发者的主力工具,但从 2024.02 版本起,JetBrains 调整了试用政策,新用户不再享有默认的 30 天免费试用…

【数据分析】数据筛选与访问行列元素3

访问元素 .loc属性可以通过传入index的值访问行数据。 .loc属性允许传入两个参数,分别是index的值和columns的值,参数间用“逗号”隔开,这样便可以访问数据中的元素。 1. 访问单个元素 访问单个元素比较简单,只需要通过它的in…

C++ std::list超详细指南:基础实践(手搓list)

目录 一.核心特性 1.双向循环链表结构 2.头文件:#include 3.时间复杂度 4.内存特性 二.构造函数 三.list iterator的使用 1.学习list iterator之前我们要知道iterator的区分 ​编辑 2.begin()end() 3.rbegin()rend() 四.list关键接口 1.empty() 2. size…

【免费】2004-2017年各地级市进出口总额数据

2004-2017年各地级市进出口总额数据 1、时间:2004-2017年 2、来源:城市年鉴 3、指标:进出口贸易总额 4、范围:286个地级市 5、指标说明:进出口总额是指一个国家在特定时期内(通常为一年)所…

谈谈 undefined 和 null

*** 补充 null 和 ‘’

【第15届蓝桥杯】软件赛CB组省赛

个人主页:Guiat 归属专栏:算法竞赛真题题解 文章目录 A. 握手问题(填空题)B. 小球反弹(填空题)C. 好数D. R格式E. 宝石组合F. 数字接龙G. 爬山H. 拔河 正文 总共8道题。 A. 握手问题(填空题&…

【计算机视觉】工业表计读数(2)--表计检测

1. 简介 工业表计(如压力表、电表、气表等)在工控系统、能源管理等领域具有重要应用。然而,传统人工抄表不仅工作量大、效率低,而且容易产生数据误差。近年来,基于深度学习的目标检测方法在工业检测中展现出极大优势&…

提示词工程(Prompt Engineering)

https://www.bilibili.com/video/BV1PX9iYQEry 一、懂原理,要知道 为什么有的指令有效,有的指令无效为什么同样的指令有时有效,又是无效怎么提升指令有效的概率 大模型应用架构师想什么? 怎样能更准确?答&#xff1…