Gradle 初探
如何用 gradle 建立專案
如何用 gradle 建立專案
有沒有var差很大啊,要注意 Output is “7” $(document).ready(function () { x = 6; }); $(document).ready(function () { x = 7; }); $(document).ready(function () { alert(x); }); x is not defined $(document).ready(function () { var x = 6; }); $(document).ready(function () { var x = 7; }); $(document).ready(function () { alert(x); });
2013 開放 Web 軟體安全計畫 – Open Web Application Security Project https://www.owasp.org/index.php/Top_10_2013-Top_10 網站安全標準須防止 OWASP (開放Web軟體安全計畫 – Open Web Application Security Project)十大Web資安漏洞,其安全要求表列入下。 A1 - Injection (注入攻擊): A2 - Broken Authentication and Session Management (失效的驗證與連線管理): A3 - Cross-Site Scripting(XSS) (跨站腳本程式攻擊): A4 - Insecure Direct Object References (不安全的物件參考): A5 - Security Misconfiguration (不當的安全組態設定): A6 - Sensitive Data Exposure (敏感資料暴露): A7 - Missing Function Level Access Control (缺少功能級別的存取控制): A8 - Cross Site Request Forgery (CSRF) (跨站冒名請求): A9 - Using Components with Known Vulnerabilities(使用已知漏洞元件): A10 - Unvalidated Redirects and Forwards (未經驗證的重新導向與轉送): Top 10 A1 - Injection (注入攻擊): 注入攻擊可說是目前最普遍的網站應用程式的攻擊手法 ...
Postfix 介紹 Postfix 是一套快速, 安全及容易管理的開源 Mail Transfer Agent (MTA), 也是 Sendmail 很好的替代品。 以下會介紹在 RHEL 及 CentOS 7 安裝 Postfix 及 Dovecot 作為 Email Server. 安裝 前置作業 在開始前, 如果系統內安裝了其他 MTA (例如 Sendmail 或 Exim), 那便需要將它們移除, 以下是移除 Sendmail 及 Exim 的方法: 查詢是否安裝過 rpm -qa | grep sendmail rpm -qa | grep exim 移除 yum remove sendmail yum remove exim 為了使安裝過程簡單一點, 關閉 SELinux, 開啟 /etc/sysconfig/selinux, 將: SELINUX=enforcing 換成 SELINUX=disabled 重開機後生效 開始安裝 Postfix yum install postfix ...
新增 nginx.repo vi /etc/yum.repos.d/nginx.repo [nginx] name=nginx repo baseurl=http://nginx.org/packages/mainline/centos/$releasever/$basearch/ gpgcheck=0 enabled=1 安裝Nginx yum install nginx 啟動服務 service nginx start chkconfig --levels 235 nginx on
一、更新rpm REMI源 (最新的PHP版本需要修改REMI.REPO中的ENABLED=0為1) vi /etc/yum.repos.d/remi.repo CentOS 6 yum install http://rpms.famillecollet.com/enterprise/remi-release-6.rpm CentOS 7 yum install http://rpms.famillecollet.com/enterprise/remi-release-7.rpm 二、安裝 PHP 想install其它版本的PHP需要修改REMI.REPO中的ENABLED=0為1 路徑:/etc/yum.repos.d/remi.repo [remi-php55]是PHP5.5 [remi-php56]是PHP5.6 選擇你要的版本做修改即可 vi /etc/yum.repos.d/remi.repo 安裝 PHP yum install php 安裝其他 PHP Lib yum install php-mysql php-gd libjpeg* php-imap php-ldap php-odbc php-pear php-xml php-xmlrpc php-mbstring php-mcrypt php-bcmath php-mhash libmcrypt libmcrypt-devel php-fpm 設定 php, php-fpm 設定 php 設定內容如下(/etc/php.ini): cgi.fix_pathinfo=0 session.save_handler = files session.save_path = "/var/lib/php/session" date.timezone = "Asia/Taipei" error_reporting = E_ALL & ~E_NOTICE display_errors = On magic_quotes_gpc = Off 設定 php session 檔的權限 mkdir /var/lib/php/session ...
Nexus OSS Nexus OSS是用來架設maven私有倉庫的好幫手 安裝其實非常容易 下載網址 下載至您要放置的目錄下即可開始操作以下流程 (這裡放置在/usr/local) tar zxvf nexus-2.11.4-01-bundle.tar.gz ln -s nexus-2.11.4-01/ nexus chown -R nexus:nexus nexus chown -R nexus:nexus nexus-2.11.4-01/ chown -R nexus:nexus sonatype-work/ 修改下面兩個設定 vi /nexus-2.11.4-01/bin/nexus NEXUS_HOME="/usr/local/nexus/nexus" RUN_AS_USER=nexus 修改Port vi /nexus-2.11.4-01/conf/nexus.properties application-port=18081 啟動 sh /var/opt/nexus/nexus/bin/nexus start