Конфигурационный файл Wicd: как прочитать пароль?

GRUB2 в Debian 9 определенно может читать из обычного («линейного» )тома LVM2 на метаданных MD raid1 (v1.2 ). Однако я обнаружил, что это работает только в том случае, если вы делаетеinsmod lvmдоinsmod mdraid1x.

Если я загружу их в обратном порядке, изменится порядок устройств, показанных командой GRUB ls(! ), но не добавляет устройства lvm в список.

Стандартная автоматическая конфигурация

Чтобы получить grub-mkconfig(, который является серверной частью Debianupdate-grub)для обнаружения второго экземпляра Linux, как это предлагается на вики-странице RAID, достаточно было установить пакет os-prober. (Я полагаю, что программа установки Debian установила бы этот пакет автоматически, если бы увидела вторую ОС при первоначальной установке загрузчика. Особенно если была установка Windows ).

Интересно, что сгенерированный конфиг загружалсяlvmпослеmdraid1x. Однако он также загружал diskfilterдо mdraid1x. Он также использовал скрытый путь lvmid/...вместо (lvm/...). Ради нашего здравомыслия давайте проигнорируем последнее различие и представим, что ранняя загрузка diskfilter, вероятно, позволяет этой конфигурации работать :).

Я не уверен, где вы должны изучить любой из этих методов :-/.

5
26.12.2019, 08:29
1 ответ

Диспетчер сетевых подключений Wicd хранит свои файлы конфигурации в /etc/wicd/, пароль ключа Wi-Fi хранится в wireless-settings.conf, но более новая версия Wicd скрывает файлы конфигурации.

Используемый каталог: (это может варьироваться от дистрибутива к другому):

  • /usr/lib/wicd/для библиотек
  • /usr/share/wicd/для общей конфигурации
  • /etc/wicd/для основного конфига
  • /var/lib/wicd/
  • $HOME/.wicd/
  • и т. д.

Следующая часть кода изwicd-daemon.pyскрывает ключи файла конфигурации (и т. д. ), предоставляя им код разрешения 0600, что означает, что только владелец файла может читать/записывать файлы, root может видеть файлы, если демон запускается от имени пользователя root, в противном случае, если демон запускается от имени другого пользователя (wicd или еще )только этот пользователь может видеть файлы...

    # Hide the files, so the keys aren't exposed.
    print("chmoding configuration files 0600...")
    os.chmod(app_conf.get_config(), 0o600)
    os.chmod(wireless_conf, 0o600)
    os.chmod(wired_conf, 0o600)
    os.chmod(dhclient_conf, 0o644)

Одним из решений является просмотр файлов от имени пользователя root или пользователя, запустившего демон wicd.

Другое возможное решение — эмулировать целевую беспроводную сеть с помощью функции точки доступа любого смартфона. Вы должны использовать на телефоне то же сетевое имя (SSID ), что и имя сети, которую хотите восстановить, а затем использовать wicd. gui для отображения сохраненного пароля.

Главный человек:(переведен)

/etc/wicd/manager-settings.conf This file contains general Wicd settings. See the man page of this file for more information about it.

/etc/wicd/wired-settings.conf This file contains settings for the fixed interface. See the man page of this file for more information about it.

/etc/wicd/wireless-settings.conf This file contains settings related to the wireless interface. See the man page of this file for more information about it.

/etc/wicd/encryption/templates/ This directory contains various templates for encrypted (WEP, WPA, etc.) connections. If none of them meets your needs, you can make your own and add to this directory. If you do this, take it please contact the makers of Wicd (see below).

/var/lib/wicd/configurations/ This directory contains individual configuration files for each encrypted connection you make with Wicd.

/var/log/wicd/ This directory contains log files of Wicd's activities. Look in the log if you have problems with the connection or with other things.

Wireless -settings.conf man:(переведено)

DESCRIPTION

This file contains configuration information for the wireless network interfaces in Wicd.

This file is here: /etc/wicd/wireless-settings.conf

SETTINGS

"bssid =" This value can be found with iwconfig (8).

"essid =" This value can be found with iwconfig (8).

"hidden =" This option sets whether the ESSID of the network is broadcast or not.

"channel =" Good channels depend on the country. This value can be found with iwconfig (8).

"mode =" This value can be found with iwconfig (8).

"enctype =" This can be the value of any encryption template that is in / etc / wicd / encryption / templates /.

"key =" Ensure that this file can only be read by root.

"encryption_method =" WEP | WPA | WPA2> This value can be found with iwconfig (8).

"automatic =" This option sets whether Wicd should connect to this network automatically.

"ip =" Use this option if you have a fixed IP address for your system.

"netmask =" This setting only applies if a fixed IP address is set above.

"broadcast =" This setting only applies if a fixed IP address is set above.

"gateway =" This setting only applies if a fixed IP address is set above.

"use_static_dns =" ​​ True = use fixed DNS servers instead of accepting what the dhcp server offers..TP

"use_global_dns =" ​​ True = use the global DNS servers that are in wicd-manager-settings.conf (5). This option only applies if "use_static_dns = True"

"dns1 =" Static DNS address as "use_static_dns = True" and "use_global_dns = False"

"dns2 =" Static DNS address as "use_static_dns = True" and "use_global_dns = False"

"dns3 =" Static DNS address as "use_static_dns = True" and "use_global_dns = False"

"use_settings_globally =" <0 | 1> Wicd keeps track of whether a connection should be established automatically based on bssid. This ensures that you do not accidentally connect to another network that is not yours but has the same essid - for example, there are a lot of commercial routers in use with "linksys" as the essid.

0 = Do not use global settings

1 = Use global settings

"beforescript =" This defines a script that must be started before Wicd connects. This script must be a Bourne compatible script and must be executable.

IMPORTANT - scripts must ONLY be writable by root and must be in a directory that is only writable by root.

"afterscript =" This defines a script to be started after Wicd has established a connection. This script must be a Bourne compatible script and must be executable.

IMPORTANT - scripts must ONLY be writable by root and must be in a directory that is only writable by root.

"predisconnectscript =" This defines a script that must be started before Wicd breaks the connection. This script must be a Bourne compatible script and must be executable.

IMPORTANT - scripts must ONLY be writable by root and must be in a directory that is only writable by root.

"postdisconnectscript =" This defines a script to be started after Wicd has disconnected. This script must be a Bourne compatible script and must be executable.

IMPORTANT - scripts must ONLY be writable by root and must be in a directory that is only writable by root.

The "use_settings_globally" option according to how individual networks are configuration stanza starts. If the option is "0" (do not use settings globally), then the stanza's top line will be the bssid of the access point (in this format):

[00: 15: 3E: 87: D3: 68]

If the "option is set to" 1 "(use settings globally), then the first line of the stanza will be in this format:

[essid: UA Public Wireless Network]

3
27.01.2020, 20:42

Теги

Похожие вопросы