Defined in 1 files as a function:

Referenced in 9 files:

Smatch caller information:

kernel/bpf/log.c copy_to_bpfptr_offset() -> copy_to_sockptr_offset()

Type Parameter Key Value
PARAM_VALUE 1 offset 1-u32max
PARAM_VALUE 2 src 8006813563159089152
PARAM_VALUE 3 size 4
BUF_SIZE 2 src 4
BUF_SIZE 2 src 4
DATA_SOURCE 0 dst $0
DATA_SOURCE 1 offset $1
DATA_SOURCE 2 src $2
DATA_SOURCE 3 size $3
BIT_INFO 0 dst 0x0,0x0
UNITS 3 size unit_byte

drivers/virt/coco/sev-guest/sev-guest.c copy_to_sockptr() -> copy_to_sockptr_offset()

Type Parameter Key Value
PARAM_VALUE 1 offset 0
PARAM_VALUE 2 src 4096-ptr_max
PARAM_VALUE 3 size 0-16384
BUF_SIZE 2 src 0,112,4016,4096-16384
BUF_SIZE 2 src 0,112,4016,4096-16384
CAPPED_DATA 2 src 1
DATA_SOURCE 0 dst $0
DATA_SOURCE 2 src $1
DATA_SOURCE 3 size $2
FUZZY_MAX 3 size 16384
BIT_INFO 0 dst 0x0,0x0
BIT_INFO 3 size 0x0,0x7ff0
BIT_INFO 3 size 0x0,0x7ff0
RX_PATH
TASK_NOT_RUNNING
USER_DATA 3 size 1-16384
UNITS 3 size unit_byte
USER_PTR 2 src

security/smack/smack_lsm.c copy_to_sockptr() -> copy_to_sockptr_offset()

Type Parameter Key Value
PARAM_VALUE 1 offset 0
PARAM_VALUE 3 size 1-1010102
BUF_SIZE 2 src (-1),1,4
BUF_SIZE 2 src (-1),1,4
CAPPED_DATA 3 size 1
CAPPED_DATA 3 size 1
DATA_SOURCE 0 dst $0
DATA_SOURCE 2 src $1
DATA_SOURCE 3 size $2
FUZZY_MAX 3 size 1
STR_LEN 0 dst (-1)-0
STR_LEN 0 dst (-1)-0
BIT_INFO 0 dst 0x0,0x0
UNITS 3 size unit_byte

net/core/filter.c copy_to_sockptr() -> copy_to_sockptr_offset()

Type Parameter Key Value
PARAM_VALUE 1 offset 0
PARAM_VALUE 3 size 0-524280
CAPPED_DATA 3 size 1
CAPPED_DATA 3 size 1
DATA_SOURCE 0 dst $0
DATA_SOURCE 2 src $1
DATA_SOURCE 3 size $2
BIT_INFO 0 dst 0x0,0x0
RX_PATH
TASK_NOT_RUNNING
HALF_LOCKED2 sk

net/ipv4/tcp.c copy_to_sockptr() -> copy_to_sockptr_offset()

Type Parameter Key Value
PARAM_VALUE 1 offset 0
PARAM_VALUE 3 size 0-s32max,18446744071562067968-u64max
BUF_SIZE 2 src (-1),4,16,20,32,64,280
BUF_SIZE 2 src (-1),4,16,20,32,64,280
DATA_SOURCE 0 dst $0
DATA_SOURCE 2 src $1
DATA_SOURCE 3 size $2
BIT_INFO 0 dst 0x0,0x0
RX_PATH
USER_DATA 3 size 0-s32max,18446744071562067968-u64max
UNITS 3 size unit_byte

net/ipv4/igmp.c copy_to_sockptr() -> copy_to_sockptr_offset()

Type Parameter Key Value
PARAM_VALUE 1 offset 0
PARAM_VALUE 2 src 4602062573353107456,6412688078062829568
PARAM_VALUE 3 size 4,16
BUF_SIZE 2 src (-1),4
BUF_SIZE 2 src (-1),4
DATA_SOURCE 0 dst $0
DATA_SOURCE 2 src $1
DATA_SOURCE 3 size $2
BIT_INFO 0 dst 0x0,0x0
HARD_MAX 3 size 16
RX_PATH
UNITS 3 size unit_byte
HALF_LOCKED2 global &rtnl_mutex
HALF_LOCKED2 sk

net/ipv4/igmp.c ip_mc_gsfget() -> copy_to_sockptr_offset()

Type Parameter Key Value
PARAM_VALUE 1 offset 140,144,268,272-u64max
PARAM_VALUE 2 src 8062427076335206400
PARAM_VALUE 3 size 128
BUF_SIZE 2 src 128
DATA_SOURCE 0 dst $2
DATA_SOURCE 1 offset $3 [m]
BIT_INFO 0 dst 0x0,0x0
MEM_ZERO 2 src
RX_PATH
UNITS 3 size unit_byte
HALF_LOCKED2 global &rtnl_mutex
HALF_LOCKED2 sk

