函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:kernel\bpf\verifier.c Create Date:2022-07-27 14:11:29
Last Modify:2022-05-19 20:02:10 Copyright©Brick
首页 函数Tree
注解内核,赢得工具下载SCCTEnglish

函数名称:__check_packet_access

函数原型:static int __check_packet_access(struct bpf_verifier_env *env, u32 regno, int off, int size, bool zero_size_allowed)

返回类型:int

参数:

类型参数名称
struct bpf_verifier_env *env
u32regno
intoff
intsize
boolzero_size_allowed
2348  regs等于cur_regs(env)
2349  reg等于regs[regno]
2351  如果off小于0或size小于0或size恒等于0且非zero_size_allowedoffsize大于 valid when type == PTR_TO_PACKET
2353  verbose(env, "invalid access to packet, off=%d size=%d, R%d(id=%d,off=%d,r=%d)\n", off, size, regno, For PTR_TO_PACKET, used to find other pointers with the same variable * offset, so they can share range knowledge. * For PTR_TO_MAP_VALUE_OR_NULL this is used to share which map value we * came from, when one is tested for != NULL. * For PTR_TO_SOCKET thi, Fixed part of pointer offset, pointer types only , valid when type == PTR_TO_PACKET )
2355  返回:负EACCES
2357  返回:0
调用者
名称描述
check_packet_access