%PDF- %PDF-
| Direktori : /lib/python3/dist-packages/samba/__pycache__/ |
| Current File : //lib/python3/dist-packages/samba/__pycache__/remove_dc.cpython-312.pyc |
�
�I�dI � �� � d dl Z d dlZd dlmZ d dlmZ d dlmZ d dlmZm Z d dl
mZmZm
Z
mZmZmZ G d� de� Zd � Zdd
�Zd� Z dd�Z dd
�Zd� Zd� Zy)� N)�LdbError)�werror)�
ndr_unpack)�misc�dnsp)�DNS_TYPE_NS�
DNS_TYPE_A�
DNS_TYPE_AAAA�DNS_TYPE_CNAME�DNS_TYPE_SRV�DNS_TYPE_PTRc � � e Zd ZdZd� Zd� Zy)�DemoteExceptionzBase element for demote errorsc � � || _ y �N��value)�selfr s �1/usr/lib/python3/dist-packages/samba/remove_dc.py�__init__zDemoteException.__init__ s � ���
� c � � d| j z S )NzDemoteException: r )r s r �__str__zDemoteException.__str__# s � �"�T�Z�Z�/�/r N)�__name__�
__module__�__qualname__�__doc__r r � r r r r s � �(��0r r c �� � | j � }dd|z fD ]� }t j | |� } |j | j � � |j d� |j dd|� |j d |z � | j |� �� d
D ]� }t j | |� } |j | j � � |j d� |j dd|� |j d |z � | j |� �� y # t j
$ r t
d|�d| j � ��� �w xY w# t j
$ r t
d|z � �w xY w# t j
$ r/}|j \ }}|t j k( rn� Y d }~���d }~ww xY w# t j
$ r t
d|�d| j � ��� �w xY w# t j
$ r t
d|�d|�d�� �w xY w# t j
$ r/} | j \ }}|t j k( rn� Y d } ~ ���d } ~ ww xY w)
Nz3CN=Enterprise,CN=Microsoft System Volumes,CN=Systemz+CN=%s,CN=Microsoft System Volumes,CN=SystemzFailed constructing DN z by adding base zCN=Xz.Failed constructing DN %s by adding child CN=Xr �CNzRemoving Sysvol reference: %s)zMCN=Domain System Volumes (SYSVOL share),CN=File Replication Service,CN=SystemzDCN=Topology,CN=Domain System Volume,CN=DFSR-GlobalSettings,CN=Systemz% by adding child CN=X (soon to be CN=�))�domain_dns_name�ldb�Dn�add_base�get_config_basednr r � add_child�
set_component�info�delete�args�ERR_NO_SUCH_OBJECT�get_default_basedn)
�samdb�logger�dc_name�realm�s�dn�e�enum�estr�e1s
r �remove_sysvol_referencesr8 '