net/ipv4/igmp.c ip_mc_msfget() -> copy_to_sockptr_offset()

Type Parameter Key Value
PARAM_VALUE 1 offset 16
PARAM_VALUE 3 size 1-s32max,18446744071562067968-u64max
BUF_SIZE 2 src 4-s32max
CAPPED_DATA 3 size 1
DATA_SOURCE 0 dst $2
DATA_SOURCE 3 size r size_mul
BIT_INFO 0 dst 0x0,0x0
RX_PATH
USER_DATA 3 size 4-s32max[c]
HALF_LOCKED2 global &rtnl_mutex
HALF_LOCKED2 sk

net/ipv6/ipv6_sockglue.c compat_ipv6_get_msfilter() -> copy_to_sockptr_offset()

Type Parameter Key Value
PARAM_VALUE 1 offset 132
PARAM_VALUE 3 size 4
BUF_SIZE 2 src 4
DATA_SOURCE 0 dst $1
BIT_INFO 0 dst 0x0,0x0
RX_PATH
UNITS 3 size unit_byte
HALF_LOCKED2 sk

net/ipv6/ipv6_sockglue.c compat_ipv6_get_msfilter() -> copy_to_sockptr_offset()

Type Parameter Key Value
PARAM_VALUE 1 offset 136
PARAM_VALUE 3 size 4
BUF_SIZE 2 src 4
DATA_SOURCE 0 dst $1
BIT_INFO 0 dst 0x0,0x0
RX_PATH
UNITS 3 size unit_byte
HALF_LOCKED2 sk

net/ipv6/ipv6_sockglue.c copy_to_sockptr() -> copy_to_sockptr_offset()

Type Parameter Key Value
PARAM_VALUE 1 offset 0
PARAM_VALUE 3 size 0-s32max,18446744071562067968-u64max
BUF_SIZE 2 src (-1),4,32,272
BUF_SIZE 2 src (-1),4,32,272
CAPPED_DATA 3 size 1
CAPPED_DATA 3 size 1
DATA_SOURCE 0 dst $0
DATA_SOURCE 2 src $1
DATA_SOURCE 3 size $2
BIT_INFO 0 dst 0x0,0x0
RX_PATH
USER_DATA 3 size 0-2047[c]
UNITS 2 src unit_byte
UNITS 3 size unit_byte

net/ipv6/ip6mr.c copy_to_sockptr() -> copy_to_sockptr_offset()

Type Parameter Key Value
PARAM_VALUE 1 offset 0
PARAM_VALUE 2 src 1754092673830039552,3211545678044725248
PARAM_VALUE 2 *src 0-4,773
PARAM_VALUE 3 size 0-4,18446744071562067968-u64max
BUF_SIZE 2 src 4
BUF_SIZE 2 src 4
DATA_SOURCE 0 dst $0
DATA_SOURCE 2 src $1
DATA_SOURCE 3 size $2
BIT_INFO 0 dst 0x0,0x0
RX_PATH
USER_DATA 3 size 0-3[c]
UNITS 3 size unit_byte

net/ipv4/ip_sockglue.c compat_ip_get_mcast_msfilter() -> copy_to_sockptr_offset()

Type Parameter Key Value
PARAM_VALUE 1 offset 132
PARAM_VALUE 3 size 4
BUF_SIZE 2 src 4
DATA_SOURCE 0 dst $1
BIT_INFO 0 dst 0x0,0x0
RX_PATH
UNITS 3 size unit_byte
HALF_LOCKED2 global &rtnl_mutex
HALF_LOCKED2 sk

net/ipv4/ip_sockglue.c compat_ip_get_mcast_msfilter() -> copy_to_sockptr_offset()

Type Parameter Key Value
PARAM_VALUE 1 offset 136
PARAM_VALUE 3 size 4
BUF_SIZE 2 src 4
DATA_SOURCE 0 dst $1
BIT_INFO 0 dst 0x0,0x0
RX_PATH
UNITS 3 size unit_byte
HALF_LOCKED2 global &rtnl_mutex
HALF_LOCKED2 sk

net/ipv4/ip_sockglue.c copy_to_sockptr() -> copy_to_sockptr_offset()

Type Parameter Key Value
PARAM_VALUE 1 offset 0
PARAM_VALUE 3 size 0-s32max
BUF_SIZE 2 src (-1),4,40,272
BUF_SIZE 2 src (-1),4,40,272
DATA_SOURCE 0 dst $0
DATA_SOURCE 2 src $1
DATA_SOURCE 3 size $2
BIT_INFO 0 dst 0x0,0x0
RX_PATH
USER_DATA 3 size 0-s32max[c]
UNITS 3 size unit_byte

