GTP-U experiment and security consideratiion
User Plane protocol stack in 5G
Transmission path of data
Experiment Setting:After initiating the srsUE and srsgnb, the memory usage is as follows:
We install Open5GS and srsRAN both in the Raspberry pi 4 8G.
When we ping UPF address, and see what the GTP-U packet is like, we use
1sudo tcpdump -i lo udp port 2152 -n -vv -w gtpu_test.pcap
Where the lo represents localhost since the Open5GS config uses loop back addresses for each function. Only the UPF has an public ip address who needs to commu ...
Greedy algorithms
Greedy strategy for coin changeGiven n types of coins, where the denomination of the ith type of coin is coins[i−1], and the target amount is amt, with each type of coin available indefinitely, what is the minimum number of coins needed to make up the target amount? If it is not possible to make up the target amount, return −1.
Given the target amount, we greedily choose the coin that is closest to and not greater than it
123456789101112131415161718int coinChangeGreedy(vector<int> &coi ...
RAN仿真实现学习
安装Open5GSOpen5GS core结构如图所示:
Next time we will complement the explanations of each component.
Install Open5GS with a Package ManagerHere we should import the public key used by the package management system.
123$ sudo apt update$ sudo apt install gnupg$ curl -fsSL https://pgp.mongodb.com/server-6.0.asc | sudo gpg -o /usr/share/keyrings/mongodb-server-6.0.gpg --dearmor
Then we will create the list file /etc/apt/sources.list.d/mongodb-org-6.0.list for your version of Ubuntu.
Universally we use Ub ...
NS3 simulation
Installationthis part will be supplemented soon.
Build and setupthis part will be supplemented soon.
Simulation study first partbuild our own script “first.cc”
12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758#include "ns3/core-module.h"#include "ns3/network-module.h"#include "ns3/internet-module.h"#include "ns3/point-to-point-module.h"#include "ns3/applications-module.h"using namespace ns ...
Named Data Network
Let data consumers fetch desired data
Higher layers decide whether to fetch, and which piece most urgent
Lower layers decide when/what’s the best way to fetch.
Performance evaluationmeasure transport performance: dataset namespace udpate delay
sync interests can be lost.
time between data production and reception by each node in the group.
measure application performance:
Fetching delay: the time period from sending an interest packet till the requested data packet received.
Throughput
Th ...
Visual Basic Application(in Access)
窗体设计例子1.窗体的标题每隔1秒钟交替显示当前日期和当前时间。
窗体的属性表中的事件选项卡上,在事件过程中编辑弹出的VBE框和代码。
1234Private Sub Form_Load() Me.Caption = Time#设置字幕为时间 #Caption为窗体Me的属性。End Sub
然后将属性表中的“计时器间隔”属性设置为1000,然后设置计时器触发代码如下:
1234567Private Sub Form_Timer() If Me.caption = Date Then Me.caption = Time Else Me.Caption = Date End IfEnd Sub
注意If后面一定要接End If。
2.输入口令的判别过程
也就是一个输入口令的框,然后设置1个密码,2个按键,分别写入确认和退出函数。
确认函数如下:
123456789Private Sub Command2_Click() If Me.Text0.Value = "123456" Then MsgBox "口令正确,欢迎进入!"#文本显示 Els ...
DB文本检测模型和CRNN文本识别模型的推理
CTPN讲解本网络也分为三部分,允许任意大小的图像输入。它通过密集地滑动小窗口在卷积特征图上检测文本行,输入一个固定大小的文本建议序列。我们采用VGG16卷积神经网络来提取特征图,用3x3的小窗口在卷积最后一层上进行滑动。卷积最后一层conv5的结果大小显然已经由输入图像大小,卷积层参数确定了。
和传统目标检测不同,文本区域容易无法检测出全部文本,只得到部分区域,因为文本包含很多特征,比如笔画,字符,单词,文本行。因为单词有分开的特点,所以不容易预测文本的开始与结束。所以我们可以将文本行看成一个固定大小文本建议序列,比如每个文本建议为16像素宽,所以每个建议区域都包含文字的一部分。提高了准确率因为固定了很难检测的横向坐标。相比于以前的预测4个坐标,现在我们只需要预测纵向坐标。
对于每一个文本区域,预测两个结果,一个是竖直坐标,另一个是文本/非文本分数。
我们的文本建议是被定义为16像素宽的区域,其实就是移动检测器(检测器测量conv5中每一个空间位置)让步长为16即可。我们对于每个文本区域,用k个相同水平位置的框(纵坐标不同)来预测。
这k个框,每个的高度和中心坐标都可以通过输入图像直 ...
v2ray全连接后的一次网络实验
我们记录一次实验数据,首先是尝试访问http://www.youtube.com,然后观察v2ray日志在`/var/log/v2ray/access.log`查看我们与代理端口1087通信的端口号,如图所示:
与此同时我们提前打开了wireshark抓取loopback地址的包,如图所示。
发现通过tcp三次握手与1087建立了连接。然后发送了http数据,我们打开这个http请求数据,如图:
看到设置了proxy选项。
这期间还进行了两次DNS查询,在上图红色即为查询结果,可以看到查询结果就是正确解析到的cloudflare的ip地址,如图所示:
在整个通信过程最后我们可以看到
通过代理服务器收到了返回的http包裹,然后四次挥手断开连接。我们试图找到代理的痕迹。
打开http包裹,如图所示,看到代理持续连接。
我们再来一次实验,这次抓一下以太网卡,看一下外部的情况,就圆满了。
我们看到首先进行三次握手,和cloudflare代理服务器建立通信,然后将数据通过tls1.3协议转发出去。这个协议是由cloudflare端设置的,可以在cloudflare平台看到。数据包 ...
lab-hackthebox-Vaccine-FTPRCE
首先用openvpn连接到vpn服务,然后进行常规扫描
12nmap -sC -sV ipnmap -sS -Pn -n -p- --open ip --min-rate=5000
这里我们看到了ftp服务开启并且允许匿名登陆。
汇编语言(十三)内中断
内中断任何一种CPU都可以执行这样的操作,也就是在执行指令的过程中,突然检测到从CPU内部或者外部发送过来或是产生的一种特殊信息,CPU要先处理这个特殊信息,然后再去继续执行指令。这种特殊的信息称为中断信息。而本章的内中断就是指CPU内部产生的中断信息。
1.内中断的产生当CPU有下列特殊情况发生时候,会产生中断信息
1.除法错误,比如div产生除法溢出。(中断码:0)
2.单步执行。(中断码:1)
3.执行into指令。(中断码:4)
4.执行int指令。(该指令的格式位int n,n为字节型立即数,为中断码。)
接收到这4种不同的信息,就要进行不同的处理。因为中断信息来源不同,比如上面4种,那么就要有编码来对不同事件编码区分,叫做中断类型码,为一个字节型数据,可以表示256种中断信息的来源。
2.中断程序处理对中断信息处理需要我们编程决定。一般对不同的中断信息写不同的程序。要执行某处的程序,就要将CS:IP指向它的入口(也就是程序第一条指令的地址)。所以重要的问题时,CPU收到中断信息后,如何根据中断信息确定其处理程序的入口。所以CPU需要在中断信息和程序入口之间建立联系。
根据中 ...



