<?xml version="1.0" encoding="UTF-8" ?>

<bugzilla version="5.2"
          urlbase="https://bugzilla.altlinux.org/"
          
          maintainer="jenya@basealt.ru"
>

    <bug>
          <bug_id>13745</bug_id>
          
          <creation_ts>2007-12-18 14:27:17 +0300</creation_ts>
          <short_desc>Advanced settings hang</short_desc>
          <delta_ts>2008-03-06 02:15:28 +0300</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>4</classification_id>
          <classification>Development</classification>
          <product>Sisyphus</product>
          <component>alterator-apache2</component>
          <version>unstable</version>
          <rep_platform>all</rep_platform>
          <op_sys>Linux</op_sys>
          <bug_status>CLOSED</bug_status>
          <resolution>FIXED</resolution>
          
          
          <bug_file_loc></bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords></keywords>
          <priority>P2</priority>
          <bug_severity>normal</bug_severity>
          <target_milestone>---</target_milestone>
          
          <blocked>13746</blocked>
    
    <blocked>14698</blocked>
          <everconfirmed>1</everconfirmed>
          <reporter name="Grigory Batalov">bga</reporter>
          <assigned_to name="solo">solo</assigned_to>
          <cc>dubrsl</cc>
    
    <cc>inger</cc>
          
          <qa_contact>qa-sisyphus</qa_contact>

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>59705</commentid>
    <comment_count>0</comment_count>
    <who name="Grigory Batalov">bga</who>
    <bug_when>2007-12-18 14:27:17 +0300</bug_when>
    <thetext>Страница &quot;Расширенные настройки&quot;
https://localhost:8080/index.scm/apache2/extra/available не открывается и вешает
бэкенд.
В консоли команда alterator-cmdline /apache2/extra/available action list также
зависает.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>60057</commentid>
    <comment_count>1</comment_count>
    <who name="solo">solo</who>
    <bug_when>2007-12-27 04:40:43 +0300</bug_when>
    <thetext>Что-то непонятное:

1. Сам по себе бакенд работает нормально:

$ sudo -H /usr/lib/alterator/backend3/apache2 
_message:begin
_objects:extra/available
action:list
_message:end
(
(&quot;Directory_cgibin_default&quot; enabled &quot;no&quot; status_def &quot;none&quot; summary &quot;Default
config for CGI directory&quot;)
(&quot;httpd-mime&quot; enabled &quot;no&quot; status_def &quot;none&quot; summary &quot;Configure the list of
mappings from filename extension to MIME-type.&quot;)
(&quot;DirectoryIndex_default&quot; enabled &quot;yes&quot; status_def &quot;enable&quot; summary
&quot;DirectoryIndex by default&quot;)
(&quot;httpd-languages&quot; enabled &quot;yes&quot; status_def &quot;enable&quot; summary &quot;Settings for
hosting different languages.&quot;)
(&quot;httpd-proxy&quot; enabled &quot;no&quot; status_def &quot;none&quot; summary &quot;proxy_module configure&quot;)
(&quot;httpd-dav&quot; enabled &quot;no&quot; status_def &quot;none&quot; summary &quot;Distributed authoring and
versioning (WebDAV)&quot;)
(&quot;httpd-addon.d&quot; enabled &quot;yes&quot; status_def &quot;enable&quot; summary &quot;Load config files
from the config directory &quot;conf/addon.d&quot;)
(&quot;httpd-manual&quot; enabled &quot;yes&quot; status_def &quot;enable&quot; summary &quot;Provide access to the
documentation on your server&quot;)
(&quot;httpd-multilang-errordoc&quot; enabled &quot;yes&quot; status_def &quot;enable&quot; summary &quot;The
configuration below implements multi-language error documents through
content-negotiation&quot;)
(&quot;httpd-default&quot; enabled &quot;yes&quot; status_def &quot;enable&quot; summary &quot;This configuration
file reflects default settings for Apache HTTP Server.&quot;)
(&quot;mime_magic_default&quot; enabled &quot;no&quot; status_def &quot;none&quot; summary &quot;Default configs
for mime_magic_module&quot;)
(&quot;httpd-autoindex&quot; enabled &quot;yes&quot; status_def &quot;enable&quot; summary &quot;Directives
controlling the display of server-generated directory listings.&quot;)
(&quot;httpd-manual-addons&quot; enabled &quot;yes&quot; status_def &quot;enable&quot; summary &quot;Provide access
to the documentation to addons on your server&quot;)
(&quot;userdir_default&quot; enabled &quot;no&quot; status_def &quot;none&quot; summary &quot;Settings for user
home directories&quot;)
(&quot;mem_cache_default&quot; enabled &quot;no&quot; status_def &quot;none&quot; summary &quot;Default configs for
mem_cache_module&quot;)
(&quot;httpd-mpm&quot; enabled &quot;yes&quot; status_def &quot;enable&quot; summary &quot;&quot;)
(&quot;dav_fs_default&quot; enabled &quot;no&quot; status_def &quot;none&quot; summary &quot;&quot;)
(&quot;Directory_root_default&quot; enabled &quot;no&quot; status_def &quot;none&quot; summary &quot;Default config
for all dirs&quot;)
(&quot;Directory_html_default&quot; enabled &quot;no&quot; status_def &quot;none&quot; summary &quot;Default config
for html documents&quot;)
(&quot;deflate_default&quot; enabled &quot;no&quot; status_def &quot;none&quot; summary &quot;&quot;)
(&quot;httpd-info&quot; enabled &quot;no&quot; status_def &quot;none&quot; summary &quot;Get information about the
requests being processed by the server and the configuration of the server.&quot;)
(&quot;disk_cache_default&quot; enabled &quot;no&quot; status_def &quot;none&quot; summary &quot;&quot;)
(&quot;log_config_default&quot; enabled &quot;yes&quot; status_def &quot;enable&quot; summary &quot;Loging configure&quot;)
)