net/ipv6/ip6_flowlabel.c ipv6_flowlabel_get() -> copy_to_sockptr_offset()

Type Parameter Key Value
PARAM_VALUE 1 offset 16
PARAM_VALUE 2 src 4096-ptr_max
PARAM_VALUE 2 *src 0-1048575
PARAM_VALUE 3 size 4
BUF_SIZE 2 src 4
DATA_SOURCE 0 dst $2
BIT_INFO 0 dst 0x0,0x0
RX_PATH
TASK_NOT_RUNNING
UNITS 3 size unit_byte
HALF_LOCKED2 sk

kernel/bpf/cgroup.c copy_to_sockptr() -> copy_to_sockptr_offset()

Type Parameter Key Value
PARAM_VALUE 1 offset 0
PARAM_VALUE 3 size 1-s32max
BUF_SIZE 2 src (-1),4
BUF_SIZE 2 src (-1),4
CAPPED_DATA 3 size 1
CAPPED_DATA 3 size 1
DATA_SOURCE 0 dst $0
DATA_SOURCE 2 src $1
DATA_SOURCE 3 size $2
BIT_INFO 0 dst 0x0,0x0
RX_PATH
TASK_NOT_RUNNING
USER_DATA 3 size 1-s32max[c]
UNITS 3 size unit_byte
USER_PTR 2 src

net/core/sock.c copy_to_sockptr() -> copy_to_sockptr_offset()

Type Parameter Key Value
PARAM_VALUE 1 offset 0
PARAM_VALUE 3 size 0-s32max,18446744071562067968-u64max
BUF_SIZE 2 src 4,12,16,36,128
BUF_SIZE 2 src 4,12,16,36,128
CAPPED_DATA 3 size 1
CAPPED_DATA 3 size 1
DATA_SOURCE 0 dst $0
DATA_SOURCE 2 src $1
DATA_SOURCE 3 size $2
STR_LEN 0 dst (-1)-s32max
STR_LEN 0 dst (-1)-s32max
BIT_INFO 0 dst 0x0,0x0
RX_PATH
TASK_NOT_RUNNING
USER_DATA 3 size 0-s32max[c]
UNITS 3 size unit_byte

net/core/sock.c groups_to_user() -> copy_to_sockptr_offset()

Type Parameter Key Value
PARAM_VALUE 1 offset 0-8589934588
PARAM_VALUE 2 src 5269675842486128640
PARAM_VALUE 3 size 4
BUF_SIZE 2 src 4
CAPPED_DATA 1 offset 1
DATA_SOURCE 0 dst $0
BIT_INFO 0 dst 0x0,0x0
RX_PATH
TASK_NOT_RUNNING
UNITS 3 size unit_byte

net/socket.c copy_to_sockptr() -> copy_to_sockptr_offset()

Type Parameter Key Value
PARAM_VALUE 1 offset 0
PARAM_VALUE 2 src 1266357494456262736
PARAM_VALUE 2 *src 0-s32max
PARAM_VALUE 3 size 4
BUF_SIZE 2 src 4
BUF_SIZE 2 src 4
DATA_SOURCE 0 dst $0
DATA_SOURCE 2 src $1
DATA_SOURCE 3 size $2
BIT_INFO 0 dst 0x0,0x0
RX_PATH
UNITS 3 size unit_byte

net/ipv6/mcast.c ip6_mc_msfget() -> copy_to_sockptr_offset()

Type Parameter Key Value
PARAM_VALUE 1 offset 140,144,268,272-u64max
PARAM_VALUE 2 src 3109187961033854976
PARAM_VALUE 3 size 128
BUF_SIZE 2 src 128
DATA_SOURCE 0 dst $2
DATA_SOURCE 1 offset $3 [m]
BIT_INFO 0 dst 0x0,0x0
MEM_ZERO 2 src
RX_PATH
UNITS 3 size unit_byte
HALF_LOCKED2 sk

net/ipv4/tcp_ao.c copy_to_sockptr() -> copy_to_sockptr_offset()

Type Parameter Key Value
PARAM_VALUE 1 offset 0
PARAM_VALUE 2 src 3455305663459356672,4255672503487967232,7755768682469928960
PARAM_VALUE 3 size 1-48
BUF_SIZE 2 src 4,16,48
BUF_SIZE 2 src 4,16,48
CAPPED_DATA 3 size 1
CAPPED_DATA 3 size 1
DATA_SOURCE 0 dst $0
DATA_SOURCE 2 src $1
DATA_SOURCE 3 size $2
BIT_INFO 0 dst 0x0,0x0
RX_PATH
USER_DATA 3 size 1-47[c]
UNITS 3 size unit_byte
HALF_LOCKED2 sk

