搜尋此網誌

2019/9/9

[資安新聞]台中資安危機 逾千中製監視器藏校園

https://www.epochtimes.com.tw/n291507/%E5%8F%B0%E4%B8%AD%E8%B3%87%E5%AE%89%E5%8D%B1%E6%A9%9F-%E9%80%BE%E5%8D%83%E4%B8%AD%E8%A3%BD%E7%9B%A3%E8%A6%96%E5%99%A8%E8%97%8F%E6%A0%A1%E5%9C%92.html

被行政院與國安會列入禁止採購黑名單的「海康威視」,日前在台中市區多處地下道現形後,引發市民不安與關注。台中市議員黃守達日前發函市府要求各局處全面盤點、結果揭曉,警察局回覆重要路口無架設中製監視器,交通局、建設局表示已全數汰換為台製監視器,但還有1,599支藏在34所學校裡。

[資安新聞]Google揭多個iOS漏洞指iPhone用戶長期受攻擊,Apple:沒這麼嚴重

https://www.ithome.com.tw/news/132927

Apple發出官方聲明,反駁Google日前揭露iOS一系列漏洞時,稱這些漏洞被用來發動有史以來針對iPhone用戶最大規模攻擊的說法,Apple表示,使用這些漏洞進行的攻擊複雜且狹隘,並經過調查,駭客主要發動攻擊的時間僅有2個月,非Google所暗示的2年。


[資安新聞]Exim 伺服器再傳根權限RCE漏洞

https://ithome.com.tw/news/132935

Exim維護團隊在接獲研究人員的安全通報後,於9月初釋出4.92.2版以修補漏洞,提醒用戶應盡快捨棄4.92.1以前的舊版軟體並完成更新

[資安新聞]開源安全測試框架Metasploit嵌入BlueKeep攻擊程式

https://www.ithome.com.tw/news/132949

在開源測試框架中嵌入這個針對舊版Windows遠端桌面服務缺陷所打造的攻擊程式,固然可能遭駭客利用,但Metasploit管理方Rapid7認為,此舉對防禦方來說是利大於弊

2018/1/28

[vmware][centos6]vmsvc [warning] [guestinfo] RecordRoutingInfo: Unable to collect IPv4 routing table

在從vm template轉vm時遇到了
vmsvc [warning] [guestinfo] RecordRoutingInfo: Unable to collect IPv4 routing table

找了一下網路的資源,後來想了一下有可能是因為新deploy主機有資訊沒清乾淨,產生新mac,所以對應的網路卡改變了
先去將下面位置的檔案清乾淨,再把network restart就正常了
/etc/udev/rules.d/70-persistent-net.rules

2017/3/15

[powershell]如何使用powershell ise來編輯vmware powercli

1、開啟PowerShell ISE

2、執行下面語法:
New-Item -Path $Profile -ItemType file -Force
notepad $profile

3、將下面的值填入記事本內:
& 'C:\Program Files (x86)\VMware\Infrastructure\vSphere PowerCLI\Scripts\Initialize-PowerCLIEnvironment.ps1'
不過我的路徑是
C:\Program Files (x86)\VMware\Infrastructure\PowerCLI\Scripts\Initialize-PowerCLIEnvironment.ps1
跟官方給的路徑不一樣,所以使用前要確認

最後重啟powershell ise就完成了

參考資料
http://www.virten.net/2016/07/how-to-properly-initialize-powercli-6-x-in-powershell-ise/

2016/11/3

[linux]Centos/Redhat 6/7 更改hostname方式

Centos/Redhat 6
vi /etc/sysconfig/network

CentOS/RedHat 7
hostnamectl set-hostname 名稱


2016/10/11

[bash]將資料夾內全部檔案做md5並輸出成檔案

find -type f -exec md5sum "{}" + > checklist.chk

[excel]IP2LONG語法

將ip轉成整數後比對範圍,比字串比對效率高的多,看到有網站說明如何轉換的語法,還有sql的語法
http://vcert.blogspot.tw/2013/04/ip2long-and-long2ip-in-excel.html

