应用层:

负责native格式的请求配置,请求发起、关闭等功能;

负责应用数据请求可直接调用的api的支持。

使用表示层和会话层包装而成的便捷工具(API):Alamofire

表示层:

将应用层配置的数据格式化为协议支持的数据格式(数据包);

根据应用要求和协议规定进行请求和相应数据的格式化和反格式化;

Techopedia explains Presentation Layer

The presentation layer is responsible for the following:

  • Data encryption/decryption
  • Character/string conversion
  • Data compression
  • Graphic handling

The presentation layer mainly translates data between the application layer and the network format. Data can be communicated in different formats via different sources. Thus, the presentation layer is responsible for integrating all formats into a standard format for efficient and effective communication.

OSI模型的表示层,为应用层提供数据,并负责数据装换和代码的格式化。从本质上来说,这一层是翻译器,并提供编码和转换功能。

会话层:

承接应用层的请求发起、关闭指令,进行会话处理和控制;包含会话数据的安全;

包含 http的会话管理策略、鉴权策略、ssl加密策略、证书验证策略、缓存策略等等等;

根据协议规定进行会话控制;

会话层是整个应用通信的核心;应用层所做的工作就是和表示层、会话层一起协作,配置会话需要的数据,从而完成会话。

编程的过程实在最上面的三个层次进行的;

之所以要分为三个层次,是为了方便逻辑上的组织;没有其它更多用途。

The Presentation Layer (Layer 6)

This layer is sometimes called the syntax layer. It isn’t often referred to, but in general the Presentation Layer is responsible for converting application data to a syntax that is ready for network transport using lower layer protocols.

https://www.wordfence.com/learn/networking-for-wordpress-administrators/

https://www.networxsecurity.org/members-area/glossary/o/osi-model.html

https://www.networxsecurity.org/members-area/glossary/o/osi-model.html

Application (think web browser, email client)

Application layer usually is the easiest to understand, so we should start our discussion here. This layer can be the program running on your computer (or on a server) that connects you to Google.com, eBay, or this blog. The client application will exchange data with the server application (and vice versa) without understanding Ethernet, TCP/IP, or other networking techniques (in general). This application data requires some processing locally before sending it to the server, care of the next several layers. I've provided examples next to the layer name, to help connect the layer to a common implementation.

Presentation (think encryption, compression)

Presentation layer provides formatting for data to be transferred between systems, so the end-system can readily receive and interpret the application data correctly. This step was vital when differing standards of data format were a problem (think 7-bit ASCII vs 8-bit EBCDIC). The most common examples now would be any encryption/decryption required for transmitting application data (not VPN-based, but application-based encryption) or the use of compression within applications transmitting data between systems.

Session (think Remote Procedure Calls)

Session layer provides a way for applications to "synchronize" their client-server communication and translate between "transport addresses" of Layer 4 and the "session addresses" that represent the application. If a system were running Firefox and Internet Explorer simultaneously, the session layer keeps Layer 4 connections associated with the right browser (or the pages displayed would be unusable in most cases). A good example of this layer are the remote procedure calls (RPC) associated with many client-server applications like Microsoft Exchange and Network File System (NFS).

https://primacore.net/articles/osi-model-overview.html

会话层:

在ssh、fastcgi以及http2等协议中,确实是有session的概念的。一个tcp链接里multiplex了多个session,每个session都可以单独close,创建session基本没有开销,session就相当于轻量级链接。

The session layer provides the mechanism for opening, closing and managing a session between end-user application processes, Communication sessions consist of requests and responses that occur between applications.

Session-layer services are commonly used in application environments that make use of remote procedure calls (RPCs).

Session layer establishes, controls and ends the sessions between local and remote applications.(tracks the dialogs between multiple computers)

