{"id":5808,"date":"2019-11-08T09:33:52","date_gmt":"2019-11-08T00:33:52","guid":{"rendered":"https:\/\/east19-mikas.com\/?p=5808"},"modified":"2024-08-21T10:54:42","modified_gmt":"2024-08-21T01:54:42","slug":"centos8%e3%81%abwaf","status":"publish","type":"post","link":"https:\/\/east19-mikas.com\/mpat\/?p=5808","title":{"rendered":"CentOS8\u306bWAF"},"content":{"rendered":"\n<h2 class=\"wp-block-heading\">CentOS8\u74b0\u5883\u306bWAF(modsecurity)\u3092\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3057\u307e\u3057\u305f<\/h2>\n\n\n\n<p>\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u65b9\u6cd5\u306f\u4e0b\u8a18\u306b\u8a18\u3057\u307e\u3059<\/p>\n\n\n\n<p class=\"has-white-color has-text-color has-background has-link-color wp-elements-34f38761f23e111cc7cf6bf57024fde1\" style=\"background-color:#444444\"># <span id=\"yelo\">yum install mod_security mod_security_crs<\/span><br>\u30e1\u30bf\u30c7\u30fc\u30bf\u306e\u671f\u9650\u5207\u308c\u306e\u6700\u7d42\u78ba\u8a8d: 0:25:46 \u6642\u9593\u524d\u306e 2019\u5e7411\u670807\u65e5 14\u664237\u520632\u79d2 \u306b\u5b9f\u65bd\u3057\u307e\u3057\u305f\u3002<br>\u4f9d\u5b58\u95a2\u4fc2\u304c\u89e3\u6c7a\u3057\u307e\u3057\u305f\u3002<br>================================================================================<br> \u30d1\u30c3\u30b1\u30fc\u30b8             \u30a2\u30fc\u30ad\u30c6\u30af\u30c1\u30e3\u30fc<br>                                     \u30d0\u30fc\u30b8\u30e7\u30f3           \u30ea\u30dd\u30b8\u30c8\u30ea      \u30b5\u30a4\u30ba<br>================================================================================<br>Installing:<br> mod_security           x86_64       2.9.2-8.el8          AppStream       267 k<br> mod_security_crs       noarch       3.0.0-5.el8          AppStream       127 k<br>\u4f9d\u5b58\u95a2\u4fc2\u3092\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u4e2d:<br> yajl                   x86_64       2.1.0-10.el8         AppStream        41 k<br><br>\u30c8\u30e9\u30f3\u30b6\u30af\u30b7\u30e7\u30f3\u306e\u6982\u8981<br>================================================================================<br>\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb  3 \u30d1\u30c3\u30b1\u30fc\u30b8<br><br>\u30c0\u30a6\u30f3\u30ed\u30fc\u30c9\u30b5\u30a4\u30ba\u306e\u5408\u8a08: 435 k<br>\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u6e08\u307f\u306e\u30b5\u30a4\u30ba: 1.6 M<br>\u3053\u308c\u3067\u3088\u308d\u3057\u3044\u3067\u3059\u304b? [y\/N]: <span id=\"grlo\">y<\/span><br>\u30d1\u30c3\u30b1\u30fc\u30b8\u306e\u30c0\u30a6\u30f3\u30ed\u30fc\u30c9\u4e2d\u3067\u3059:<br>(1\/3): yajl-2.1.0-10.el8.x86_64.rpm              36 kB\/s |  41 kB     00:01    <br>(2\/3): mod_security_crs-3.0.0-5.el8.noarch.rpm   94 kB\/s | 127 kB     00:01    <br>(3\/3): mod_security-2.9.2-8.el8.x86_64.rpm      126 kB\/s | 267 kB     00:02    <br>&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8211;<br>\u5408\u8a08                                            128 kB\/s | 435 kB     00:03     <br>\u30c8\u30e9\u30f3\u30b6\u30af\u30b7\u30e7\u30f3\u306e\u78ba\u8a8d\u3092\u5b9f\u884c\u4e2d<br>\u30c8\u30e9\u30f3\u30b6\u30af\u30b7\u30e7\u30f3\u306e\u78ba\u8a8d\u306b\u6210\u529f\u3057\u307e\u3057\u305f\u3002<br>\u30c8\u30e9\u30f3\u30b6\u30af\u30b7\u30e7\u30f3\u306e\u30c6\u30b9\u30c8\u3092\u5b9f\u884c\u4e2d<br>\u30c8\u30e9\u30f3\u30b6\u30af\u30b7\u30e7\u30f3\u306e\u30c6\u30b9\u30c8\u306b\u6210\u529f\u3057\u307e\u3057\u305f\u3002<br>\u30c8\u30e9\u30f3\u30b6\u30af\u30b7\u30e7\u30f3\u3092\u5b9f\u884c\u4e2d<br>  \u6e96\u5099             :                                                        1\/1 <br>  Installing       : yajl-2.1.0-10.el8.x86_64                               1\/3 <br>  Installing       : mod_security-2.9.2-8.el8.x86_64                        2\/3 <br>  Installing       : mod_security_crs-3.0.0-5.el8.noarch                    3\/3 <br>  scriptlet\u306e\u5b9f\u884c\u4e2d: mod_security_crs-3.0.0-5.el8.noarch                    3\/3 <br>  \u691c\u8a3c             : mod_security-2.9.2-8.el8.x86_64                        1\/3 <br>  \u691c\u8a3c             : mod_security_crs-3.0.0-5.el8.noarch                    2\/3 <br>  \u691c\u8a3c             : yajl-2.1.0-10.el8.x86_64                               3\/3 <br><br>\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u6e08\u307f:<br>  mod_security-2.9.2-8.el8.x86_64      mod_security_crs-3.0.0-5.el8.noarch     <br>  yajl-2.1.0-10.el8.x86_64            <br><br>\u5b8c\u4e86\u3057\u307e\u3057\u305f!<\/p>\n\n\n\n<p>\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u5f8c\u3001Apache\u3092\u518d\u8d77\u52d5\u3057\u307e\u3059<\/p>\n\n\n\n<p class=\"has-white-color has-text-color has-background has-link-color wp-elements-3c25588e40298831d37a6e296c98c22d\" style=\"background-color:#444444\"># <span id=\"yelo\">systemctl restart httpd<\/span><\/p>\n\n\n\n<p>\u8a2d\u5b9a\u65b9\u6cd5\u306f\u5f8c\u65e5\uff08\u30c7\u30d5\u30a9\u30eb\u30c8\u3067\u5168\u3066\u306e\u30eb\u30fc\u30eb\u304c\u9069\u7528\u3055\u308c\u307e\u3059\u3002<\/p>\n\n\n\n<h2 class=\"wp-block-heading\" id=\"hh_h2\">\u30af\u30e9\u30a4\u30a2\u30f3\u30c8\u306eIP\u3092\u8a31\u53ef\u3059\u308b\u65b9\u6cd5<\/h2>\n\n\n\n<p>CentOS7\u3068\u306f\u8a2d\u5b9a\u65b9\u6cd5\u304c\u5909\u308f\u308a\u307e\u3057\u305f\u3002\u7528\u610f\u3055\u308c\u3066\u3044\u308b\u30ed\u30fc\u30ab\u30eb\u30eb\u30fc\u30eb\u306b\u3001\u5185\u5bb9\u3092\u8ffd\u8a18\u3057\u307e\u3059\u3002<br>\u4eca\u56de\u306f\u3001\u4f7f\u7528\u3057\u3066\u3044\u308b\u30ed\u30fc\u30ab\u30eb\u74b0\u5883\u306e\u4f7f\u7528\u3057\u3066\u3044\u308bIP\u3092\u8a31\u53ef\u3059\u308b\u8a2d\u5b9a\u3067\u3059\u3002<\/p>\n\n\n\n<p class=\"has-white-color has-text-color has-background has-link-color wp-elements-54113c79968101627a16ab5ffd505486\" style=\"background-color:#444444\"># <span id=\"yelo\">cd \/etc\/httpd\/modsecurity.d\/rocal_rules\/<\/span><br># <span id=\"yelo\">vi modsecurity_localrules.conf<\/span><br><span id=\"chal\">9\u884c\u76ee\u306b\u8ffd\u52a0<\/span><br>SecRule REMOTE_ADDR &#8220;@ipMatch 172.16.10.100&#8221; id:2000,phase:1,t:none,log,allow  \u30fb\u30fb\u30fb<span id=\"gylo\">\u4e00\u884c\u3067\u8a18\u8f09<\/span><br>\u30d5\u30a1\u30a4\u30eb\u3092\u4e0a\u66f8\u304d\u3057\u305f\u3089\u3001httpd\u30b5\u30fc\u30d3\u30b9\u3092\u518d\u8d77\u52d5\u3057\u307e\u3059\u3002<br># <span id=\"yelo\">systemctl restart httpd<\/span><\/p>\n\n\n\n<p>\u4ee5\u4e0a\u3067\u3001\u30ed\u30fc\u30ab\u30eb\u304b\u3089\u306e\u30a2\u30af\u30bb\u30b9\u306b\u306fmodsecurity\u30eb\u30fc\u30eb\u306f\u9069\u7528\u3055\u308c\u307e\u305b\u3093\u3002<\/p>\n","protected":false},"excerpt":{"rendered":"<p>CentOS8\u74b0\u5883\u306bWAF(modsecurity)\u3092\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3057\u307e\u3057\u305f \u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u65b9\u6cd5\u306f\u4e0b\u8a18\u306b\u8a18\u3057\u307e\u3059 # yum install mod_security mod_security_crs\u30e1\u30bf\u30c7\u30fc\u30bf\u306e\u671f\u9650\u5207\u308c\u306e\u6700 [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":7886,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"site-sidebar-layout":"default","site-content-layout":"","ast-site-content-layout":"default","site-content-style":"default","site-sidebar-style":"default","ast-global-header-display":"","ast-banner-title-visibility":"","ast-main-header-display":"","ast-hfb-above-header-display":"","ast-hfb-below-header-display":"","ast-hfb-mobile-header-display":"","site-post-title":"","ast-breadcrumbs-content":"","ast-featured-img":"","footer-sml-layout":"","ast-disable-related-posts":"","theme-transparent-header-meta":"","adv-header-id-meta":"","stick-header-meta":"","header-above-stick-meta":"","header-main-stick-meta":"","header-below-stick-meta":"","astra-migrate-meta-layouts":"default","ast-page-background-enabled":"default","ast-page-background-meta":{"desktop":{"background-color":"var(--ast-global-color-4)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""},"tablet":{"background-color":"","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""},"mobile":{"background-color":"","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""}},"ast-content-background-meta":{"desktop":{"background-color":"var(--ast-global-color-5)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""},"tablet":{"background-color":"var(--ast-global-color-5)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""},"mobile":{"background-color":"var(--ast-global-color-5)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""}},"footnotes":""},"categories":[9,13],"tags":[],"class_list":["post-5808","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-linux","category-server"],"_links":{"self":[{"href":"https:\/\/east19-mikas.com\/mpat\/index.php?rest_route=\/wp\/v2\/posts\/5808","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/east19-mikas.com\/mpat\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/east19-mikas.com\/mpat\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/east19-mikas.com\/mpat\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/east19-mikas.com\/mpat\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=5808"}],"version-history":[{"count":2,"href":"https:\/\/east19-mikas.com\/mpat\/index.php?rest_route=\/wp\/v2\/posts\/5808\/revisions"}],"predecessor-version":[{"id":8652,"href":"https:\/\/east19-mikas.com\/mpat\/index.php?rest_route=\/wp\/v2\/posts\/5808\/revisions\/8652"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/east19-mikas.com\/mpat\/index.php?rest_route=\/wp\/v2\/media\/7886"}],"wp:attachment":[{"href":"https:\/\/east19-mikas.com\/mpat\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=5808"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/east19-mikas.com\/mpat\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=5808"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/east19-mikas.com\/mpat\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=5808"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}