EXCEL:
=MID(D1,1,FIND("|",SUBSTITUTE(D1,".","|",1))-1)*2^24+MID(D1,FIND("|",SUBSTITUTE(D1,".","|",1))+1,FIND("|",SUBSTITUTE(D1,".","|",2))-FIND("|",SUBSTITUTE(D1,".","|",1))-1)*2^16+MID(D1,FIND("|",SUBSTITUTE(D1,".","|",2))+1,FIND("|",SUBSTITUTE(D1,".","|",3))-FIND("|",SUBSTITUTE(D1,".","|",2))-1)*2^8+MID(D1,FIND("|",SUBSTITUTE(D1,".","|",3))+1,4)


2016/9/28

[python]設定timezone及取時間

我的python有點弱找了一陣子,感覺最簡單的方式算是這樣使用了
筆記一下
import pytz, datetime

tz=pytz.timezone('Asia/Taipei')
dt=datetime.datetime.now(tz)
print dt.strftime("%b %d %H:")
http://strftime.org/
如果要

CodeMeaningExample
%aWeekday as locale’s abbreviated name.Mon
%AWeekday as locale’s full name.Monday
%wWeekday as a decimal number, where 0 is Sunday and 6 is Saturday.1
%dDay of the month as a zero-padded decimal number.30
%-dDay of the month as a decimal number. (Platform specific)30
%bMonth as locale’s abbreviated name.Sep
%BMonth as locale’s full name.September
%mMonth as a zero-padded decimal number.09
%-mMonth as a decimal number. (Platform specific)9
%yYear without century as a zero-padded decimal number.13
%YYear with century as a decimal number.2013
%HHour (24-hour clock) as a zero-padded decimal number.07
%-HHour (24-hour clock) as a decimal number. (Platform specific)7
%IHour (12-hour clock) as a zero-padded decimal number.07
%-IHour (12-hour clock) as a decimal number. (Platform specific)7
%pLocale’s equivalent of either AM or PM.AM
%MMinute as a zero-padded decimal number.06
%-MMinute as a decimal number. (Platform specific)6
%SSecond as a zero-padded decimal number.05
%-SSecond as a decimal number. (Platform specific)5
%fMicrosecond as a decimal number, zero-padded on the left.000000
%zUTC offset in the form +HHMM or -HHMM (empty string if the the object is naive).
%ZTime zone name (empty string if the object is naive).
%jDay of the year as a zero-padded decimal number.273
%-jDay of the year as a decimal number. (Platform specific)273
%UWeek number of the year (Sunday as the first day of the week) as a zero padded decimal number. All days in a new year preceding the first Sunday are considered to be in week 0.39
%WWeek number of the year (Monday as the first day of the week) as a decimal number. All days in a new year preceding the first Monday are considered to be in week 0.39
%cLocale’s appropriate date and time representation.Mon Sep 30 07:06:05 2013
%xLocale’s appropriate date representation.09/30/13
%XLocale’s appropriate time representation.07:06:05
%%A literal '%' character.%

[資安]CVE-2016-6662 mysql、mariadb

都忘記發文了,
主要是CVE-2016-6662這個漏洞,最先公告的地方是這網站
http://legalhackers.com/advisories/MySQL-Exploit-Remote-Root-Code-Execution-Privesc-CVE-2016-6662.txt
簡中版
http://bobao.360.cn/learning/detail/3027.html
影響範圍
MySQL  <= 5.7.14       Remote Root Code Execution / Privilege Escalation (0day)
   5.6.32
    5.5.51

MySQL clones are also affected, including:

MariaDB
PerconaDB 
但底下的III. INTRODUCTION寫了
The vulnerability affects all MySQL servers in default configuration in all 
version branches (5.7, 5.6, and 5.5) including the latest versions, and could 
be exploited by both local and remote attackers. 
Both the authenticated access to MySQL database (via network connection or web 
interfaces such as phpMyAdmin) and SQL Injection could be used as exploitation 
vectors.

看起來是全系列都受影響,但測試舊版的rhel6 mysql、rhel5 mysql發現並無my.cnf內沒有mysqld_safe的相關設定,所以只影響到新版包含使用mysql source code fork出去的資料庫

基本上漏洞使用的方式就是分2種
1、有帳號
使用此漏洞可以修改my.cnf,可以控制my.cnf
2、沒帳號
使用trigger,讓mysql在flush時觸發後提權帳號,再控制my.cnf