2. После добавления отладочной печати в начало и конец цикла обработки команд, в
логе вижу (после повисшего sudo -H alterator-cmdline apache2/extra/available
action list):

S in_action=list in__objects=extra/available
(&quot;Directory_cgibin_default&quot; enabled &quot;no&quot; status_def &quot;none&quot; summary &quot;Default
config for CGI directory&quot;)
(&quot;httpd-mime&quot; enabled &quot;no&quot; status_def &quot;none&quot; summary &quot;Configure the list of
mappings from filename extension to MIME-type.&quot;)
(&quot;DirectoryIndex_default&quot; enabled &quot;yes&quot; status_def &quot;enable&quot; summary
&quot;DirectoryIndex by default&quot;)
(&quot;httpd-languages&quot; enabled &quot;yes&quot; status_def &quot;enable&quot; summary &quot;Settings for
hosting different languages.&quot;)
(&quot;httpd-proxy&quot; enabled &quot;no&quot; status_def &quot;none&quot; summary &quot;proxy_module configure&quot;)
(&quot;httpd-dav&quot; enabled &quot;no&quot; status_def &quot;none&quot; summary &quot;Distributed authoring and
versioning (WebDAV)&quot;)
(&quot;httpd-addon.d&quot; enabled &quot;yes&quot; status_def &quot;enable&quot; summary &quot;Load config files
from the config directory &quot;conf/addon.d&quot;)
(&quot;httpd-manual&quot; enabled &quot;yes&quot; status_def &quot;enable&quot; summary &quot;Provide access to the
documentation on your server&quot;)
(&quot;httpd-multilang-errordoc&quot; enabled &quot;yes&quot; status_def &quot;enable&quot; summary &quot;The
configuration below implements multi-language error documents through
content-negotiation&quot;)
(&quot;httpd-default&quot; enabled &quot;yes&quot; status_def &quot;enable&quot; summary &quot;This configuration
file reflects default settings for Apache HTTP Server.&quot;)
(&quot;mime_magic_default&quot; enabled &quot;no&quot; status_def &quot;none&quot; summary &quot;Default configs
for mime_magic_module&quot;)
(&quot;httpd-autoindex&quot; enabled &quot;yes&quot; status_def &quot;enable&quot; summary &quot;Directives
controlling the display of server-generated directory listings.&quot;)
(&quot;httpd-manual-addons&quot; enabled &quot;yes&quot; status_def &quot;enable&quot; summary &quot;Provide access
to the documentation to addons on your server&quot;)
(&quot;userdir_default&quot; enabled &quot;no&quot; status_def &quot;none&quot; summary &quot;Settings for user
home directories&quot;)
(&quot;mem_cache_default&quot; enabled &quot;no&quot; status_def &quot;none&quot; summary &quot;Default configs for
mem_cache_module&quot;)
(&quot;httpd-mpm&quot; enabled &quot;yes&quot; status_def &quot;enable&quot; summary &quot;&quot;) 
(&quot;dav_fs_default&quot; enabled &quot;no&quot; status_def &quot;none&quot; summary &quot;&quot;)
(&quot;Directory_root_default&quot; enabled &quot;no&quot; status_def &quot;none&quot; summary &quot;Default config
for all dirs&quot;)
(&quot;Directory_html_default&quot; enabled &quot;no&quot; status_def &quot;none&quot; summary &quot;Default config
for html documents&quot;)
(&quot;deflate_default&quot; enabled &quot;no&quot; status_def &quot;none&quot; summary &quot;&quot;)
(&quot;httpd-info&quot; enabled &quot;no&quot; status_def &quot;none&quot; summary &quot;Get information about the
requests being processed by the server and the configuration of the server.&quot;)
(&quot;disk_cache_default&quot; enabled &quot;no&quot; status_def &quot;none&quot; summary &quot;&quot;)
(&quot;log_config_default&quot; enabled &quot;yes&quot; status_def &quot;enable&quot; summary &quot;Loging configure&quot;)
E in_action=list in__objects=extra/available

  Похоже, что альтератор неможет переворить то что ему возвращает модуль. Раньше
переваривал...



