From cc7f1f6761b4432fb074ea4b937cb0fcf4eefa4e Mon Sep 17 00:00:00 2001 From: Santiago Alessandri Date: Mon, 15 Aug 2011 20:08:23 -0300 Subject: [PATCH] Added license to some files. --- include/arp.h | 22 ++++++++++++++++++++++ include/icmp.h | 21 +++++++++++++++++++++ src/arp.cpp | 23 +++++++++++++++++++++++ src/icmp.cpp | 22 ++++++++++++++++++++++ 4 files changed, 88 insertions(+) diff --git a/include/arp.h b/include/arp.h index b265765..dacb152 100644 --- a/include/arp.h +++ b/include/arp.h @@ -1,3 +1,25 @@ +/* + * libtins is a net packet wrapper library for crafting and + * interpreting sniffed packets. + * + * Copyright (C) 2011 Nasel + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public + * License as published by the Free Software Foundation; either + * version 2.1 of the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA + */ + + #ifndef __ARP_H #define __ARP_H diff --git a/include/icmp.h b/include/icmp.h index 0421735..566a9d1 100644 --- a/include/icmp.h +++ b/include/icmp.h @@ -1,3 +1,24 @@ +/* + * libtins is a net packet wrapper library for crafting and + * interpreting sniffed packets. + * + * Copyright (C) 2011 Nasel + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public + * License as published by the Free Software Foundation; either + * version 2.1 of the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA + */ + #ifndef __ICMP_H #define __ICMP_H diff --git a/src/arp.cpp b/src/arp.cpp index 945d0ee..b5ef713 100644 --- a/src/arp.cpp +++ b/src/arp.cpp @@ -1,3 +1,25 @@ +/* + * libtins is a net packet wrapper library for crafting and + * interpreting sniffed packets. + * + * Copyright (C) 2011 Nasel + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public + * License as published by the Free Software Foundation; either + * version 2.1 of the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA + */ + + #include #include #include @@ -18,6 +40,7 @@ Tins::ARP::ARP() : PDU(0x0608) { void Tins::ARP::set_arp_request(const string &ip_dst, const string &ip_src, const string &hw_src) { _arp.ar_tip = Utils::resolve_ip(ip_dst); _arp.ar_sip = Utils::resolve_ip(ip_src); + _arp.ar_op = REQUEST; } uint32_t Tins::ARP::header_size() const { diff --git a/src/icmp.cpp b/src/icmp.cpp index 1aeec42..c691008 100644 --- a/src/icmp.cpp +++ b/src/icmp.cpp @@ -1,3 +1,25 @@ +/* + * libtins is a net packet wrapper library for crafting and + * interpreting sniffed packets. + * + * Copyright (C) 2011 Nasel + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public + * License as published by the Free Software Foundation; either + * version 2.1 of the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA + */ + + #ifndef WIN32 #include #endif