暫態解法
https://www.psce.com/blog/2016/09/12/how-to-quickly-patch-mysql-server-against-cve-2016-6662/
https://dev.mysql.com/doc/refman/5.5/en/mysqld-safe.html#option_mysqld_safe_malloc-lib
https://github.com/percona/percona-server/commit/c14be53e029442f576cced1fb8ff96b58e89f2e0#diff-144aa2f11374843c969d96b7b84247eaR261
暫時性可以用的解法在mysql官方還沒正式更新前,就是用github裡的方式,指定可以載入lib的目錄,非這些目錄的不可以載入


http://bobao.360.cn/learning/detail/3026.html
http://www.ithome.com.tw/news/108454
http://avfisher.win/archives/tag/mysql
http://legalhackers.com/exploits/0ldSQL_MySQL_RCE_exploit.py

[分享]南港推拿~ "奕霖損傷整復"

自從工作後,運動時間越來越短受傷機率越來越大
到了台北後,腳扭傷了也不知道去那看又怕治不好囧
在偶然之間,找到了一間還不錯的醫生,離租屋處又近
傷了近十年的大拇指,就在這裡一次處理好了~(噴淚
收費方式是看藥布大小而定~~
推薦給大家
真的很不錯,整個球隊、公司打球的朋友、朋友的朋友也都來這裡看了~~超棒的
喔,對了,腰傷的話,通常要帶X光片去給奕霖,要不然可能不會推喔



2016/8/15

openssl安全性掃描網站

https://www.ssllabs.com/ssltest/

HOSTNAME:輸入要測試的IP

[ubuntu16.4]fcitx安裝嘸蝦米中文輸入法

新酷音輸入法
$ sudo apt-get install fcitx-chewing
無蝦米輸入法
$ sudo apt-get install fcitx-table-boshiamy
倉頡輸入法
$ sudo apt-get install fcitx-table-cangjie5
日文輸入法
$ sudo apt-get install fcitx-anthy

2016/8/4

[資安新聞〕8款來自 BlackHat 2016 的安全工具

標題:8款來自 BlackHat 2016 的安全工具

摘要:
一年一度的美國黑帽大會(Black Hat USA 2016)在拉斯維加斯曼德勒海灣酒店(Mandalay Bay)順利舉行。除了披露重大安全漏洞外,先進的工具展示過程也是大會必不可少的精彩環節。

1. Infection Monkey:
Infection Monkey是一個數據中心滲透測試工具,通過啟動數據中心中隨機散佈的部分受感染虛擬機,以測試整個網絡安全鏈中的潛在盲點,幫助安全團隊提升數據中心的安全恢復能力。

2. Project Delta:
在幫助滲透測試人員嗅探SDN的安全性。該工具包含一個識別OpenFlow路由器安全性能和控制器部署的框架,還包括一個專門定制的模糊測試模塊,以發現SDN網絡中的未知安全漏洞。

3. Ablation:
作為一種靜態分析輔助工具,能夠從執行進程中抽取數據。它的目的是簡化逆向工程流程,幫助研究人員對比樣本代碼而不僅僅是比較數據。

4. Keystone Engine:
新型逆向工程工具,旨在幫助研究人員更容易的選擇安全軟件。

5. AVLeak:
幫助AVLeak用戶偵測出一台機器上是否安裝了反病毒模擬器,進而優化惡意攻擊軟件,使其不被反病毒軟件發現。

6. Swizzler:
移動安全研究員Vincent Tan選擇重新拾起擱置已久的Swizzler,重新開發了該工具以支持移動應用滲透測試人員所需的各種功能。

7. DPTrace:
開源工具DPtrace ~ 半自動的崩潰分析框架,該工具可以幫助研究者在系統崩潰的瞬間掃描輸入區域的映射,分析代碼執行的潛在影響。

8. BLE MITM Proxy:
BLE MITM Proxy是一款開源工具,能夠在樹莓派(Raspberry Pi)中加載運行,通過開發、逆向工程以及調試幫助探測藍牙低功耗設備。

引用來源:
http://www.freebuf.com/sectool/111065.html

原始資料:
http://www.darkreading.com/vulnerabilities---threats/8-bad-ass-tools-coming-out-of-black-hat/d/d-id/1326444

2016/7/25

[linux]could not be found in rpmdb

遇到問題
Setting up Upgrade Process
Error: Package tuple ('openssl-devel', 'x86_64', '0', '1.0.1e', '42.el6_7.4') could not be found in rpmdb


解決方式
1、yum clean all
2、rpmdb --rebuilddb