</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>60058</commentid>
    <comment_count>2</comment_count>
    <who name="solo">solo</who>
    <bug_when>2007-12-27 04:55:31 +0300</bug_when>
    <thetext>2inger: Нормальный ли вывод даёт модуль (п.1 предыдущего сообщения)?</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>61059</commentid>
    <comment_count>3</comment_count>
    <who name="Lenar Shakirov">shakirov</who>
    <bug_when>2008-01-14 19:30:21 +0300</bug_when>
    <thetext>Поковырялся и решил вопрос так:
Дело в кавычках.
Подредактировав файл /etc/httpd2/conf/extra-available/httpd-addon.d.conf

не работает:
Summary: Load config files from the config directory &quot;conf/addon.d&quot;
так работает:
Summary: Load config files from the config directory conf/addon.d

при отправке данных на woo шину:
printf &apos;(&quot;%s&quot; enabled &quot;%s&quot; status_def &quot;%s&quot; 
summary &quot;%s&quot;)\n&apos; &quot;$name&quot; &quot;$en&quot; &quot;$status_def&quot; &quot;$summary&quot;

в поле summary &quot;съедается&quot; одна кавычка:
(&quot;httpd-addon.d&quot; enabled &quot;yes&quot; status_def &quot;enable&quot; summary &quot;Load config files 
from the config directory &quot;conf/addon.d&quot;), а должно быть
(&quot;httpd-addon.d&quot; enabled &quot;yes&quot; status_def &quot;enable&quot; summary &quot;Load config files 
from the config directory &quot;conf/addon.d&quot;&quot;).</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>61060</commentid>
    <comment_count>4</comment_count>
    <who name="Lenar Shakirov">shakirov</who>
    <bug_when>2008-01-14 20:15:25 +0300</bug_when>
    <thetext>Поковыря дальше, кавычка &quot;съедается&quot; вот здесь
/usr/share/alterator/build/apache2.sh
а конкретно, в функции get_headers
а конкретней в паттерне P_get_Summary, который я расковыривать не стал</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>61108</commentid>
    <comment_count>5</comment_count>
    <who name="solo">solo</who>
    <bug_when>2008-01-15 13:39:30 +0300</bug_when>
    <thetext>(In reply to comment #4)
&gt; Поковыря дальше, кавычка &quot;съедается&quot; вот здесь
&gt; /usr/share/alterator/build/apache2.sh
&gt; а конкретно, в функции get_headers
&gt; а конкретней в паттерне P_get_Summary, который я расковыривать не стал

Спасибо, дальше сам справлюсь.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>61720</commentid>
    <comment_count>6</comment_count>
    <who name="solo">solo</who>
    <bug_when>2008-01-22 16:20:03 +0300</bug_when>
    <thetext>Как оказалось, здесь у меня целый букет багов:

1) кавычки терялись при формировании регулярного выражения;

2) не правильно отбрасывались концевые (они отбрасывались всегда, даже если
строка начиналась/заканчивалась закавыченной подстрокой);

3) внутристрочные кавычки передавались alterator`у без экранирования...

Тег ALT/alterator-apache2/2.3.4 (см.
http://git.altlinux.org/people/solo/packages/?p=alterator-apache2.git;a=commit;h=12ad8aeaba0dc55cea5c531fc02d39abde133f9c)
содержит исправленную версию скриптов.

Сделано:

1. Поправлено использование кавычек внутри регэкспов (перешёл на bash синтакс --
так проще).

2. Отброс концевых кавычек сделан правильно (происходит только если вся строка
заключена в кавычки).

3. Кавычки экранируются при передачи.

Пункты 2 и 3 на данный момент сделаны только для части полей (пока _не_ для всех).</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>61758</commentid>
    <comment_count>7</comment_count>
    <who name="inger@altlinux.org">inger</who>
    <bug_when>2008-01-23 10:17:32 +0300</bug_when>
    <thetext>hint: libshell.
</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>61774</commentid>
    <comment_count>8</comment_count>
    <who name="solo">solo</who>
    <bug_when>2008-01-23 17:18:46 +0300</bug_when>
    <thetext>(In reply to comment #7)
&gt; hint: libshell.
&gt; 

Прошу подробностей...</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>61785</commentid>
    <comment_count>9</comment_count>
    <who name="inger@altlinux.org">inger</who>
    <bug_when>2008-01-23 19:12:56 +0300</bug_when>
    <thetext>$ apt-cache search libshell
libshell - A library of shell functions

Там много велосипедов по правильному квотированию
</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>61788</commentid>
    <comment_count>10</comment_count>
    <who name="solo">solo</who>
    <bug_when>2008-01-23 19:31:18 +0300</bug_when>
    <thetext>(In reply to comment #9)
&gt; $ apt-cache search libshell
&gt; libshell - A library of shell functions
&gt; 
&gt; Там много велосипедов по правильному квотированию
&gt; 

Спасибо.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>62195</commentid>
    <comment_count>11</comment_count>
    <who name="solo">solo</who>
    <bug_when>2008-01-29 06:58:17 +0300</bug_when>
    <thetext>alterator-apache2-2.3.5-alt1.src.rpm (см.
http://git.altlinux.org/people/solo/packages/?p=alterator-apache2.git;a=commit;h=9feff59eec02bfff4136fd8e8580d6acd819b1c1)
ушёл в incoming/Sisyphus.</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>