1 /* SPDX-License-Identifier: GPL-2.0-or-later 2 * Copyright (c) 2019 Martin Doucha <mdoucha@suse.cz> 3 */ 4 5 /* 6 * Common settings and data types for bind() connection tests 7 */ 8 9 #include <sys/types.h> 10 #include <sys/socket.h> 11 #include <sys/un.h> 12 #include <arpa/inet.h> 13 #include <netinet/in.h> 14 #include <netinet/ip.h> 15 16 #define MAIN_SOCKET_FILE "test.sock" 17 #define ABSTRACT_SOCKET_PATH "\0test.sock" 18 #define PEER_SOCKET_FILE "peer.sock" 19 #define IPV4_ADDRESS "127.0.0.1" 20 #define BUFFER_SIZE 128 21 22 struct test_case { 23 int type, protocol; 24 struct sockaddr *address; 25 socklen_t addrlen; 26 const char *description; 27 }; 28