我对ISO 七层模型的理解的更多相关文章

  1. ISO七层模型详解

    ISO七层模型详解 作者:尹正杰 版权声明:原创作品,谢绝转载!否则将追究法律责任. 在我刚刚接触运维这个行业的时候,去面试时总是会做一些面试题,笔试题就是看一个运维工程师的专业技能的掌握情况,这个很 ...

  2. TCP/IP四层协议模型与ISO七层模型

    TCP/IP四层协议模型与ISO七层模型 在世界上各地,各种各样的电脑运行着各自不同的操作系统为大家服务,这些电脑在表达同一种信息的时候所使用的方法是千差万别.就好像圣经中上帝打乱了各地人的口音,让他 ...

  3. 网络知识_01:ISO七层模型

    一 IOS七层模型 1.1OSI的概念 Open System Interconnect开放系统互连参考模型,是由ISO(国际标准化组织)定义的.它是个灵活的.稳健的和可互操作的模型. 1.2OSI模 ...

  4. 温故知新--计算机网络 iso/osi七层模型 tcp/ip四层模型

    ISO七层模型由下至上为1至7层,分别为: 应用层(Application layer) 表示层(Presentation layer) 会话层(Session layer) 传输层(Transpor ...

  5. 1-2 ISO/OSI七层模型简介

    相关名词解释: ISO:国际标准化组织 OSI:开放系统互联模型 IOS:苹果操作系统, 但是在计算机网络中,IOS是互联网操作系统,是思科公司为其网络设备开发的操作维护系统 <1>OSI ...

  6. Linux网络管理——ISO/OSI七层模型

    1. 网络基础 1. 网络基础 1.1 iso/osi七层模型 事前声明: ISO:国际标准化组织 OSI:开放系统互联模型 IOS:苹果操作系统 但是在计算机网络当中,IOS是互联网操作系统,是思科 ...

  7. OSI七层模型详解 TCP/IP协议

      总结 OSI中的层 功能 TCP/IP协议族 应用层 文件传输,电子邮件,文件服务,虚拟终端 TFTP,HTTP,SNMP,FTP,SMTP,DNS,Telnet 等等 表示层 数据格式化,代码转 ...

  8. python网络编程-OSI七层模型详解

    OSI 七层模型通过七个层次化的结构模型使不同的系统不同的网络之间实现可靠的通讯,因此其最主要的功能就是帮助不同类型的主机实现数据传输 . 完成中继功能的节点通常称为中继系统.在OSI七层模型中,处于 ...

  9. OSI七层模型

    OSI 七层模型通过七个层次化的结构模型使不同的系统不同的网络之间实现可靠的通讯,因此其最主要的功能就是帮助不同类型的主机实现数据传输 . 完成中继功能的节点通常称为中继系统.在OSI七层模型中,处于 ...

随机推荐

  1. 遍历 HashSet 的方法

    遍历 HashSet 的方法 import java.util.HashSet; import java.util.Iterator; import java.util.Set; public cla ...

  2. 原始(Prototype)模式

    原型模式:用原型实例指定创建对象的种类,并且通过拷贝这些原型对象创建新的对象. 原型模式其实就是从一个对象创建另外一个可复制的对象,而且不需要知道任何创建的细节.(最常用的就是基于流的深复制) 原始模 ...

  3. 利用分析洞察力来改进Sitecore内容编辑过程

    本文旨在增强内容作者的体验; 利用富有洞察力的数据为编辑过程增添真正的价值. 内容作者的日常生活是忙碌的.从一页跳到另一页,进行修改或创建全新的领域.任务的优先顺序由谁来确定?通常首先那些呼喊最响的人 ...

  4. 初步学习async/await,Task.GetAwaiter,Task.Result

    网上关于async/await的知识有很多,看了很多但不如自己实践一遍来得快,所以这里记录下我的理解和大家学习下. 首先以最简单的同步方法来开始如下 private static void Test( ...

  5. Javascript文件上传插件

    jQuery File Uploader 这是最受欢迎的 jQuery 文件上传组件,支持批量上传,拖放上传,显示上传进度条以及校验功能. 支持预览图片.音频和视频,支持跨域上传和客户端图片缩放,支持 ...

  6. 第一章 Maven 安装配置

    Maven基于(POM)项目对象模型,通过一小段描述信息来管理项目的构建.文档.和报告的项目管理软件,类似于php 的管理构建工具composer. 有关详细的Maven学习,可以参考学习https: ...

  7. Java自学-异常处理 自定义异常

    Java 自定义异常 示例 1 : 创建自定义异常 一个英雄攻击另一个英雄的时候,如果发现另一个英雄已经挂了,就会抛出EnemyHeroIsDeadException 创建一个类EnemyHeroIs ...

  8. 关于vscode自动跳转回车的解决方法(关闭vscode自动保存功能;可能和其他插件有冲突)

    关于vscode自动跳转回车的解决方法(关闭vscode自动保存功能:可能和其他插件有冲突)

  9. 英语catarinite天铁托甲catarinite镍铁陨石

    中文名称:天铁 镍铁陨石(catarinite)是铁质陨石的一种,发现地有南非,美国,澳洲,南极大陆等.镍铁陨石有著美丽的韦德曼交纹及高含量的镍成分,因此不易氧化,大部分都用来制造饰品或展现陨石韦德曼 ...

  10. 19道常见的JS面试算法题

    最近秋招也做了多多少少的面试题,发现除了基础知识外,算法还是挺重要的.特意整理了一些常见的算法题,添加了自己的理解并实现. 除此之外,建议大家还可以刷刷<剑指offer>.此外,左神在牛客 ...