Coverage for /root/GitHubProjects/impacket/impacket/__init__.py : 56%

Hot-keys on this page
r m x p toggle line displays
j k next/prev highlighted chunk
0 (zero) top of page
1 (one) first highlighted chunk
1# Copyright (c) 2003-2016 CORE Security Technologies
2#
3# This software is provided under under a slightly modified version
4# of the Apache Software License. See the accompanying LICENSE file
5# for more information.
6#
7# Author: Alberto Solino (@agsolino)
8#
10# Set default logging handler to avoid "No handler found" warnings.
11import logging
12try: # Python 2.7+
13 from logging import NullHandler
14except ImportError:
15 class NullHandler(logging.Handler):
16 def emit(self, record):
17 pass
19# All modules inside this library MUST use this logger (impacket)
20# It is up to the library consumer to do whatever is wanted
21# with the logger output. By default it is forwarded to the
22# upstream logger
24LOG = logging.getLogger(__name__)
25LOG.addHandler(NullHandler())