Module Expr Str Import alias Import alias Import alias Import alias Import alias ImportFrom alias ImportFrom alias identifier ImportFrom alias ImportFrom alias ImportFrom alias ImportFrom alias ImportFrom alias identifier Assign NameStore Call AttributeLoad NameLoad attr Str AttributeLoad NameLoad attr Assign NameStore ListLoad Str Str Str ClassDef bases AttributeLoad NameLoad attr body Expr Str FunctionDef arguments args NameParam NameParam defaults body Expr Str Expr Call AttributeLoad Call NameLoad NameLoad NameLoad attr NameLoad Assign AttributeStore AttributeLoad NameLoad attr attr Str Expr Call AttributeLoad NameLoad attr Assign AttributeStore NameLoad attr AttributeStore NameLoad attr AttributeStore NameLoad attr AttributeStore NameLoad attr NameLoad Assign AttributeStore NameLoad attr AttributeStore NameLoad attr AttributeStore NameLoad attr NameLoad decorator_list FunctionDef arguments args NameParam defaults body Expr Str Assign NameStore Call AttributeLoad NameLoad attr Assign AttributeStore NameLoad attr AttributeLoad NameLoad attr Assign AttributeStore NameLoad attr AttributeLoad NameLoad attr Expr Call AttributeLoad Call AttributeLoad NameLoad attr Str NameLoad attr Expr Call AttributeLoad Call AttributeLoad NameLoad attr Str NameLoad attr Expr Call AttributeLoad Call AttributeLoad NameLoad attr Str NameLoad attr Expr Call AttributeLoad Call AttributeLoad NameLoad attr Str NameLoad attr Assign NameStore Call AttributeLoad NameLoad attr Str Assign NameStore Call AttributeLoad NameLoad attr Assign AttributeStore NameLoad attr Call AttributeLoad NameLoad attr Str decorator_list FunctionDef arguments args NameParam NameParam defaults vararg kwarg body Expr Str If Call NameLoad NameLoad body Assign NameStore Call NameLoad NameLoad Return Call AttributeLoad Call NameLoad NameLoad NameLoad attr NameLoad NameLoad NameLoad orelse Return Call AttributeLoad NameLoad attr NameLoad NameLoad NameLoad decorator_list FunctionDef arguments args NameParam NameParam defaults vararg kwarg body Expr Str If Call NameLoad NameLoad body Assign NameStore Call NameLoad NameLoad Return Call AttributeLoad Call NameLoad NameLoad NameLoad attr NameLoad NameLoad NameLoad orelse Return Call AttributeLoad NameLoad attr NameLoad NameLoad NameLoad decorator_list FunctionDef arguments args NameParam NameParam defaults body Expr Str Assign NameStore Call NameLoad AttributeLoad NameLoad attr NameLoad NameLoad If Call NameLoad NameLoad body Return NameLoad orelse Raise Call NameLoad decorator_list FunctionDef arguments args NameParam defaults body Expr Str If Call NameLoad AttributeLoad NameLoad attr Str body TryExcept body Expr Call AttributeLoad NameLoad attr ListLoad AttributeLoad AttributeLoad NameLoad attr attr Str handlers ExceptHandler type AttributeLoad NameLoad attr body Raise Call AttributeLoad NameLoad attr Str Assign NameStore Call AttributeLoad Call NameLoad NameLoad NameLoad attr Assign AttributeStore NameLoad attr Call NameLoad NameLoad Assign AttributeStore NameLoad attr Call NameLoad NameLoad Assign TupleStore AttributeStore NameLoad attr AttributeStore NameLoad attr Call NameLoad NameLoad Assign NameStore Call NameLoad NameLoad With Call NameLoad Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad Str NameStore body Assign NameStore Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad Call AttributeLoad Call AttributeLoad NameLoad attr attr Assign AttributeStore NameLoad attr Call NameLoad NameLoad NameLoad Expr Call AttributeLoad NameLoad attr NameLoad Expr Call AttributeLoad NameLoad attr NameLoad NameLoad TryExcept body Expr Call AttributeLoad NameLoad attr Call AttributeLoad Str attr NameLoad NameLoad handlers ExceptHandler type AttributeLoad NameLoad attr body Raise Call AttributeLoad NameLoad attr Call AttributeLoad Str attr NameLoad Return NameLoad decorator_list FunctionDef arguments args NameParam NameParam defaults body Expr Str Assign NameStore Call AttributeLoad NameLoad attr ListLoad Str NameLoad Str Str keyword AttributeLoad NameLoad attr Expr Call AttributeLoad NameLoad attr ListLoad Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str keyword AttributeLoad NameLoad attr decorator_list FunctionDef arguments args NameParam NameParam NameParam defaults body Expr Str Assign AttributeStore AttributeLoad NameLoad attr attr NameLoad Assign AttributeStore AttributeLoad NameLoad attr attr Call AttributeLoad Str attr NameLoad NameLoad Assign AttributeStore AttributeLoad NameLoad attr attr Call AttributeLoad Str attr NameLoad Assign AttributeStore AttributeLoad NameLoad attr attr Call AttributeLoad Str attr NameLoad Assign AttributeStore AttributeLoad NameLoad attr attr BinOpAdd AttributeLoad AttributeLoad NameLoad attr attr Str Assign AttributeStore NameLoad attr Call AttributeLoad NameLoad attr keyword Call AttributeLoad NameLoad attr AttributeLoad NameLoad attr keyword Str Expr Call AttributeLoad AttributeLoad NameLoad attr attr decorator_list FunctionDef arguments args NameParam defaults body Expr Str Expr Call AttributeLoad Call NameLoad NameLoad NameLoad attr Expr Call AttributeLoad AttributeLoad NameLoad attr attr decorator_list FunctionDef arguments args NameParam defaults body Expr Str If AttributeLoad NameLoad attr body Return AttributeLoad NameLoad attr orelse Raise Call AttributeLoad NameLoad attr Str decorator_list FunctionDef arguments args NameParam defaults body Expr Str If AttributeLoad NameLoad attr body Return AttributeLoad NameLoad attr orelse Return Set Str decorator_list FunctionDef arguments args NameParam NameParam NameParam NameParam NameParam NameParam defaults NameLoad NameLoad body Expr Str Assign TupleStore NameStore NameStore NameStore Call AttributeLoad NameLoad attr NameLoad NameLoad NameLoad Expr Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad NameLoad NameLoad NameLoad NameLoad decorator_list decorator_list Call AttributeLoad AttributeLoad NameLoad attr attr AttributeLoad NameLoad attr FunctionDef arguments args NameParam defaults body Expr Str If Call NameLoad NameLoad NameLoad body Assign NameStore SubscriptLoad NameLoad Index Num For NameStore NameLoad body If Call AttributeLoad NameLoad attr NameLoad body Return NameLoad Return NameLoad decorator_list FunctionDef arguments args NameParam defaults body Expr Str If Call NameLoad NameLoad NameLoad body For NameStore Call NameLoad Call NameLoad NameLoad body If CompareEq SubscriptLoad NameLoad Index NameLoad Str body Assign SubscriptStore NameLoad Index NameLoad Str orelse Assign NameStore Call AttributeLoad NameLoad attr Str Str Return NameLoad decorator_list FunctionDef arguments args NameParam NameParam defaults body Expr Str Assign NameStore Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad Str Expr Call AttributeLoad Call NameLoad NameLoad Str attr Expr Call AttributeLoad NameLoad attr ListLoad Str Str Str NameLoad Return NameLoad decorator_list FunctionDef arguments args NameParam defaults body Expr Str Assign NameStore ListComp NameLoad comprehension NameStore Call AttributeLoad NameLoad attr NameLoad Call AttributeLoad AttributeLoad NameLoad attr attr Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad NameLoad If CompareNotEq Call NameLoad NameLoad Num body Expr Call AttributeLoad NameLoad attr Call AttributeLoad Str attr NameLoad Return Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad Call AttributeLoad SubscriptLoad NameLoad Index Num attr decorator_list FunctionDef arguments args NameParam defaults body Expr Str Assign NameStore Call NameLoad Assign NameStore Call NameLoad With Call NameLoad Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad Str NameStore body For NameStore NameLoad body If Call AttributeLoad SubscriptLoad NameLoad Index Num attr body Assign NameStore Call AttributeLoad NameLoad attr If CompareEq SubscriptLoad NameLoad Index Num Str body Expr Call AttributeLoad NameLoad attr SubscriptLoad NameLoad Index Num Expr Call AttributeLoad NameLoad attr SubscriptLoad NameLoad Index Num orelse If BoolOpAnd CompareEq SubscriptLoad NameLoad Index Num Str UnaryOpNot Call AttributeLoad AttributeLoad NameLoad attr attr SubscriptLoad NameLoad Index Num body Expr Call AttributeLoad NameLoad attr SubscriptLoad NameLoad Index Num Expr Call AttributeLoad NameLoad attr SubscriptLoad NameLoad Index Num orelse If CompareNotIn Str NameLoad body Assign NameStore Call AttributeLoad NameLoad attr If BoolOpOr Call AttributeLoad SubscriptLoad NameLoad Index Num attr Str BoolOpAnd Call AttributeLoad SubscriptLoad NameLoad Index Num attr Str UnaryOpNot Call AttributeLoad AttributeLoad NameLoad attr attr SubscriptLoad NameLoad Index Num CompareNotEq Call AttributeLoad SubscriptLoad NameLoad Index Num attr Str Num body Expr Call AttributeLoad NameLoad attr SubscriptLoad NameLoad Index Num Return TupleLoad NameLoad NameLoad decorator_list FunctionDef arguments args NameParam defaults body Expr Str Assign NameStore ListLoad With Call NameLoad Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad Str NameStore body For NameStore NameLoad body If Call AttributeLoad SubscriptLoad NameLoad Index Num attr body Assign NameStore Call AttributeLoad NameLoad attr Expr Call AttributeLoad NameLoad attr SubscriptLoad SubscriptLoad NameLoad Index Num Slice Num Return NameLoad decorator_list FunctionDef arguments args NameParam defaults body Expr Str With Call NameLoad Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad Str NameStore body Assign NameStore Call AttributeLoad NameLoad attr Call AttributeLoad NameLoad attr If CompareNotEq Call NameLoad NameLoad Num body Raise Call AttributeLoad NameLoad attr Str Return Call NameLoad ListComp Call NameLoad NameLoad comprehension NameStore Call AttributeLoad SubscriptLoad NameLoad Index Num attr Str decorator_list
N/A N/A Provides a common base for Apache proxies N/A re N/A os N/A subprocess N/A mock N/A zope.interface certbot configuration certbot errors le_errors certbot_apache configurator certbot_compatibility_test errors certbot_compatibility_test interfaces certbot_compatibility_test util certbot_compatibility_test.configurators common configurators_common N/A APACHE_VERSION_REGEX N/A N/A re compile Apache/([0-9\.]*) N/A re IGNORECASE N/A APACHE_COMMANDS N/A apachectl a2enmod a2dismod Proxy N/A N/A configurators_common Proxy N/A N/A A common base for Apache test configurators __init__ N/A N/A self args N/A N/A N/A Initializes the plugin with the given command line args N/A N/A N/A N/A super Proxy self __init__ args N/A N/A N/A self le_config apache_le_vhost_ext -le-ssl.conf N/A N/A N/A self _setup_mock N/A N/A self modules N/A self server_root N/A self test_conf N/A self version None N/A N/A self _apache_configurator N/A self _all_names N/A self _test_names None N/A _setup_mock N/A N/A self N/A N/A N/A Replaces specific modules with mock.MagicMock N/A mock_subprocess N/A N/A mock MagicMock N/A N/A mock_subprocess check_call N/A self check_call N/A N/A mock_subprocess Popen N/A self popen N/A N/A N/A N/A N/A mock patch certbot_apache.configurator.subprocess mock_subprocess start N/A N/A N/A N/A N/A mock patch certbot_apache.parser.subprocess mock_subprocess start N/A N/A N/A N/A N/A mock patch certbot.le_util.subprocess mock_subprocess start N/A N/A N/A N/A N/A mock patch certbot_apache.configurator.le_util.exe_exists _is_apache_command start N/A patch N/A N/A mock patch certbot_apache.configurator.display_ops.select_vhost N/A mock_display N/A N/A patch start N/A N/A mock_display side_effect N/A N/A le_errors PluginError Unable to determine vhost N/A check_call N/A N/A self command N/A args kwargs N/A N/A If command is an Apache command, command is executed in the
        running docker image. Otherwise, subprocess.check_call is used.

         N/A N/A _is_apache_command command N/A N/A command N/A _modify_command command N/A N/A N/A N/A super Proxy self check_call command args kwargs N/A N/A N/A N/A subprocess check_call command args kwargs N/A popen N/A N/A self command N/A args kwargs N/A N/A If command is an Apache command, command is executed in the
        running docker image. Otherwise, subprocess.Popen is used.

         N/A N/A _is_apache_command command N/A N/A command N/A _modify_command command N/A N/A N/A N/A super Proxy self popen command args kwargs N/A N/A N/A N/A subprocess Popen command args kwargs N/A __getattr__ N/A N/A self name N/A N/A N/A Wraps the Apache Configurator methods N/A method N/A getattr N/A self _apache_configurator name None N/A N/A callable method N/A N/A method N/A N/A N/A AttributeError N/A load_config N/A N/A self N/A N/A N/A Loads the next configuration for the plugin to test N/A N/A hasattr N/A self le_config apache_init_script N/A N/A N/A N/A N/A N/A self check_call N/A N/A N/A self le_config apache_init_script stop N/A N/A N/A N/A errors Error N/A N/A N/A N/A errors Error Failed to stop previous apache config from running N/A config N/A N/A N/A super Proxy self load_config N/A N/A self modules N/A _get_modules config N/A N/A self version N/A _get_version config N/A N/A N/A self _all_names N/A self _test_names N/A _get_names config N/A server_root N/A _get_server_root config N/A N/A open N/A N/A N/A os path join config config_file f N/A N/A config_file N/A N/A N/A os path join server_root N/A N/A N/A N/A f readline rstrip N/A N/A self test_conf N/A _create_test_conf server_root config_file N/A N/A N/A self preprocess_config server_root N/A N/A N/A self _prepare_configurator server_root config_file N/A N/A N/A N/A N/A self check_call N/A N/A apachectl -d {0} -f {1} -k start format server_root config_file N/A N/A N/A N/A errors Error N/A N/A N/A N/A errors Error N/A N/A Apache failed to load {0} before tests started format config N/A config N/A preprocess_config N/A N/A self server_root N/A N/A N/A Prepares the configuration for use in the Docker N/A find N/A N/A subprocess Popen N/A find server_root -type f stdout N/A subprocess PIPE N/A N/A N/A subprocess check_call N/A xargs sed -e s/DocumentRoot.*/DocumentRoot \/usr\/local\/apache2\/htdocs/I -e s/SSLPassPhraseDialog.*/SSLPassPhraseDialog builtin/I -e s/TypesConfig.*/TypesConfig \/usr\/local\/apache2\/conf\/mime.types/I -e s/LoadModule/#LoadModule/I -e s/SSLCertificateFile.*/SSLCertificateFile \/usr\/local\/apache2\/conf\/empty_cert.pem/I -e s/SSLCertificateKeyFile.*/SSLCertificateKeyFile \/usr\/local\/apache2\/conf\/rsa1024_key2.pem/I -i stdin N/A find stdout N/A _prepare_configurator N/A N/A self server_root config_file N/A N/A N/A Prepares the Apache plugin for testing N/A N/A N/A self le_config apache_server_root server_root N/A N/A N/A self le_config apache_ctl N/A N/A apachectl -d {0} -f {1} format server_root config_file N/A N/A N/A self le_config apache_enmod N/A N/A a2enmod.sh {0} format server_root N/A N/A N/A self le_config apache_dismod N/A N/A a2dismod.sh {0} format server_root N/A N/A N/A self le_config apache_init_script N/A N/A N/A self le_config apache_ctl  -k N/A N/A self _apache_configurator N/A N/A configurator ApacheConfigurator config N/A N/A configuration NamespaceConfig N/A self le_config name apache N/A N/A N/A N/A self _apache_configurator prepare N/A cleanup_from_tests N/A N/A self N/A N/A N/A Performs any necessary cleanup from running plugin tests N/A N/A N/A N/A super Proxy self cleanup_from_tests N/A N/A N/A N/A mock patch stopall N/A get_all_names_answer N/A N/A self N/A N/A N/A Returns the set of domain names that the plugin should find N/A N/A self _all_names N/A N/A N/A self _all_names N/A N/A N/A N/A errors Error No configuration file loaded N/A get_testable_domain_names N/A N/A self N/A N/A N/A Returns the set of domain names that can be tested against N/A N/A self _test_names N/A N/A N/A self _test_names N/A N/A N/A example.com N/A deploy_cert N/A N/A self domain cert_path key_path chain_path fullchain_path N/A None None N/A N/A Installs cert N/A N/A cert_path key_path chain_path N/A N/A self copy_certs_and_keys cert_path key_path chain_path N/A N/A N/A N/A self _apache_configurator deploy_cert domain cert_path key_path chain_path fullchain_path N/A N/A N/A N/A N/A zope interface implementer N/A interfaces IConfiguratorProxy _is_apache_command N/A N/A command N/A N/A N/A Returns true if command is an Apache command N/A N/A isinstance command list N/A N/A command N/A command N/A 0 N/A apache_command APACHE_COMMANDS N/A N/A N/A N/A command startswith apache_command N/A N/A True N/A False N/A _modify_command N/A N/A command N/A N/A N/A Modifies command so configtest works inside the docker image N/A N/A isinstance command list N/A N/A i N/A xrange N/A len command N/A N/A N/A N/A command N/A i configtest N/A N/A N/A command N/A i -t N/A N/A command N/A N/A command replace configtest -t N/A command N/A _create_test_conf N/A N/A server_root apache_config N/A N/A N/A Creates a test config file and adds it to the Apache config N/A test_conf N/A N/A N/A os path join server_root test.conf N/A N/A N/A N/A open test_conf w close N/A N/A N/A subprocess check_call N/A sed -i 1iInclude test.conf apache_config N/A test_conf N/A _get_server_root N/A N/A config N/A N/A N/A Returns the server root directory in config N/A subdirs N/A name N/A name N/A N/A os listdir config N/A N/A N/A os path isdir N/A N/A N/A os path join config name N/A N/A N/A len subdirs 1 N/A N/A N/A N/A errors Error N/A N/A Malformed configuration directiory {0} format config N/A N/A N/A N/A os path join config N/A N/A N/A subdirs N/A 0 rstrip N/A _get_names N/A N/A config N/A N/A N/A Returns all and testable domain names in config N/A all_names N/A set N/A non_ip_names N/A set N/A N/A open N/A N/A N/A os path join config vhosts f N/A N/A line f N/A N/A N/A N/A N/A line N/A 0 isspace N/A N/A words N/A N/A line split N/A N/A N/A words N/A 0 alias N/A N/A N/A N/A all_names add N/A words N/A 1 N/A N/A N/A non_ip_names add N/A words N/A 1 N/A N/A N/A N/A N/A words N/A 1 80 N/A N/A N/A N/A util IP_REGEX match N/A words N/A 3 N/A N/A N/A N/A all_names add N/A words N/A 3 N/A N/A N/A non_ip_names add N/A words N/A 3 N/A N/A N/A NameVirtualHost line N/A N/A words N/A N/A line split N/A N/A N/A N/A N/A words N/A 0 endswith * N/A N/A N/A N/A words N/A 0 endswith 80 N/A N/A N/A N/A util IP_REGEX match N/A words N/A 1 N/A N/A N/A N/A words N/A 1 find . -1 N/A N/A N/A N/A all_names add N/A words N/A 1 N/A N/A all_names non_ip_names N/A _get_modules N/A N/A config N/A N/A N/A Returns the list of modules found in module_list N/A modules N/A N/A N/A open N/A N/A N/A os path join config modules f N/A N/A line f N/A N/A N/A N/A N/A line N/A 0 isspace N/A N/A words N/A N/A line split N/A N/A N/A modules append N/A N/A words N/A 0 N/A -7 N/A modules N/A _get_version N/A N/A config N/A N/A N/A Return version of Apache Server.

    Version is returned as tuple. (ie. 2.4.7 = (2, 4, 7)). Code taken from
    the Apache plugin.

     N/A N/A open N/A N/A N/A os path join config version f N/A N/A matches N/A N/A APACHE_VERSION_REGEX findall N/A N/A f readline N/A N/A N/A len matches 1 N/A N/A N/A N/A errors Error Unable to find Apache version N/A N/A tuple N/A N/A int i N/A i N/A N/A N/A matches N/A 0 split . N/A