* [Sysadmins] Безопасность openvpn @ 2009-03-01 10:23 Michael A. Kangin 2009-03-01 14:25 ` Nikolay A. Fetisov 0 siblings, 1 reply; 4+ messages in thread From: Michael A. Kangin @ 2009-03-01 10:23 UTC (permalink / raw) To: ALT Linux sysadmin discuss Добрый день. Насколько безопасна работа openvpn без чрута и от рута, если оно гоняется в своём собственном VE? А то есть желание поднимать файрвольные правила и рутинг поюзерно с помощью client-connect script и client-config-dir/ И есть ли альтернативные варианты? Жёстко привязывать пользователей к фиксированным IPшникам не хотелось бы, из-за возможных duplicate-cn в частности. -- wbr, Michael A. Kangin ^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [Sysadmins] Безопасность openvpn 2009-03-01 10:23 [Sysadmins] Безопасность openvpn Michael A. Kangin @ 2009-03-01 14:25 ` Nikolay A. Fetisov 2009-03-01 14:57 ` Michael A. Kangin 0 siblings, 1 reply; 4+ messages in thread From: Nikolay A. Fetisov @ 2009-03-01 14:25 UTC (permalink / raw) To: sysadmins On Sun, 1 Mar 2009 13:23:45 +0300 Michael A. Kangin wrote: > Насколько безопасна работа openvpn без чрута и от рута, если оно гоняется в > своём собственном VE? > А то есть желание поднимать файрвольные правила и рутинг поюзерно с помощью > client-connect script и client-config-dir/ Особых противопоказаний нет. Работа от непривилегированного пользователя и в chroot-окружении исходя из общих соображений желательна, но не обязательна. С другой стороны, никто не мешает как разрешить запускать iptables и 'ip route' из скрипта через sudo, так и втащить их во внутрь chroot'а. > И есть ли альтернативные варианты? Жёстко привязывать пользователей к > фиксированным IPшникам не хотелось бы, из-за возможных duplicate-cn в > частности. Зависит от задачи. Например, не совсем понятно, как планируется совмещать использование одинаковых сертификатов на нескольких клиентах и зависящие от конкретных клиентов правила маршрутизации. Т.е., индивидуальные маршруты в client-config-dir задаются, если есть необходимость дать доступ через канал OpenVPN к сети на стороне клиента. Если этот клиент (различаемый по cn) может устанавливать одновременно несколько соединений (что разрешает делать duplicate-cn), то как скрипт client-connect будет определять, какое из этих соединений использовать для маршрута в сеть клиента? Аналогичные вопросы - и по индивидуальным для клиента правилам межсетевого экрана. -- С уважением, Николай Фетисов ^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [Sysadmins] Безопасность openvpn 2009-03-01 14:25 ` Nikolay A. Fetisov @ 2009-03-01 14:57 ` Michael A. Kangin 2009-03-02 7:20 ` Nikolay A. Fetisov 0 siblings, 1 reply; 4+ messages in thread From: Michael A. Kangin @ 2009-03-01 14:57 UTC (permalink / raw) To: ALT Linux sysadmin discuss On Sunday 01 March 2009 17:25:45 Nikolay A. Fetisov wrote: > > Насколько безопасна работа openvpn без чрута и от рута, если оно гоняется > > в своём собственном VE? > > А то есть желание поднимать файрвольные правила и рутинг поюзерно с > > помощью client-connect script и client-config-dir/ > Особых противопоказаний нет. Работа от непривилегированного > пользователя и в chroot-окружении исходя из общих соображений > желательна, но не обязательна. > С другой стороны, никто не мешает как разрешить запускать iptables и > 'ip route' из скрипта через sudo, так и втащить их во внутрь chroot'а. Да, думал над этим. Страшит ручной труд по втаскиванию и трудности с поддержкой... До сих пор с содроганием вспоминаю свой апач в чруте на слакваре. > > И есть ли альтернативные варианты? Жёстко привязывать пользователей к > > фиксированным IPшникам не хотелось бы, из-за возможных duplicate-cn в > > частности. > Зависит от задачи. Например, не совсем понятно, как планируется > совмещать использование одинаковых сертификатов на нескольких клиентах > и зависящие от конкретных клиентов правила маршрутизации. > Т.е., индивидуальные маршруты в client-config-dir задаются, если есть > необходимость дать доступ через канал OpenVPN к сети на стороне клиента. > Если этот клиент (различаемый по cn) может устанавливать > одновременно несколько соединений (что разрешает делать duplicate-cn), > то как скрипт client-connect будет определять, какое из этих соединений > использовать для маршрута в сеть клиента? > Аналогичные вопросы - и по индивидуальным для клиента правилам > межсетевого экрана. Есть пользователи, есть филиалы. Моя первоначальная мысль была - не заморачиваться с дополнительными каналами, и принимать тех и других одним и тем же каналом демона, разруливая особенности клиентскими файлами. Пользователи могут коннектиться потенциально с разных машин, для них-то и делается duplicate-cn. Рутинг на них как раз поднимать не надо, только файрвольное правило (if user=admin_vasya then iptables -s $vadmin_vasya_ip -j ACCEPT). А филиалы ожидаются по одному подключению, и им как раз необходимо возведение рутинга. Или я фигнёй страдаю и лучше всё же развести их по каналам? -- wbr, Michael A. Kangin ^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [Sysadmins] Безопасность openvpn 2009-03-01 14:57 ` Michael A. Kangin @ 2009-03-02 7:20 ` Nikolay A. Fetisov 0 siblings, 0 replies; 4+ messages in thread From: Nikolay A. Fetisov @ 2009-03-02 7:20 UTC (permalink / raw) To: sysadmins On Sun, 1 Mar 2009 17:57:17 +0300 Michael A. Kangin wrote: > On Sunday 01 March 2009 17:25:45 Nikolay A. Fetisov wrote: > > > > Насколько безопасна работа openvpn без чрута и от рута, если оно гоняется > > > в своём собственном VE? > > ... никто не мешает как разрешить запускать iptables и > > 'ip route' из скрипта через sudo, так и втащить их во внутрь chroot'а. > > ... Страшит ручной труд по втаскиванию и трудности с > поддержкой... Как вариант - вытащить из chroot и оставить работать под непривилегированным пользователем. > .... > Есть пользователи, есть филиалы. Моя первоначальная мысль была - не > заморачиваться с дополнительными каналами, и принимать тех и других одним и > тем же каналом демона, разруливая особенности клиентскими файлами. Зависит от числа как пользователей, так и филиалов. И от того, насколько различаются требования к этим двум группам соединений. Например, филиалы должны иметь возможность общаться друг с другом через сервер OpenVPN (т.е. будет ли включён флаг client-to-client)? Если да, то и пользователи тоже смогут видеть друг друга - что, скорее всего, нежелательно. > Пользователи могут коннектиться потенциально с разных машин, для них-то и > делается duplicate-cn. Зачем? dublicate-cn разрешает несколько одновременных соединений с одним и и тем же сертификатом. Или пользователи могут _одновременно_ работать с разных машин? И не проще ли тем пользователям, которые действительно имеют несколько компьютеров, выдать несколько сертификатов? > ... > Или ... лучше всё же развести их по каналам? Зависит от числа пользователей и от того, откуда они подсоединяются. Как правило, филиалов немного, их число меняется редко - явные кандидаты на получение фиксированных IP. Пользователи же характерны тем, что выданные им права на подключения к серверу OpenVPN может потребоваться отозвать. Если пользователей немного - то им вполне можно назначать фиксированные IP через персональные файлы конфигурации в ccd/ . Дополнительно можно включить на сервере ccd-exclusive и тем самым запретить соединения от тех клиентов, для которых файлов конфигурации не существует. После этого, если надо запретить соединение от какого-либо пользователя, достаточно удалить его файл конфигурации. Если пользователей много - то может оказаться проще не создавать для каждого из них свой файл конфигурации, а отзывать сертификаты средствами SSL, через CRL. Для избранных пользователей при этом можно оставить и индивидуальные файлы настроек, они вполне уживаются с динамическим распределением адресов. Кроме того, возможно вообще потребуется отдельно поднимать сервер OpenVPN на 443/tcp, специально для тех, кто сидит за прокси-серверами. -- С уважением, Николай Фетисов ^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2009-03-02 7:20 UTC | newest] Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed) -- links below jump to the message on this page -- 2009-03-01 10:23 [Sysadmins] Безопасность openvpn Michael A. Kangin 2009-03-01 14:25 ` Nikolay A. Fetisov 2009-03-01 14:57 ` Michael A. Kangin 2009-03-02 7:20 ` Nikolay A. Fetisov
ALT Linux sysadmins discussion This inbox may be cloned and mirrored by anyone: git clone --mirror http://lore.altlinux.org/sysadmins/0 sysadmins/git/0.git # If you have public-inbox 1.1+ installed, you may # initialize and index your mirror using the following commands: public-inbox-init -V2 sysadmins sysadmins/ http://lore.altlinux.org/sysadmins \ sysadmins@lists.altlinux.org sysadmins@lists.altlinux.ru sysadmins@lists.altlinux.com public-inbox-index sysadmins Example config snippet for mirrors. Newsgroup available over NNTP: nntp://lore.altlinux.org/org.altlinux.lists.sysadmins AGPL code for this site: git clone https://public-inbox.org/public-inbox.git