Linode Email 無法寄送的解法

Linode 於 2019/12/5 以後開得新帳號(原因:CAN-SPAM Act),連到外部 SMTP Port 預設都被擋掉,以至於全部 Connection timed out。

新開機器可以直接 telnet 測試看看:

$ telnet gmail-smtp-in.l.google.com 25
Trying 2404:6800:4008:c03::1b…
Trying 74.125.203.26…
telnet: Unable to connect to remote host: Connection timed out

正常狀況

$ telnet gmail-smtp-in.l.google.com 25
Trying 74.125.203.26…
Connected to gmail-smtp-in.l.google.com.
Escape character is '^]'.
220 mx.google.com ESMTP k2si12268129pld.364 - gsmtp

於 Postfix 的 /var/log/mail.log 會看到下述訊息:

Apr 29 12:47:24 localhost postfix/smtp[18520]: connect to gmail-smtp-in.l.google.com[74.125.203.27]:25: Connection timed out
Apr 29 12:47:24 localhost postfix/smtp[18521]: connect to gmail-smtp-in.l.google.com[108.177.97.27]:25: Connection timed out
Apr 29 12:47:24 localhost postfix/smtp[18523]: connect to gmail-smtp-in.l.google.com[64.233.189.26]:25: Connection timed out
Apr 29 12:47:54 localhost postfix/smtp[18523]: connect to alt1.gmail-smtp-in.l.google.com[108.177.9.27]:25: Connection timed out
Apr 29 12:48:24 localhost postfix/smtp[18523]: connect to alt2.gmail-smtp-in.l.google.com[209.85.234.26]:25: Connection timed out
Apr 29 12:48:54 localhost postfix/smtp[18522]: connect to alt3.gmail-smtp-in.l.google.com[142.250.11.27]:25: Connection timed out Apr 29 12:49:24 localhost postfix/smtp[18520]: connect to alt4.gmail-smtp-in.l.google.com[142.250.12.27]:25: Connection timed out

想要開通 Email 的 SMTP Port 需要做些設定,然後在於後台開 Ticket 申請。

閱讀全文〈Linode Email 無法寄送的解法〉

透過 LED燈控制器 來控制的殭屍網路

IoT 的設備現在越來越多,而 IoT 的設備重點在於大多都有連接網路,而有連接網路若資安沒有處理好,就會發生此新聞報導的類似問題。

  • 註:這個案例可以提供給 IoT 廠商用,設備的安全性很重要~

閱讀全文〈透過 LED燈控制器 來控制的殭屍網路〉

油價首次「負」值 跌到「負40美元」 - 2020

因為 新冠病毒(COVID-19) 的疫情關係,飛機不飛,甚至連出門都沒了(封城),全球原油的需求量已經減少 1/3,現在明顯供過於求。

不過,就算是需求減少,油價期貨為何會跌到變負數呢?

閱讀全文〈油價首次「負」值 跌到「負40美元」 - 2020〉

耳溫、額溫、腋溫、肛溫、口溫 判斷 發燒 的體溫溫度

體溫幾度被叫發燒呢?依照測量的方法不一樣,發燒的溫度認定也不一樣。

也有人本身體溫就低,發燒燒不起來的,37℃就叫發燒,也有本身體溫就高,38℃才叫發燒,所以還是因人而異,此篇紀錄幾個測量方式的發燒定義~

閱讀全文〈耳溫、額溫、腋溫、肛溫、口溫 判斷 發燒 的體溫溫度〉

PHP 如何為 json_encode 移除 Array Index

PHP 與 JavaScript 串接經常回傳 JSON 格式,但是會遇到 PHP 的 Array 預設 Index (Assoc array key reference index) 都會有 1、2、3 ...,要怎麼移除這 Index 在傳給 JavaScript 呢?

閱讀全文〈PHP 如何為 json_encode 移除 Array Index〉