-
-
Notifications
You must be signed in to change notification settings - Fork 2k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #296 from p-l-/fix-circular-imports
Arch: move constant values to a new submodule
- Loading branch information
Showing
8 changed files
with
36 additions
and
34 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
## This file is part of Scapy | ||
## See http://www.secdev.org/projects/scapy for more informations | ||
## Copyright (C) Philippe Biondi <phil@secdev.org> | ||
## This program is published under a GPLv2 license | ||
|
||
import os | ||
from sys import platform | ||
|
||
LINUX = platform.startswith("linux") | ||
OPENBSD = platform.startswith("openbsd") | ||
FREEBSD = "freebsd" in platform | ||
NETBSD = platform.startswith("netbsd") | ||
DARWIN = platform.startswith("darwin") | ||
SOLARIS = platform.startswith("sunos") | ||
WINDOWS = platform.startswith("win32") | ||
BSD = DARWIN or FREEBSD or OPENBSD or NETBSD | ||
|
||
if WINDOWS: | ||
X86_64 = False | ||
ARM_64 = False | ||
else: | ||
uname = os.uname() | ||
X86_64 = uname[4] == 'x86_64' | ||
ARM_64 = uname[4] == 'aarch64' | ||
|
||
LOOPBACK_NAME = "lo" if LINUX else "lo0" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -11,6 +11,4 @@ | |
import socket | ||
socket.IPPROTO_GRE = 47 | ||
|
||
LOOPBACK_NAME="lo0" | ||
|
||
from scapy.arch.unix import * |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters