aboutsummaryrefslogtreecommitdiffstats
path: root/erts/emulator/nifs/common/socket_int.h
diff options
context:
space:
mode:
authorMicael Karlberg <[email protected]>2018-10-04 15:24:13 +0200
committerMicael Karlberg <[email protected]>2018-10-04 15:28:04 +0200
commit352b28117de7e523ea09fd2b6a5066d8ffd1156b (patch)
tree26b9af82090a12edf5d054502232b79dbe2cf2a6 /erts/emulator/nifs/common/socket_int.h
parent1c412c62ba3be17b7a818f264049a7ee7942351e (diff)
downloadotp-352b28117de7e523ea09fd2b6a5066d8ffd1156b.tar.gz
otp-352b28117de7e523ea09fd2b6a5066d8ffd1156b.tar.bz2
otp-352b28117de7e523ea09fd2b6a5066d8ffd1156b.zip
[socket-nif] Add owner validation when setopt controlling_process
Before allowing setopt(Sock, opt, controlling_process, NewPid), verify that the caller is actually the current controlling_process. OTP-14831
Diffstat (limited to 'erts/emulator/nifs/common/socket_int.h')
-rw-r--r--erts/emulator/nifs/common/socket_int.h11
1 files changed, 11 insertions, 0 deletions
diff --git a/erts/emulator/nifs/common/socket_int.h b/erts/emulator/nifs/common/socket_int.h
index c3595e495d..f9246856fa 100644
--- a/erts/emulator/nifs/common/socket_int.h
+++ b/erts/emulator/nifs/common/socket_int.h
@@ -103,8 +103,10 @@ typedef unsigned int BOOLEAN_T;
/* ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
* "Global" atoms
*/
+extern ERL_NIF_TERM esock_atom_accept;
extern ERL_NIF_TERM esock_atom_addr;
extern ERL_NIF_TERM esock_atom_any;
+extern ERL_NIF_TERM esock_atom_connect;
extern ERL_NIF_TERM esock_atom_credentials;
extern ERL_NIF_TERM esock_atom_ctrl;
extern ERL_NIF_TERM esock_atom_ctrunc;
@@ -129,6 +131,8 @@ extern ERL_NIF_TERM esock_atom_local;
extern ERL_NIF_TERM esock_atom_loopback;
extern ERL_NIF_TERM esock_atom_lowdelay;
extern ERL_NIF_TERM esock_atom_mincost;
+extern ERL_NIF_TERM esock_atom_not_found;
+extern ERL_NIF_TERM esock_atom_not_owner;
extern ERL_NIF_TERM esock_atom_ok;
extern ERL_NIF_TERM esock_atom_oob;
extern ERL_NIF_TERM esock_atom_origdstaddr;
@@ -138,11 +142,18 @@ extern ERL_NIF_TERM esock_atom_port;
extern ERL_NIF_TERM esock_atom_protocol;
extern ERL_NIF_TERM esock_atom_raw;
extern ERL_NIF_TERM esock_atom_rdm;
+extern ERL_NIF_TERM esock_atom_recv;
+extern ERL_NIF_TERM esock_atom_recvfrom;
+extern ERL_NIF_TERM esock_atom_recvmsg;
extern ERL_NIF_TERM esock_atom_reliability;
extern ERL_NIF_TERM esock_atom_rights;
extern ERL_NIF_TERM esock_atom_scope_id;
extern ERL_NIF_TERM esock_atom_sctp;
extern ERL_NIF_TERM esock_atom_sec;
+extern ERL_NIF_TERM esock_atom_select_sent;
+extern ERL_NIF_TERM esock_atom_send;
+extern ERL_NIF_TERM esock_atom_sendmsg;
+extern ERL_NIF_TERM esock_atom_sendto;
extern ERL_NIF_TERM esock_atom_seqpacket;
extern ERL_NIF_TERM esock_atom_socket;
extern ERL_NIF_TERM esock_atom_spec_dst;