<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>poohSec</title>
	<atom:link href="http://pooh.gr.jp/?feed=rss2" rel="self" type="application/rss+xml" />
	<link>http://pooh.gr.jp</link>
	<description>プーさんたちとセキュリティ</description>
	<lastBuildDate>Fri, 18 May 2012 16:45:22 +0000</lastBuildDate>
	<language>ja</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.2</generator>
		<item>
		<title>CentOS 6にLibreOfficeをインストールする</title>
		<link>http://pooh.gr.jp/?p=9730</link>
		<comments>http://pooh.gr.jp/?p=9730#comments</comments>
		<pubDate>Fri, 18 May 2012 16:42:30 +0000</pubDate>
		<dc:creator>shinago</dc:creator>
				<category><![CDATA[Linux]]></category>

		<guid isPermaLink="false">http://pooh.gr.jp/?p=9730</guid>
		<description><![CDATA[CentOS 6.2にLibreOffice 3.5.3をインストールする。rpmパッケージをダウンロードしてインストールする。yumに対応して欲しい。 LibreOfficeのメインインストーラーをインストールする。 wget "http://download.documentfoundation.org/libreoffice/stable/3.5.3/rpm/x86/LibO_3.5.3_Linux_x86_install-rpm_en-US.tar.gz" tar zxf LibO_3.5.3_Linux_x86_install-rpm_en-US.tar.gz rpm -Uvh ./LibO_3.5.3rc2_Linux_x86_install-rpm_en-US/RPMS/*.rpm メニューをインストールする。 rpm -Uvh ./LibO_3.5.3rc2_Linux_x86_install-rpm_en-US/RPMS/desktop-integration/libreoffice3.5-freedesktop-menus-3.5.3-2.noarch.rpm 日本語インタフェースをインストールする。 wget "http://download.documentfoundation.org/libreoffice/stable/3.5.3/rpm/x86/LibO_3.5.3_Linux_x86_langpack-rpm_ja.tar.gz" tar...]]></description>
			<content:encoded><![CDATA[<p><a href="http://pooh.gr.jp/wp-content/uploads/2012/05/linux-libreoffice.jpg"><img class="wp-image-9733 aligncenter" title="linux-libreoffice" src="http://pooh.gr.jp/wp-content/uploads/2012/05/linux-libreoffice.jpg" alt="" width="368" height="247" /></a></p>
<p>CentOS 6.2にLibreOffice 3.5.3をインストールする。rpmパッケージをダウンロードしてインストールする。yumに対応して欲しい。<br />
LibreOfficeのメインインストーラーをインストールする。</p>
<pre>wget "http://download.documentfoundation.org/libreoffice/stable/3.5.3/rpm/x86/LibO_3.5.3_Linux_x86_install-rpm_en-US.tar.gz"
tar zxf LibO_3.5.3_Linux_x86_install-rpm_en-US.tar.gz
rpm -Uvh ./LibO_3.5.3rc2_Linux_x86_install-rpm_en-US/RPMS/*.rpm</pre>
<p>メニューをインストールする。</p>
<pre>rpm -Uvh ./LibO_3.5.3rc2_Linux_x86_install-rpm_en-US/RPMS/desktop-integration/libreoffice3.5-freedesktop-menus-3.5.3-2.noarch.rpm</pre>
<p>日本語インタフェースをインストールする。</p>
<pre>wget "http://download.documentfoundation.org/libreoffice/stable/3.5.3/rpm/x86/LibO_3.5.3_Linux_x86_langpack-rpm_ja.tar.gz"
tar zxf LibO_3.5.3_Linux_x86_helppack-rpm_ja.tar.gz
rpm -Uvh .LibO_3.5.3rc2_Linux_x86_langpack-rpm_ja/RPMS/*.rpm</pre>
<p>ヘルプをインストールする。</p>
<pre>wget "http://download.documentfoundation.org/libreoffice/stable/3.5.3/rpm/x86/LibO_3.5.3_Linux_x86_helppack-rpm_ja.tar.gz"
tar zxf LibO_3.5.3_Linux_x86_langpack-rpm_ja.tar.gz
rpm -Uvh LibO_3.5.3rc2_Linux_x86_helppack-rpm_ja/RPMS/*.rpm</pre>
<p>LibreOffice for CentOS 5 or CentOS 6 install howto<br />
<a href="http://pjwelsh.blogspot.jp/2011/07/libroffice-for-centos-5-or-centos-6.html "> http://pjwelsh.blogspot.jp/2011/07/libroffice-for-centos-5-or-centos-6.html</a></p>
]]></content:encoded>
			<wfw:commentRss>http://pooh.gr.jp/?feed=rss2&#038;p=9730</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>CentOS 6にGoogle Chromeをインストールしたい</title>
		<link>http://pooh.gr.jp/?p=9717</link>
		<comments>http://pooh.gr.jp/?p=9717#comments</comments>
		<pubDate>Fri, 18 May 2012 16:18:10 +0000</pubDate>
		<dc:creator>shinago</dc:creator>
				<category><![CDATA[Linux]]></category>

		<guid isPermaLink="false">http://pooh.gr.jp/?p=9717</guid>
		<description><![CDATA[CentOS 6.2にGoogle Chromeをインストールする。yumを利用する。 32ビットの場合 cat &#60;&#60; 'EOF' &#62; /etc/yum.repos.d/google.repo [google-chrome] name=google-chrome - 32-bit baseurl=http://dl.google.com/linux/chrome/rpm/stable/i386 enabled=1 gpgcheck=1 gpgkey=https://dl-ssl.google.com/linux/linux_signing_key.pub EOF 64ビットの場合 cat...]]></description>
			<content:encoded><![CDATA[<p style="text-align: center;"><a href="http://pooh.gr.jp/wp-content/uploads/2012/05/linux-chrome.jpg"><img class="wp-image-9718 aligncenter" title="linux-chrome" src="http://pooh.gr.jp/wp-content/uploads/2012/05/linux-chrome.jpg" alt="" width="464" height="180" /></a></p>
<p>CentOS 6.2にGoogle Chromeをインストールする。yumを利用する。</p>
<p>32ビットの場合</p>
<pre>cat &lt;&lt; 'EOF' &gt; /etc/yum.repos.d/google.repo
[google-chrome]
name=google-chrome - 32-bit
baseurl=http://dl.google.com/linux/chrome/rpm/stable/i386
enabled=1
gpgcheck=1
gpgkey=https://dl-ssl.google.com/linux/linux_signing_key.pub
EOF</pre>
<p>64ビットの場合</p>
<pre>cat &lt;&lt; 'EOF' &gt; /etc/yum.repos.d/google.repo
[google-chrome]
name=google-chrome - 64-bit
baseurl=http://dl.google.com/linux/chrome/rpm/stable/x86_64
enabled=1
gpgcheck=1
gpgkey=https://dl-ssl.google.com/linux/linux_signing_key.pub
EOF</pre>
<p>インストールの実行</p>
<pre>yum -y install google-chrome-stable</pre>
<p>google-chrome-beta, google-chrome-unstableは簡単には動かせない。</p>
<p>Install Google Chrome with YUM on Fedora 16/15, CentOS/Red Hat (RHEL) 6.2<br />
<a href="http://www.if-not-true-then-false.com/2010/install-google-chrome-with-yum-on-fedora-red-hat-rhel/">http://www.if-not-true-then-false.com/2010/install-google-chrome-with-yum-on-fedora-red-hat-rhel/</a></p>
<p>&nbsp;</p>
]]></content:encoded>
			<wfw:commentRss>http://pooh.gr.jp/?feed=rss2&#038;p=9717</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>VNCのキーボードレイアウトが英語（US）</title>
		<link>http://pooh.gr.jp/?p=9712</link>
		<comments>http://pooh.gr.jp/?p=9712#comments</comments>
		<pubDate>Tue, 15 May 2012 04:59:16 +0000</pubDate>
		<dc:creator>shinago</dc:creator>
				<category><![CDATA[Linux]]></category>

		<guid isPermaLink="false">http://pooh.gr.jp/?p=9712</guid>
		<description><![CDATA[CentOS 6にて。 VNCでキーボードのレイアウトが日本語になってくれない（@キー押してるのに[）ときは、あえてレイアウトを英語（US）にするとよいかも。 [システム] &#62; [設定] &#62; [キーボード] [レイアウト] タブ &#62; [デフォルトに戻す] レイアウト[日本語] が削除され [英語（US）] のみになる [設定の確認] に &#8220;@&#8221; などを入力してみる...]]></description>
			<content:encoded><![CDATA[<p>CentOS 6にて。</p>
<p>VNCでキーボードのレイアウトが日本語になってくれない（@キー押してるのに[）ときは、あえてレイアウトを英語（US）にするとよいかも。</p>
<p>[システム] &gt; [設定] &gt; [キーボード]<br />
[レイアウト] タブ &gt; [デフォルトに戻す]<br />
レイアウト[日本語] が削除され [英語（US）] のみになる<br />
[設定の確認] に &#8220;@&#8221; などを入力してみる</p>
<p>CentOS6.0とVNC<br />
<a href="http://www.furuthin.net/blog/archives/37">http://www.furuthin.net/blog/archives/37</a></p>
]]></content:encoded>
			<wfw:commentRss>http://pooh.gr.jp/?feed=rss2&#038;p=9712</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Xが起動しない（GUI）</title>
		<link>http://pooh.gr.jp/?p=9709</link>
		<comments>http://pooh.gr.jp/?p=9709#comments</comments>
		<pubDate>Tue, 15 May 2012 03:54:27 +0000</pubDate>
		<dc:creator>shinago</dc:creator>
				<category><![CDATA[Linux]]></category>

		<guid isPermaLink="false">http://pooh.gr.jp/?p=9709</guid>
		<description><![CDATA[CentOS 6.2にて。 messagebusを止めたから。止めるとログイン前の起動画面で固まる。起動しなくなったら確かめてみて。 /sbin/chkconfig --list messagebus]]></description>
			<content:encoded><![CDATA[<p>CentOS 6.2にて。</p>
<p>messagebusを止めたから。止めるとログイン前の起動画面で固まる。起動しなくなったら確かめてみて。</p>
<pre>/sbin/chkconfig --list messagebus</pre>
]]></content:encoded>
			<wfw:commentRss>http://pooh.gr.jp/?feed=rss2&#038;p=9709</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>CentOS 5をOracle Linux 5にアップデート</title>
		<link>http://pooh.gr.jp/?p=9706</link>
		<comments>http://pooh.gr.jp/?p=9706#comments</comments>
		<pubDate>Mon, 07 May 2012 07:59:44 +0000</pubDate>
		<dc:creator>shinago</dc:creator>
				<category><![CDATA[Linux]]></category>

		<guid isPermaLink="false">http://pooh.gr.jp/?p=9706</guid>
		<description><![CDATA[CentOSのパッチリリースが遅れるようになったのでOracle Linuxに移行する。でもわざわざOSを再インストールはしたくないのでup2dateとyumを使ってパッケージを上書きする。CentOS 5 → Oracle Linux 5 iptablesに穴を開ける。 /sbin/iptables -I OUTPUT -d linux-update.oracle.com -j ACCEPT /sbin/iptables -I OUTPUT -d public-yum.oracle.com...]]></description>
			<content:encoded><![CDATA[<p>CentOSのパッチリリースが遅れるようになったのでOracle Linuxに移行する。でもわざわざOSを再インストールはしたくないのでup2dateとyumを使ってパッケージを上書きする。CentOS 5 → Oracle Linux 5</p>
<p>iptablesに穴を開ける。</p>
<pre>/sbin/iptables -I OUTPUT -d linux-update.oracle.com -j ACCEPT
/sbin/iptables -I OUTPUT -d public-yum.oracle.com -j ACCEPT</pre>
<p>up2dateの依存関係にあるパッケージをインストールする。</p>
<pre>yum install -y libxml2-python pyOpenSSL
rpm -ivh http://public-yum.oracle.com/repo/OracleLinux/OL5/latest/i386/rhnlib-2.5.22-7.el5.noarch.rpm</pre>
<p>up2date（ULN版）をインストールする。</p>
<pre>rpm -ivh --force http://linux-update.oracle.com/rpms/up2date-5.10.1-40.8.el5.i386.rpm</pre>
<p style="padding-left: 30px;">up2date（ULN版）とcentos-release-5-8.el5.centosは競合するため&#8211;forceオプションで強制的にインストールする必要がある。</p>
<pre style="padding-left: 30px;">ファイル /etc/sysconfig/rhn/sources (パッケージ up2date-5.10.1-40.8.el5.i386 から) は、パッケージ centos-release-5-8.el5.centos.i386 からのファイルと競合しています。</pre>
<p>ULN向けの穴を開ける。/etc/sysconfig/iptablesに次の設定を追加する。</p>
<pre># ORACLE-FI
-A OUTPUT -d 141.146.0.0/16 -j ACCEPT</pre>
<p>ULNに登録する。ライセンスが必要。</p>
<pre>rpm --import /usr/share/rhn/RPM-GPG-KEY
/usr/sbin/up2date --register</pre>
<p>up2date自体をアップデートから除外する。up2dateを一緒にアップデートしたり、いきなりyumするとエラーになってしまう。</p>
<pre>cp -a /etc/sysconfig/rhn/up2date /etc/sysconfig/rhn/up2date.orig
sed -i -e '/^pkgSkipList=/s/$/up2date;/' /etc/sysconfig/rhn/up2date</pre>
<p>up2dateを実行してCentOSからOracle Linuxのパッケージにアップデートする。</p>
<pre>/usr/sbin/up2date -u</pre>
<p>up2date自体とkernelもアップデートする。</p>
<pre>/usr/sbin/up2date -u -f</pre>
<p>up2dateだけでなくyumも使えるようにする。</p>
<pre>/usr/sbin/up2date --install yum-rhn-plugin</pre>
<p>yumの邪魔な古い設定を消す。</p>
<pre>yum erase -y centos-release centos-release-notes
for fn in $( ls /etc/yum.repos.d/*.repo ) ; do mv ${fn} ${fn}.$( date +%Y%m%d%H%M%S ) ; done</pre>
<p>Switching from Red Hat Network to Unbreakable Linux Network (ULN)<br />
<a href="https://linux.oracle.com/switch.html">https://linux.oracle.com/switch.html</a></p>
<p>On Yum support for Unbreakable Linux Network (ULN)<br />
<a href="https://blogs.oracle.com/linux/entry/turning_on_yum_support_for_unbreakable_linux_network_uln">https://blogs.oracle.com/linux/entry/turning_on_yum_support_for_unbreakable_linux_network_uln</a></p>
<p>up2dateで特定のパッケージを更新対象から除外する方法<br />
<a href="http://www.lovebug.jp/index.php?up2date/%C6%C3%C4%EA%A4%CE%A5%D1%A5%C3%A5%B1%A1%BC%A5%B8%A4%F2%B9%B9%BF%B7%C2%D0%BE%DD%A4%AB%A4%E9%BD%FC%B3%B0%A4%B9%A4%EB%CA%FD%CB%A1">http://www.lovebug.jp/index.php?up2date/%C6%C3%C4%EA%A4%CE%A5%D1%A5%C3%A5%B1%A1%BC%A5%B8%A4%F2%B9%B9%BF%B7%C2%D0%BE%DD%A4%AB%A4%E9%BD%FC%B3%B0%A4%B9%A4%EB%CA%FD%CB%A1</a></p>
]]></content:encoded>
			<wfw:commentRss>http://pooh.gr.jp/?feed=rss2&#038;p=9706</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Macに追加したアプリ</title>
		<link>http://pooh.gr.jp/?p=9702</link>
		<comments>http://pooh.gr.jp/?p=9702#comments</comments>
		<pubDate>Mon, 07 May 2012 03:54:05 +0000</pubDate>
		<dc:creator>shinago</dc:creator>
				<category><![CDATA[Mac]]></category>

		<guid isPermaLink="false">http://pooh.gr.jp/?p=9702</guid>
		<description><![CDATA[AppStoreから追加したアプリ Xcode http://itunes.apple.com/jp/app/xcode/id497799835 ClamXav http://itunes.apple.com/jp/app/clamxav/id430207028 Pages http://itunes.apple.com/jp/app/pages/id409201541 Numbers http://itunes.apple.com/jp/app/numbers/id409203825 Keynote http://itunes.apple.com/jp/app/keynote/id409183694 iPhoto http://itunes.apple.com/jp/app/iphoto/id40898138 iMovie http://itunes.apple.com/jp/app/imovie/id408981434 Memory Scope http://itunes.apple.com/jp/app/memory-scope/id470372671 Twitter http://itunes.apple.com/jp/app/twitter/id409789998 インターネットから追加したアプリ Google Chrome http://www.google.co.jp/chrome/ Google 日本語入力 http://www.google.co.jp/ime/ Keka http://www.kekaosx.com/ja/ Cyberduck http://cyberduck.ch/ CotEditor http://sourceforge.jp/projects/coteditor/ MacPorts http://www.macports.org/install.php...]]></description>
			<content:encoded><![CDATA[<p>AppStoreから追加したアプリ</p>
<p style="padding-left: 30px;">Xcode <a href="http://itunes.apple.com/jp/app/xcode/id497799835">http://itunes.apple.com/jp/app/xcode/id497799835<br />
</a>ClamXav <a href="http://itunes.apple.com/jp/app/clamxav/id430207028">http://itunes.apple.com/jp/app/clamxav/id430207028<br />
</a>Pages <a href="http://itunes.apple.com/jp/app/pages/id409201541">http://itunes.apple.com/jp/app/pages/id409201541<br />
</a>Numbers <a href="http://itunes.apple.com/jp/app/numbers/id409203825">http://itunes.apple.com/jp/app/numbers/id409203825<br />
</a>Keynote <a href="http://itunes.apple.com/jp/app/keynote/id409183694">http://itunes.apple.com/jp/app/keynote/id409183694<br />
</a>iPhoto <a href="http://itunes.apple.com/jp/app/iphoto/id408981381">http://itunes.apple.com/jp/app/iphoto/id40898138<br />
</a>iMovie <a href="http://itunes.apple.com/jp/app/imovie/id408981434">http://itunes.apple.com/jp/app/imovie/id408981434<br />
</a>Memory Scope <a href="http://itunes.apple.com/jp/app/memory-scope/id470372671">http://itunes.apple.com/jp/app/memory-scope/id470372671<br />
</a>Twitter <a href="http://itunes.apple.com/jp/app/twitter/id409789998">http://itunes.apple.com/jp/app/twitter/id409789998</a></p>
<p>インターネットから追加したアプリ</p>
<p style="padding-left: 30px;">Google Chrome <a href="http://www.google.co.jp/chrome/">http://www.google.co.jp/chrome/<br />
</a>Google 日本語入力 <a href="http://www.google.co.jp/ime/">http://www.google.co.jp/ime/<br />
</a>Keka <a href="http://www.kekaosx.com/ja/">http://www.kekaosx.com/ja/<br />
</a>Cyberduck <a href="http://cyberduck.ch/">http://cyberduck.ch/<br />
</a>CotEditor <a href="http://sourceforge.jp/projects/coteditor/">http://sourceforge.jp/projects/coteditor/<br />
</a>MacPorts <a href="http://www.macports.org/install.php">http://www.macports.org/install.php<br />
</a>XMind <a href="http://www.xmind.net/downloads/">http://www.xmind.net/downloads/<br />
</a>Picasa <a href="http://picasa.google.com/">http://picasa.google.com/<br />
</a>Skype <a href="http://www.skype.com/intl/ja/get-skype/">http://www.skype.com/intl/ja/get-skype/<br />
</a>あんずもじ・あんずもじ等幅 <a href="http://www8.plala.or.jp/p_dolce/font2.html">http://www8.plala.or.jp/p_dolce/font2.html</a></p>
<p>パッケージで追加したアプリ</p>
<p style="padding-left: 30px;">Microsoft Office for Mac <a href="http://www.microsoft.com/japan/mac">http://www.microsoft.com/japan/mac</a></p>
]]></content:encoded>
			<wfw:commentRss>http://pooh.gr.jp/?feed=rss2&#038;p=9702</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>その他のpostfixの設定</title>
		<link>http://pooh.gr.jp/?p=9696</link>
		<comments>http://pooh.gr.jp/?p=9696#comments</comments>
		<pubDate>Wed, 02 May 2012 15:34:32 +0000</pubDate>
		<dc:creator>shinago</dc:creator>
				<category><![CDATA[Linux]]></category>

		<guid isPermaLink="false">http://pooh.gr.jp/?p=9696</guid>
		<description><![CDATA[TLSサポートのために証明書を作成する。 umask 0077 cat &#60;&#60; 'EOF' &#62; /etc/pki/tls/certs/mail.conf [ req ] prompt = no distinguished_name = req_distinguished_name [ req_distinguished_name ]...]]></description>
			<content:encoded><![CDATA[<p>TLSサポートのために証明書を作成する。</p>
<pre>umask 0077
cat &lt;&lt; 'EOF' &gt; /etc/pki/tls/certs/mail.conf
[ req ]
prompt                  = no
distinguished_name      = req_distinguished_name
[ req_distinguished_name ]
C                       = JP
ST                      = Tokyo
L                       = Kita-ku
O                       = POOH.GR.JP
OU                      = POOH.GR.JP
CN                      = allekto.pooh.gr.jp
EOF
openssl req -new -x509 -nodes -days 3650 \
 -out /etc/pki/tls/certs/mail.crt \
 -keyout /etc/pki/tls/private/mail.key \
 -config /etc/pki/tls/certs/mail.conf
umask 0022</pre>
<p>clamav-milter以外のpostfixの設定。</p>
<pre>cat &lt;&lt; 'EOF' &gt;&gt; /etc/postfix/main.cf

myhostname = allekto.pooh.gr.jp
mydomain = pooh.gr.jp
myorigin = $myhostname
inet_interfaces = all
mydestination = $myhostname, localhost.$mydomain, localhost, $mydomain
local_recipient_maps = $alias_maps
mynetworks = 127.0.0.0/8, 10.0.0.0/8, 172.16.0.0/12, 192.168.0.0/16
relay_domains = $mydestination, softbank.ne.jp
smtpd_banner = $myhostname ESMTP
smtpd_tls_cert_file = /etc/pki/tls/certs/mail.crt
smtpd_tls_key_file = /etc/pki/tls/private/mail.key
smtpd_tls_loglevel = 1
smtpd_use_tls = yes
smtpd_tls_session_cache_database = btree:/etc/postfix/smtpd_scache
message_size_limit=10000000
disable_vrfy_command=yes
smtpd_helo_required=yes
strict_rfc821_envelopes=no
allow_percent_hack = yes
swap_bangpath = yes
allow_untrusted_routing = no

smtpd_recipient_restrictions =
    reject_unauth_destination,
    permit_mynetworks
EOF</pre>
<p>permit_mynetworksよりもreject_unauth_destinationを優先しているので、mynetworksからのリレーを許可しているが宛先を$mydestination, softbank.ne.jpに制限している。</p>
]]></content:encoded>
			<wfw:commentRss>http://pooh.gr.jp/?feed=rss2&#038;p=9696</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>postfixでclamav-milter</title>
		<link>http://pooh.gr.jp/?p=9694</link>
		<comments>http://pooh.gr.jp/?p=9694#comments</comments>
		<pubDate>Wed, 02 May 2012 15:25:25 +0000</pubDate>
		<dc:creator>shinago</dc:creator>
				<category><![CDATA[Linux]]></category>

		<guid isPermaLink="false">http://pooh.gr.jp/?p=9694</guid>
		<description><![CDATA[ClamAVのインストールは次を参照。 ウイルス対策ClamAVをインストールする（milter対応） http://pooh.gr.jp/?p=9681 clamav-milterの設定は次を参照。 メールサーバのウイルス対策clamav-milter http://pooh.gr.jp/?p=9691 smtpd_milters, non_smtp_miltersにclamav-milterを指定する。 cp -a /etc/postfix/main.cf /etc/postfix/main.cf.$( date '+%Y%m%d%H%M%S' ) cat &#60;&#60; 'EOF' &#62;&#62; /etc/postfix/main.cf...]]></description>
			<content:encoded><![CDATA[<p>ClamAVのインストールは次を参照。<br />
ウイルス対策ClamAVをインストールする（milter対応）<br />
<a href="http://pooh.gr.jp/?p=9681">http://pooh.gr.jp/?p=9681</a></p>
<p>clamav-milterの設定は次を参照。<br />
メールサーバのウイルス対策clamav-milter<br />
<a href="http://pooh.gr.jp/?p=9691">http://pooh.gr.jp/?p=9691</a></p>
<p>smtpd_milters, non_smtp_miltersにclamav-milterを指定する。</p>
<pre>cp -a /etc/postfix/main.cf /etc/postfix/main.cf.$( date '+%Y%m%d%H%M%S' )
cat &lt;&lt; 'EOF' &gt;&gt; /etc/postfix/main.cf

smtpd_milters = unix:/var/run/clamav/clamav-milter.socket
non_smtpd_milters = unix:/var/run/clamav/clamav-milter.socket
milter_default_action = accept
EOF</pre>
]]></content:encoded>
			<wfw:commentRss>http://pooh.gr.jp/?feed=rss2&#038;p=9694</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>メールサーバのウイルス対策clamav-milter</title>
		<link>http://pooh.gr.jp/?p=9691</link>
		<comments>http://pooh.gr.jp/?p=9691#comments</comments>
		<pubDate>Tue, 01 May 2012 23:35:30 +0000</pubDate>
		<dc:creator>shinago</dc:creator>
				<category><![CDATA[Linux]]></category>

		<guid isPermaLink="false">http://pooh.gr.jp/?p=9691</guid>
		<description><![CDATA[ClamAVのインストールは次を参照。 ウイルス対策ClamAVをインストールする（milter対応） http://pooh.gr.jp/?p=9681 clamdを設定と起動スクリプトを作成する。 cp -a /usr/local/clamav/etc/clamd.conf /usr/local/clamav/etc/clamd.conf.orig sed -i \ -e '/^Example$/s/^/#/' \ -e 's/^#LogFile \/tmp\/clamd.log$/LogFile \/var\/log\/clamav\/clamd.log/' \ -e...]]></description>
			<content:encoded><![CDATA[<p>ClamAVのインストールは次を参照。<br />
ウイルス対策ClamAVをインストールする（milter対応）<br />
<a href="http://pooh.gr.jp/?p=9681">http://pooh.gr.jp/?p=9681</a></p>
<p>clamdを設定と起動スクリプトを作成する。</p>
<pre>cp -a /usr/local/clamav/etc/clamd.conf /usr/local/clamav/etc/clamd.conf.orig
sed -i \
 -e '/^Example$/s/^/#/' \
 -e 's/^#LogFile \/tmp\/clamd.log$/LogFile \/var\/log\/clamav\/clamd.log/' \
 -e 's/^#LogFileMaxSize 2M/LogFileMaxSize 0/' \
 -e 's/^#LogTime yes$/LogTime yes/' \
 -e 's/^#PidFile \/var\/run\/clamd.pid$/PidFile \/var\/run\/clamav\/clamd.pid/' \
 -e '/^#DatabaseDirectory \/var\/lib\/clamav$/s/^#//' \
 -e 's/^#LocalSocket \/tmp\/clamd.socket/LocalSocket \/var\/run\/clamav\/clamd.socket/' \
 -e 's/^#User clamav$/User clamav/' \
 /usr/local/clamav/etc/clamd.conf

cat &lt;&lt; 'EOF' &gt; /etc/rc.d/init.d/clamd
#!/bin/bash
#
# chkconfig: 2345 61 39
# description: clamd an anti-virus daemon.
# processname: clamd
# config: /usr/local/clamav/etc/clamd.conf
# pidfile: /var/run/clamav/clamd.pid

# Source function library.
. /etc/rc.d/init.d/functions

[ -f /usr/local/clamav/etc/clamd.conf ] || exit 1

CLAMD=/usr/local/clamav/sbin/clamd
PROG=clamd
PIDFILE=/var/run/clamav/clamd.pid
LOCKFILE=/var/lock/subsys/clamd
RETVAL=0

start(){
        echo -n $"Starting ${PROG}:"
        daemon ${CLAMD}
        RETVAL=${?}
        echo
        [ ${RETVAL} = 0 ] &amp;&amp; touch ${LOCKFILE}
        return ${RETVAL}
}

stop(){
        echo -n "Shutting down ${PROG}:"
        killproc -p ${PIDFILE} -d 10 ${CLAMD}
        RETVAL=${?}
        echo
        [ ${RETVAL} = 0 ] &amp;&amp; rm -f ${LOCKFILE}
        return ${RETVAL}
}

case "${1}" in
        start)
                start
                ;;
        stop)
                stop
                ;;
        status)
                status -p ${PIDFILE} ${CLAMD}
                RETVAL=${?}
                ;;
        restart|reload)
                stop
                start
                ;;
        condrestart)
                if [ -f ${PIDFILE} ] ; then
                        stop
                        start
                fi
                ;;
        *)
                echo $"Usage: ${PROG} {start|stop|restart|condrestart|reload|status}"
                exit 1
esac

exit ${RETVAL}
EOF

chmod +x /etc/rc.d/init.d/clamd
/sbin/service clamd start
/sbin/chkconfig clamd on</pre>
<p>clamav-milterを設定して起動スクリプトを作成する。</p>
<pre>cp -a /usr/local/clamav/etc/clamav-milter.conf /usr/local/clamav/etc/clamav-milter.conf.orig
sed -i \
 -e '/^Example$/s/^/#/' \
 -e 's/^#MilterSocket \/tmp\/clamav-milter.socket$/MilterSocket \/var\/run\/clamav\/clamav-milter.socket/' \
 -e '/^#User clamav$/s/^#//' \
 -e 's/^#PidFile \/var\/run\/clamav-milter.pid$/PidFile \/var\/run\/clamav\/clamav-milter.pid/' \
 -e 's/^#ClamdSocket tcp:scanner.mydomain:7357$/ClamdSocket unix:\/var\/run\/clamav\/clamd.socket/' \
 -e 's/^#LogFile \/tmp\/clamav-milter.log$/LogFile \/var\/log\/clamav\/clamav-milter.log/' \
 -e 's/^#LogFileMaxSize 2M$/LogFileMaxSize 0/' \
 -e '/^#LogTime yes$/s/^#//' \
 -e '/^#LogInfected Basic$/s/^#//' \
 /usr/local/clamav/etc/clamav-milter.conf

cat &lt;&lt; 'EOF' &gt; /etc/rc.d/init.d/clamav-milter
#!/bin/sh
#
# clamav-milter This script starts and stops the clamav-milter daemon
#
# chkconfig: 2345 79 40
#
# description: clamav-milter is a daemon which hooks into sendmail and routes \
#              email messages for virus scanning with ClamAV
# processname: clamav-milter
# pidfile: /var/lock/subsys/clamav-milter

# Source function library.
. /etc/rc.d/init.d/functions

# Source networking configuration.
. /etc/sysconfig/network

# Local clamav-milter config
CLAMAV_FLAGS=
test -f /etc/sysconfig/clamav-milter &amp;&amp; . /etc/sysconfig/clamav-milter

# Check that networking is up.
[ ${NETWORKING} = "no" ] &amp;&amp; exit 0

[ -x /usr/local/clamav/sbin/clamav-milter ] || exit 0
PATH=$PATH:/usr/bin:/usr/local/clamav/sbin:/usr/local/clamav/bin

RETVAL=0

# Clamav-milter must have write access to the pid file, /var/run is not suitable
default_pidfile=
[ -d /var/run/clamav-milter ] &amp;&amp; default_pidfile=/var/run/clamav-milter/clamav-milter.pid
[ -d /var/clamav ] &amp;&amp; default_pidfile=/var/clamav/clamav-milter.pid
pidfile=${PIDFILE:-$default_pidfile}

lockfile=/var/lock/subsys/clamav-milter

start() {
        echo -n "Starting clamav-milter: "
        # Don't allow files larger than 25M to be created, to limit DoS
        # Needs to be large enough to extract the signature files
        ulimit -f 25600
        if [ ! -z $pidfile ]; then
                CLAMAV_PID=--pidfile=${pidfile}
                PID=`pidofproc -p ${pidfile} clamav-milter`
        else
                CLAMAV_PID=
                PID=`pidofproc clamav-milter`
        fi
        [ -n "$PID" ] &amp;&amp; echo " already running!" &amp;&amp; return 1
        LANG= daemon clamav-milter $CLAMAV_PID ${CLAMAV_FLAGS}
        chgrp postfix /var/run/clamav/clamav-milter.socket
        chmod g+w /var/run/clamav/clamav-milter.socket
        RETVAL=$?
        [ ! -z $pidfile -a -f $pidfile ] &amp;&amp; sed -i -e 's/-//' $pidfile
        echo
        test $RETVAL -eq 0 &amp;&amp; touch ${lockfile}
        return $RETVAL
}

stop() {
        echo -n "Shutting down clamav-milter: "
        if [ ! -z $pidfile ]; then
                killproc -p ${pidfile} clamav-milter
        else
                killproc clamav-milter
        fi
        RETVAL=$?
        echo
        test $RETVAL -eq 0 &amp;&amp; rm -f ${lockfile} ${pidfile}
}

restart() {
        stop
        start
}

# See how we were called.
case "$1" in
  start)
        # Start daemon.
        start
        ;;
  stop)
        # Stop daemon.
        stop
        ;;
  restart|reload)
        restart
        ;;
  condrestart)
        test -f ${lockfile} &amp;&amp; $0 restart || :
        ;;
  status)
        if [ ! -z $pidfile ]; then
                status -p ${pidfile} clamav-milter
        else
                status clamav-milter
        fi
        ;;
  *)
        echo "Usage: $0 {start|stop|reload|restart|condrestart|status}"
        exit 1
esac

exit $?
EOF

chmod +x /etc/rc.d/init.d/clamav-milter
/sbin/service clamav-milter start
/sbin/chkconfig clamav-milter on</pre>
]]></content:encoded>
			<wfw:commentRss>http://pooh.gr.jp/?feed=rss2&#038;p=9691</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Macでバックスラッシュを入力する</title>
		<link>http://pooh.gr.jp/?p=9687</link>
		<comments>http://pooh.gr.jp/?p=9687#comments</comments>
		<pubDate>Tue, 24 Apr 2012 17:35:02 +0000</pubDate>
		<dc:creator>shinago</dc:creator>
				<category><![CDATA[Mac]]></category>

		<guid isPermaLink="false">http://pooh.gr.jp/?p=9687</guid>
		<description><![CDATA[Macでは¥（円マーク）と\（バックスラッシュ）が区別されている。 \はOptionキー+¥キー ¥はOptionキー+Yキー]]></description>
			<content:encoded><![CDATA[<p>Macでは¥（円マーク）と\（バックスラッシュ）が区別されている。</p>
<p>\はOptionキー+¥キー<br />
¥はOptionキー+Yキー</p>
]]></content:encoded>
			<wfw:commentRss>http://pooh.gr.jp/?feed=rss2&#038;p=9687</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

