How to prevent DDoS attack on nginx?
Suppose you have a nginx container running by Docker on your server and you noticed some DDoS traffics. The first thing you might think about is to block the attacker’s IP addresses. You might use iptables to block the identified IP addresses. However, this might not work as you expected because docker isn’t very friendly with iptables. Another aspect is that DDoS means the attacker can use lots of different IP addresses to attack. In fact, there are even tools that help attackers perform DDo...
How to prevent DDoS attack on nginx?
Suppose you have a nginx container running by Docker on your server and you noticed some DDoS traffics. The first thing you might think about is to block the attacker’s IP addresses. You might use iptables to block the identified IP addresses. However, this might not work as you expected because docker isn’t very friendly with iptables. Another aspect is that DDoS means the attacker can use lots of different IP addresses to attack. In fact, there are even tools that help attackers perform DDo...
以太坊估值思考 (1)
要了解比特币的价值,需要懂货币和财富。而要了解以太坊的价值需要先搞懂Web3.0,和半个DeFi。以太坊的价值绝大程度上取决于Web3.0的价值,小部分取决于DeFi的价值。今天先主要讨论Web3.0的部分。 假设www是一家公司,现在(2022)所有的科技公司总市值为20万亿美金,如何来对www进行估值?不妨这样来想,如果你拥有这20万亿中价值1万亿的一家公司,你是否愿意花2千亿买下www这家公司?如果是我,我肯定是愿意的。如果是5千亿呢?我也愿意,因为掌握了www就掌握了整个互联网生态的话语权。再进一步推理,我甚至愿意把我的公司直接卖掉来买www。所以www至少价值1万亿。那么如果我竞争对手的公司价值2万亿,他会看着我买下www吗?当然不会,甚至他也愿意卖掉他的公司来买www。以此类推,不难发现www这家公司的价值至少是等于所有互联网公司的总市值20万亿的。可以佐证的是,思科的CEO在2014年的时候也说过,他相信“the internet of everything”在接下来的十年会产生19万亿的经济效益。 过去十年是移动互联网的十年,如果未来Web3.0的地位等同于移动互...
以太坊估值思考 (1)
要了解比特币的价值,需要懂货币和财富。而要了解以太坊的价值需要先搞懂Web3.0,和半个DeFi。以太坊的价值绝大程度上取决于Web3.0的价值,小部分取决于DeFi的价值。今天先主要讨论Web3.0的部分。 假设www是一家公司,现在(2022)所有的科技公司总市值为20万亿美金,如何来对www进行估值?不妨这样来想,如果你拥有这20万亿中价值1万亿的一家公司,你是否愿意花2千亿买下www这家公司?如果是我,我肯定是愿意的。如果是5千亿呢?我也愿意,因为掌握了www就掌握了整个互联网生态的话语权。再进一步推理,我甚至愿意把我的公司直接卖掉来买www。所以www至少价值1万亿。那么如果我竞争对手的公司价值2万亿,他会看着我买下www吗?当然不会,甚至他也愿意卖掉他的公司来买www。以此类推,不难发现www这家公司的价值至少是等于所有互联网公司的总市值20万亿的。可以佐证的是,思科的CEO在2014年的时候也说过,他相信“the internet of everything”在接下来的十年会产生19万亿的经济效益。 过去十年是移动互联网的十年,如果未来Web3.0的地位等同于移动互...
How does Metamask generate your accounts with the 12 words?
First let’s distinguish the difference between seed and mnemonic phrase. Those words are often used interchangeably. But if we refer to BIP-32, seed is just a byte sequence such as 000102030405060708090a0b0c0d0e0f. On the other hand, mnemonic phrase is a list of selected words, which are designed to be easy to remember, to help generate the seed. This was first introduced at BIP-39. Going back to BIP-32, we can see how a seed can be used to deterministically generate a sequence of bitcoin wal...
How does Metamask generate your accounts with the 12 words?
First let’s distinguish the difference between seed and mnemonic phrase. Those words are often used interchangeably. But if we refer to BIP-32, seed is just a byte sequence such as 000102030405060708090a0b0c0d0e0f. On the other hand, mnemonic phrase is a list of selected words, which are designed to be easy to remember, to help generate the seed. This was first introduced at BIP-39. Going back to BIP-32, we can see how a seed can be used to deterministically generate a sequence of bitcoin wal...