net/ipv4/tcp_ao.c tcp_ao_copy_mkts_to_user() -> copy_to_sockptr_offset()

Type Parameter Key Value
PARAM_VALUE 2 src 3520981153472221184
PARAM_VALUE 3 size 1-304
BUF_SIZE 2 src 304
CAPPED_DATA 3 size 1
CAPPED_DATA 3 size 1
DATA_SOURCE 0 dst $2
BIT_INFO 0 dst 0x0,0x0
NOSPEC 3 size
MEM_ZERO 2 src
RX_PATH
USER_DATA 1 offset 1-s32max[c][u]
USER_DATA 3 size 1-303[c]
UNITS 3 size unit_byte
HALF_LOCKED2 sk
HALF_LOCKED2 sk

net/ipv4/tcp_ao.c tcp_ao_copy_mkts_to_user() -> copy_to_sockptr_offset()

Type Parameter Key Value
PARAM_VALUE 1 offset 272
PARAM_VALUE 2 src 4915988775592701952
PARAM_VALUE 3 size 4
BUF_SIZE 2 src 4
DATA_SOURCE 0 dst $2
BIT_INFO 0 dst 0x0,0x0
RX_PATH
UNITS 3 size unit_byte
HALF_LOCKED2 sk
HALF_LOCKED2 sk

kernel/bpf/check_btf.c copy_to_bpfptr_offset() -> copy_to_sockptr_offset()

Type Parameter Key Value
PARAM_VALUE 1 offset 76,92,136
PARAM_VALUE 2 src 4278279171138863104,7942295951882776576,8169461896178999296
PARAM_VALUE 2 *src 8,16
PARAM_VALUE 3 size 4
BUF_SIZE 2 src 4
BUF_SIZE 2 src 4
DATA_SOURCE 0 dst $0
DATA_SOURCE 1 offset $1
DATA_SOURCE 2 src $2
DATA_SOURCE 3 size $3
BIT_INFO 0 dst 0x0,0x0
HARD_MAX 1 offset 136
HARD_MAX 2 *src 16
UNITS 3 size unit_byte

drivers/virt/coco/tdx-guest/tdx-guest.c copy_to_sockptr() -> copy_to_sockptr_offset()

Type Parameter Key Value
PARAM_VALUE 1 offset 0
PARAM_VALUE 2 src 0,4096-ptr_max
PARAM_VALUE 3 size 1024
DATA_SOURCE 0 dst $0
DATA_SOURCE 2 src $1
DATA_SOURCE 3 size $2
BIT_INFO 0 dst 0x0,0x0
RX_PATH
TASK_NOT_RUNNING
HALF_LOCKED2 &buffer->mutex
HALF_LOCKED2 &frag->frag_sem
HALF_LOCKED2 _T->lock

security/apparmor/lsm.c copy_to_sockptr() -> copy_to_sockptr_offset()

Type Parameter Key Value
PARAM_VALUE 1 offset 0
PARAM_VALUE 2 src 16,4096-ptr_max
PARAM_VALUE 2 *src 0-s32max
PARAM_VALUE 3 size 0-s32max
BUF_SIZE 2 src (-1),4
BUF_SIZE 2 src (-1),4
CAPPED_DATA 3 size 1
CAPPED_DATA 3 size 1
DATA_SOURCE 0 dst $0
DATA_SOURCE 2 src $1
DATA_SOURCE 3 size $2
BIT_INFO 0 dst 0x0,0x0
UNITS 3 size unit_byte

security/selinux/hooks.c copy_to_sockptr() -> copy_to_sockptr_offset()

Type Parameter Key Value
PARAM_VALUE 1 offset 0
BUF_SIZE 2 src (-1),4
BUF_SIZE 2 src (-1),4
CAPPED_DATA 3 size 1
CAPPED_DATA 3 size 1
DATA_SOURCE 0 dst $0
DATA_SOURCE 2 src $1
DATA_SOURCE 3 size $2
BIT_INFO 0 dst 0x0,0x0
UNITS 3 size unit_byte

net/ipv4/ipmr.c copy_to_sockptr() -> copy_to_sockptr_offset()

Type Parameter Key Value
PARAM_VALUE 1 offset 0
PARAM_VALUE 2 src 642562440246562816,5344317070089072640
PARAM_VALUE 2 *src 0-4,773
PARAM_VALUE 3 size 0-4
BUF_SIZE 2 src 4
BUF_SIZE 2 src 4
DATA_SOURCE 0 dst $0
DATA_SOURCE 2 src $1
DATA_SOURCE 3 size $2
BIT_INFO 0 dst 0x0,0x0
RX_PATH
USER_DATA 3 size 0-3[c]
UNITS 3 size unit_byte