/macosx-10.10/ppp-786.1.1/Drivers/PPTP/PPTP-extension/ |
H A D | pptp_proto.c | 52 #define ALIGNED_CAST(type) (type)(void *) macro 334 pptp_wan_detach(ALIGNED_CAST(struct ppp_link *)so->so_tpcb); 363 aligned_data = (ALIGNED_CAST(struct ppp_link *)so->so_tpcb)->lk_index; // Wcast-align fix - we malloc so->so_tpcb - lk_index is u_1616_t copying to u_int32_t 370 error = pptp_wan_attach(so->so_pcb, ALIGNED_CAST(struct ppp_link **)&so->so_tpcb); 376 pptp_wan_detach(ALIGNED_CAST(struct ppp_link *)so->so_tpcb); 406 return pptp_wan_input(ALIGNED_CAST(struct ppp_link *)so->so_tpcb, m); 425 pptp_wan_xmit_full(ALIGNED_CAST(struct ppp_link *)so->so_tpcb); // Wcast-align fix - we malloc so->so_tpcb 428 pptp_wan_xmit_ok(ALIGNED_CAST(struct ppp_link *)so->so_tpcb); 431 pptp_wan_input_error(ALIGNED_CAST(struct ppp_link *)so->so_tpcb);
|
/macosx-10.10/ipsec-286.1.1/ipsec-tools/racoon/ |
H A D | pfkey_racoon.c | 217 msg = ALIGNED_CAST(struct sadb_msg *)mhp[0]; // Wcast-align fix (void*) - mhp contains pointers to aligned structs in malloc'd msg buffer 985 msg = ALIGNED_CAST(struct sadb_msg *)mhp[0]; // Wcast-align fix (void*) - mhp contains pointers to aligned structs in malloc'd msg buffer 986 sa = ALIGNED_CAST(struct sadb_sa *)mhp[SADB_EXT_SA]; 987 dst = ALIGNED_CAST(struct sockaddr_storage *)PFKEY_ADDR_SADDR(mhp[SADB_EXT_ADDRESS_SRC]); /* note SA dir */ 1262 msg = ALIGNED_CAST(struct sadb_msg *)mhp[0]; // Wcast-align fix (void*) - mhp contains pointers to aligned structs in malloc'd msg buffer 1263 src = ALIGNED_CAST(struct sockaddr_storage *)PFKEY_ADDR_SADDR(mhp[SADB_EXT_ADDRESS_SRC]); 1264 dst = ALIGNED_CAST(struct sockaddr_storage *)PFKEY_ADDR_SADDR(mhp[SADB_EXT_ADDRESS_DST]); 1265 sa = ALIGNED_CAST(struct sadb_sa *)mhp[SADB_EXT_SA]; 1269 : (ALIGNED_CAST(struct sadb_x_sa2 *)mhp[SADB_X_EXT_SA2])->sadb_x_sa2_mode; 1579 msg = ALIGNED_CAST(struc [all...] |
H A D | crypto_openssl.c | 700 CCHmacUpdate(ALIGNED_CAST(CCHmacContext *)c, data->v, data->l); 712 CCHmacFinal(ALIGNED_CAST(CCHmacContext *)c, res->v); 748 CCHmacUpdate(ALIGNED_CAST(CCHmacContext *)c, data->v, data->l); 760 CCHmacFinal(ALIGNED_CAST(CCHmacContext *)c, res->v); 796 CCHmacUpdate(ALIGNED_CAST(CCHmacContext *)c, data->v, data->l); 808 CCHmacFinal(ALIGNED_CAST(CCHmacContext *)c, res->v); 845 CCHmacUpdate(ALIGNED_CAST(CCHmacContext *)c, data->v, data->l); 857 CCHmacFinal(ALIGNED_CAST(CCHmacContext *)c, res->v); 893 CCHmacUpdate(ALIGNED_CAST(CCHmacContext *)c, data->v, data->l); 905 CCHmacFinal(ALIGNED_CAST(CCHmacContex [all...] |
H A D | var.h | 106 #define ALIGNED_CAST(type) (type)(void *) macro
|
H A D | dnssec.c | 70 id_b = ALIGNED_CAST(struct ipsecdoi_id_b *)id->v;
|
H A D | session.c | 379 msg = ALIGNED_CAST(struct sadb_msg *)buf->v; 380 end = ALIGNED_CAST(struct sadb_msg *)(buf->v + buf->l); 387 next = ALIGNED_CAST(struct sadb_msg *)((caddr_t)msg + PFKEY_UNUNIT64(msg->sadb_msg_len)); // Wcast-align fix (void*) - aligned buffer + multiple of 64 400 sa = ALIGNED_CAST(struct sadb_sa *)(mhp[SADB_EXT_SA]); // Wcast-align fix (void*) - mhp contains pointers to aligned structs
|
H A D | vpn_control.c | 331 struct vpnctl_hdr *hdr = ALIGNED_CAST(struct vpnctl_hdr *)combuf; 337 struct vpnctl_cmd_bind *pkt = ALIGNED_CAST(struct vpnctl_cmd_bind *)combuf; 367 struct vpnctl_cmd_unbind *pkt = ALIGNED_CAST(struct vpnctl_cmd_unbind *)combuf; 388 struct vpnctl_cmd_redirect *redirect_msg = ALIGNED_CAST(struct vpnctl_cmd_redirect *)combuf; 431 struct vpnctl_cmd_xauth_info *pkt = ALIGNED_CAST(struct vpnctl_cmd_xauth_info *)combuf; 451 struct vpnctl_cmd_connect *pkt = ALIGNED_CAST(struct vpnctl_cmd_connect *)combuf; 469 struct vpnctl_cmd_connect *pkt = ALIGNED_CAST(struct vpnctl_cmd_connect *)combuf; 487 struct vpnctl_cmd_start_ph2 *pkt = ALIGNED_CAST(struct vpnctl_cmd_start_ph2 *)combuf; 504 struct vpnctl_cmd_start_dpd *pkt = ALIGNED_CAST(struct vpnctl_cmd_start_dpd *)combuf; 533 struct vpnctl_cmd_assert *pkt = ALIGNED_CAST(struc [all...] |
H A D | isakmp_inf.c | 377 for (pa = ALIGNED_CAST(struct isakmp_parse_t *)pbuf->v; pa->type; pa++) { // Wcast-align fix (void*) - aligned buffer of aligned (unpacked) structs 723 uint32_t *ph2_spi = ALIGNED_CAST(u_int32_t *)(delete + 1); 733 ALIGNED_CAST(u_int32_t *)(delete + 1), num_spi, NULL, NULL); // Wcast-align fix (void*) - delete payload is aligned 1451 msg = ALIGNED_CAST(struct sadb_msg *)buf->v; 1452 end = ALIGNED_CAST(struct sadb_msg *)(buf->v + buf->l); 1457 next = ALIGNED_CAST(struct sadb_msg *)((caddr_t)msg + (msg->sadb_msg_len << 3)); 1470 sa = ALIGNED_CAST(struct sadb_sa *)(mhp[SADB_EXT_SA]); // Wcast-align fix (void*) - buffer of pointers to aligned structs 1477 src = ALIGNED_CAST(struct sockaddr_storage*)PFKEY_ADDR_SADDR(mhp[SADB_EXT_ADDRESS_SRC]); // Wcast-align fix (void*) - buffer of pointers to aligned structs 1478 dst = ALIGNED_CAST(struct sockaddr_storage*)PFKEY_ADDR_SADDR(mhp[SADB_EXT_ADDRESS_DST]); 1479 lt = ALIGNED_CAST(struc [all...] |
H A D | ipsec_doi.c | 1199 struct ipsecdoi_sa_b *sab = ALIGNED_CAST(__typeof__(sab))sa->v; 1241 for (pa = ALIGNED_CAST(struct isakmp_parse_t *)pbuf->v; 1384 for (pa = ALIGNED_CAST(struct isakmp_parse_t *)pbuf->v; 1501 (ALIGNED_CAST(struct ipsecdoi_sa_b *)bp)->doi = htonl(iph1->rmconf->doitype); 1502 (ALIGNED_CAST(struct ipsecdoi_sa_b *)bp)->sit = htonl(iph1->rmconf->sittype); 1723 ld = ntohs(*ALIGNED_CAST(u_int16_t *)buf->v); 1726 ld = ntohl(*ALIGNED_CAST(u_int32_t *)buf->v); 2570 (ALIGNED_CAST(struct ipsecdoi_sa_b *)mysa->v)->doi = htonl(props->rmconf->doitype); 2571 (ALIGNED_CAST(struct ipsecdoi_sa_b *)mysa->v)->sit = htonl(props->rmconf->sittype); 2996 sab = ALIGNED_CAST(struc [all...] |
H A D | isakmp_frag.c | 179 *ALIGNED_CAST(u_int32_t *)vbuf->v = 0; // non-esp marker 212 hp = ALIGNED_CAST(int *)(gen + 1); 507 *ALIGNED_CAST(u_int32_t *)vbuf->v = 0; // non-esp marker
|
H A D | isakmp_ident.c | 308 pa = ALIGNED_CAST(struct isakmp_parse_t *)pbuf->v; 552 for (pa = ALIGNED_CAST(struct isakmp_parse_t *)pbuf->v; 877 for (pa = ALIGNED_CAST(struct isakmp_parse_t *)pbuf->v; 1074 pa = ALIGNED_CAST(struct isakmp_parse_t *)pbuf->v; 1385 for (pa = ALIGNED_CAST(struct isakmp_parse_t *)pbuf->v; 1675 for (pa = ALIGNED_CAST(struct isakmp_parse_t *)pbuf->v;
|
H A D | vpn.c | 307 id_ptr = ALIGNED_CAST(struct id *)new_sainfo->idsrc->v; 318 id_ptr = ALIGNED_CAST(struct id *)new_sainfo->iddst->v;
|
/macosx-10.10/ppp-786.1.1/Drivers/L2TP/L2TP-extension/ |
H A D | l2tp_proto.c | 52 #define ALIGNED_CAST(type) (type)(void *) macro 415 l2tp_wan_detach(ALIGNED_CAST(struct ppp_link *)so->so_tpcb); 444 aligned_data = (ALIGNED_CAST(struct ppp_link *)so->so_tpcb)->lk_index; // Wcast-align fix - we malloc so->so_tpcb - lk_index is u_int16_t being copied to u_int32_t 451 error = l2tp_wan_attach(so->so_pcb, ALIGNED_CAST(struct ppp_link **)&so->so_tpcb); // Wcast-align fix - we malloc so->so_tpcb 457 l2tp_wan_detach(ALIGNED_CAST(struct ppp_link *)so->so_tpcb); // Wcast-align fix - we malloc so->so_tpcb 506 return l2tp_wan_input(ALIGNED_CAST(struct ppp_link *)so->so_tpcb, m); // Wcast-align fix - we malloc so->so_tpcb 539 l2tp_wan_xmit_full(ALIGNED_CAST(struct ppp_link *)so->so_tpcb); // Wcast-align fix - we malloc so->so_tpcb 542 l2tp_wan_xmit_ok(ALIGNED_CAST(struct ppp_link *)so->so_tpcb); 545 l2tp_wan_input_error(ALIGNED_CAST(struct ppp_link *)so->so_tpcb);
|
/macosx-10.10/ipsec-286.1.1/ipsec-tools/setkey/ |
H A D | setkey.c | 500 kdebug_sadb(ALIGNED_CAST(struct sadb_msg *)buf); // Wcast-align fix - aligned message buffer 607 if ((sa = ALIGNED_CAST(struct sadb_sa *)mhp[SADB_EXT_SA]) != NULL) { // Wcast-align (void*) - buffer of pointers to aligned structs in malloc'd buffer 621 msg = ALIGNED_CAST(struct sadb_msg *)((caddr_t)msg + 642 msg = ALIGNED_CAST(struct sadb_msg *)((caddr_t)msg + // Wcast-align fix (void*) - aligned msg buffer passed into function 733 msg = ALIGNED_CAST(struct sadb_msg *)p; 805 if ((sa = ALIGNED_CAST(struct sadb_sa *)mhp[SADB_EXT_SA]) != NULL) { 811 lts = ALIGNED_CAST(struct sadb_lifetime *)mhp[SADB_EXT_LIFETIME_SOFT]; 812 lth = ALIGNED_CAST(struct sadb_lifetime *)mhp[SADB_EXT_LIFETIME_HARD]; 813 ltc = ALIGNED_CAST(struct sadb_lifetime *)mhp[SADB_EXT_LIFETIME_CURRENT]; 836 if ((saddr = ALIGNED_CAST(struc [all...] |
/macosx-10.10/ppp-786.1.1/Drivers/L2TP/L2TP-plugin/ |
H A D | l2tp.c | 258 struct l2tp_header *control_hdr = ALIGNED_CAST(struct l2tp_header *)control_buf; 608 msg_type = ntohs(*(ALIGNED_CAST(u_int16_t *)value_buf)); 638 params->protocol_vers = ntohs(*(ALIGNED_CAST(u_int16_t*)value_buf)); 659 params->firmware_rev = ntohs(*(ALIGNED_CAST(u_int16_t*)value_buf)); 677 if ((params->tunnel_id = ntohs(*(ALIGNED_CAST(u_int16_t*)value_buf))) == 0) { 684 if ((params->window_size = ntohs(*(ALIGNED_CAST(u_int16_t*)value_buf))) == 0) { 690 if ((params->session_id = ntohs(*(ALIGNED_CAST(u_int16_t*)value_buf))) == 0) { 707 params->call_serial_num = ntohl(*(ALIGNED_CAST(u_int32_t*)value_buf)); 803 params->result_code = ntohs(*(ALIGNED_CAST(u_int16_t*)value_buf)); 805 params->error_code = ntohs(*(ALIGNED_CAST(u_int16_ [all...] |
H A D | pfkey.c | 74 #define ALIGNED_CAST(type) (type)(void *) macro 152 if ((ALIGNED_CAST(struct sadb_alg *)p)->sadb_alg_id == alg_id) 153 return ALIGNED_CAST(struct sadb_alg *)p; 780 sup = ALIGNED_CAST(struct sadb_supported *)p; 1751 ext = ALIGNED_CAST(struct sadb_ext *)p; 1829 msg = ALIGNED_CAST(struct sadb_msg *)mhp[0]; 1891 src0 = ALIGNED_CAST(struct sadb_address *)(mhp[SADB_EXT_ADDRESS_SRC]); 1892 dst0 = ALIGNED_CAST(struct sadb_address *)(mhp[SADB_EXT_ADDRESS_DST]); 1940 p = ALIGNED_CAST(struct sadb_msg *)buf; 1973 p = ALIGNED_CAST(struc [all...] |
H A D | main.c | 428 ev_msg = ALIGNED_CAST(struct kern_event_msg *)&buf; 453 && (ALIGNED_CAST(struct sockaddr_in *)ifa->ifa_addr)->sin_addr.s_addr == our_address.sin_addr.s_addr); 716 struct vpnctl_hdr *hdr = ALIGNED_CAST(struct vpnctl_hdr *)data; 717 struct vpnctl_cmd_bind *cmd_bind = ALIGNED_CAST(struct vpnctl_cmd_bind *)data; 718 struct vpnctl_status_failed *failed_status = ALIGNED_CAST(struct vpnctl_status_failed *)data; 809 redirect_addr.sin_addr.s_addr = *ALIGNED_CAST(u_int32_t*)failed_status->data;
|
/macosx-10.10/ppp-786.1.1/Controller/ |
H A D | ipsec_manager.c | 906 cmd_xauth_info = ALIGNED_CAST(struct vpnctl_cmd_xauth_info *)serv->u.ipsec.msg; 923 attr = ALIGNED_CAST(struct isakmp_data *)dataptr; 1128 cmd_bind = ALIGNED_CAST(struct vpnctl_cmd_bind *)serv->u.ipsec.msg; 1135 cmd_xauth_info = ALIGNED_CAST(struct vpnctl_cmd_xauth_info *)serv->u.ipsec.msg; 1142 failed_status = ALIGNED_CAST(struct vpnctl_status_failed *)serv->u.ipsec.msg; 1151 addr.s_addr = *ALIGNED_CAST(u_int32_t*)failed_status->data; 1165 phase_change_status = ALIGNED_CAST(struct vpnctl_status_phase_change *)serv->u.ipsec.msg; 1171 struct vpnctl_modecfg_params *modecfg = ALIGNED_CAST(struct vpnctl_modecfg_params *)(void*)(serv->u.ipsec.msg + sizeof(struct vpnctl_status_phase_change)); 1219 cmd_xauth_info = ALIGNED_CAST(struct vpnctl_cmd_xauth_info *)serv->u.ipsec.msg; 1268 peer_resp = ALIGNED_CAST(__typeof_ [all...] |
H A D | ppp_socket_server.c | 408 processRequest(client, ALIGNED_CAST(struct msg *)client->msg); 752 notification = *ALIGNED_CAST(u_int32_t *)&msg->data[MSG_DATAOFF(msg)]; 795 notification = *ALIGNED_CAST(u_int32_t *)&msg->data[MSG_DATAOFF(msg)]; 882 index = *ALIGNED_CAST(u_int32_t *)&msg->data[0]; 1188 struct ppp_opt *opt = ALIGNED_CAST(struct ppp_opt *)&msg->data[MSG_DATAOFF(msg)]; 1189 u_int32_t optint = *ALIGNED_CAST(u_int32_t *)(&opt->o_data[0]); 1306 err = set_long_opt(opts, kSCEntNetPPP, kSCPropNetPPPLCPEchoInterval, (ALIGNED_CAST(struct ppp_opt_echo *)opt->o_data)->interval, 0, 0xFFFFFFFF, 1) 1307 || set_long_opt(opts, kSCEntNetPPP, kSCPropNetPPPLCPEchoFailure, (ALIGNED_CAST(struct ppp_opt_echo *)opt->o_data)->failure, 0, 0xFFFFFFFF, 1); 1385 struct ppp_opt *opt = ALIGNED_CAST(struct ppp_opt *)&msg->data[MSG_DATAOFF(msg)]; 1444 *ALIGNED_CAST(u_int32_ [all...] |
/macosx-10.10/ipsec-286.1.1/ipsec-tools/libipsec/ |
H A D | policy_parse.y | 511 p = ALIGNED_CAST(struct sadb_x_policy *)pbuf; 555 p = ALIGNED_CAST(struct sadb_x_ipsecrequest *)&pbuf[offset]; // Wcast-align fix - malloc'd buffer/offset 64 bit multiple 634 (ALIGNED_CAST(struct sadb_x_policy *)pbuf)->sadb_x_policy_len = PFKEY_UNIT64(tlen);
|
/macosx-10.10/ppp-786.1.1/Helpers/pppd/ |
H A D | sys-MacOSX.c | 1043 hdr = ALIGNED_CAST(struct ppp_msg_hdr *)p; 2193 (ALIGNED_CAST(struct sockaddr_in *) &ifra.ifra_addr)->sin_addr.s_addr = o; 2195 (ALIGNED_CAST(struct sockaddr_in *) &ifra.ifra_broadaddr)->sin_addr.s_addr = h; 2198 (ALIGNED_CAST(struct sockaddr_in *) &ifra.ifra_mask)->sin_addr.s_addr = m; 2257 (ALIGNED_CAST(struct sockaddr_in *) &ifra.ifra_addr)->sin_addr.s_addr = o; 2259 (ALIGNED_CAST(struct sockaddr_in *) &ifra.ifra_broadaddr)->sin_addr.s_addr = h; 2262 (ALIGNED_CAST(struct sockaddr_in *) &ifra.ifra_mask)->sin_addr.s_addr = m; 2306 (ALIGNED_CAST(struct sockaddr_in *) &ifra.ifra_addr)->sin_addr.s_addr = o; 2308 (ALIGNED_CAST(struct sockaddr_in *) &ifra.ifra_broadaddr)->sin_addr.s_addr = h; 2380 *ALIGNED_CAST(u_int16_ [all...] |
H A D | acsp.c | 235 acsp_packet *pkt = ALIGNED_CAST(acsp_packet*)packet; 298 *(ALIGNED_CAST(u_int16_t*)ptr) = htons(PPP_ACSP); 305 ext->last_seq = (ALIGNED_CAST(acsp_packet*)ptr)->seq; 1073 pkt = ALIGNED_CAST(acsp_packet*)(context->buf + 4); // leave space for address, control, and protocol 1090 route_data = ALIGNED_CAST(acsp_route_data*)pkt->data; 1146 outPkt = ALIGNED_CAST(acsp_packet*)(context->buf + 4); // leave space for address, control, and protocol 1181 route_data = ALIGNED_CAST(acsp_route_data*)pkt->data; 1534 sum += *(ALIGNED_CAST(unsigned short *)data); 1772 dp = ALIGNED_CAST(struct dhcp_packet *)pkt; 1977 dp = ALIGNED_CAST(struc [all...] |
/macosx-10.10/ipsec-286.1.1/ipsec-tools/Common/ |
H A D | key_debug.c | 446 struct sadb_session_id *p = ALIGNED_CAST(__typeof__(p))ext; // Wcast-align fix (void*) - sadb structs come from and aligned buffer 462 struct sadb_x_ipsecif *p = ALIGNED_CAST(__typeof__(p))ext; 477 struct sadb_sastat *p = ALIGNED_CAST(__typeof__(p))ext; // Wcast-align fix (void*) - sadb structs come from and aligned buffer
|
/macosx-10.10/ppp-786.1.1/Family/ |
H A D | slcompress.c | 92 #define ALIGNED_CAST(type) (type)(void *) macro 563 th = ALIGNED_CAST(struct tcphdr *)&((u_char *)&cs->cs_ip)[hlen];
|
/macosx-10.10/ppp-786.1.1/Drivers/PPTP/PPTP-plugin/ |
H A D | main.c | 383 ev_msg = ALIGNED_CAST(struct kern_event_msg *) &buf; 410 && (ALIGNED_CAST(struct sockaddr_in *)ifa->ifa_addr)->sin_addr.s_addr == ouraddress.sin_addr.s_addr); 540 peeraddress = *ALIGNED_CAST(struct in_addr*)host->h_addr_list[rd8 % count]; 546 alt_peer_address[num_alt_peer_address] = *ALIGNED_CAST(struct in_addr*)host->h_addr_list[(rd8 + num_alt_peer_address + 1)% count]; 1430 ifm = ALIGNED_CAST(struct if_msghdr *)buf;
|