File tree Expand file tree Collapse file tree 5 files changed +39
-5
lines changed Expand file tree Collapse file tree 5 files changed +39
-5
lines changed Original file line number Diff line number Diff line change @@ -253,6 +253,7 @@ Web 网关在一侧使用 HTTP 协议,另一次使用其他协议。通常可
253
253
- 词典攻击:密码猜测型攻击方式
254
254
- 恶意代理攻击和中间人攻击
255
255
- 选择明文攻击:在摘要认证的时候篡改随机数
256
+ - [ 中间人攻击] ( https://zh.wikipedia.org/wiki/%E4%B8%AD%E9%97%B4%E4%BA%BA%E6%94%BB%E5%87%BB )
256
257
257
258
需要解决的认证问题:
258
259
Original file line number Diff line number Diff line change @@ -650,12 +650,21 @@ $ date --date "2017-04-01" +%s # 将字符串类型日期输入,并转换格
650
650
%s
651
651
```
652
652
653
- ### 系统
653
+ ### Others
654
654
655
- 查看机器内网和外网 IP
655
+ - cURL
656
+
657
+ [ Linux命令行:cURL的十种常见用法] ( https://juejin.im/post/5915204b44d904006c463c61 )
658
+
659
+ - 查看机器内网和外网 IP
656
660
657
661
``` bash
658
662
$ hostname -I
659
663
# 内网 IP 外网 IP
660
664
```
661
665
666
+ ### 通过 bash 发送邮件
667
+
668
+ - [ 5 Ways to Send Email From Linux Command Line] ( https://tecadmin.net/ways-to-send-email-from-linux-command-line/ )
669
+ - [ 3 minute tip: Configure a Linux server to send email] ( https://rianjs.net/2013/08/send-email-from-linux-server-using-gmail-and-ubuntu-two-factor-authentication )
670
+ - [ “Mail” command hangs and maillogs shows error [ closed]] ( https://serverfault.com/questions/548771/mail-command-hangs-and-maillogs-shows-error )
Original file line number Diff line number Diff line change @@ -253,3 +253,12 @@ done
253
253
254
254
### 函数
255
255
256
+ ### Others
257
+
258
+ #### Check if file exists
259
+
260
+ ``` bash
261
+ if [ ! -f /tmp/foo.txt ]; then
262
+ echo " File not found!"
263
+ fi
264
+ ```
Original file line number Diff line number Diff line change 25
25
``` bash
26
26
# 创建新用户
27
27
# http://wiki.ubuntu.org.cn/%E6%96%B0%E5%BB%BA%E7%94%A8%E6%88%B7%E5%B9%B6%E6%B7%BB%E5%8A%A0%E5%88%B0%E7%AE%A1%E7%90%86%E7%BB%84
28
+ # $ userdel username 删除用户
28
29
$ adduser ecmadao # 新建用户
29
30
$ gpasswd -a ecmadao sudo # 增加权限
31
+ # $ passwd 改变当前用户的密码
30
32
31
33
# 切换到新用户
32
34
$ sudo su ecmadao
@@ -42,7 +44,7 @@ $ chmod 600 ~/.ssh/authorized_keys
42
44
$ cd ~ /.ssh
43
45
$ sudo apt-get install vim
44
46
$ vim authorized_keys
45
- # 然后加入自己本地电脑里 ~/.ssh/id_rsa.pub的内容
47
+ # 然后加入自己本地电脑里 ~/.ssh/id_rsa.pub 的内容
46
48
$ exit # 退出登录再重新登入,验证是否成功
47
49
48
50
$ cd /etc/ssh/
@@ -52,6 +54,11 @@ $ sudo service ssh restart # 重启服务
52
54
$ pwd # 查看路径
53
55
```
54
56
57
+ ``` bash
58
+ # 登录服务器安全性保障
59
+ # http://jamyy.us.to/blog/2014/01/5800.html
60
+ ```
61
+
55
62
### 开发环境配置
56
63
57
64
#### curl
@@ -185,7 +192,7 @@ server {
185
192
root /home/ecmadao/www/hacknical/public;
186
193
location / {
187
194
index index.html index.htm;
188
- proxy_pass http://127.0.0.1: 3000;
195
+ proxy_pass http://127.0.0.1: 3000;
189
196
proxy_set_header Host $http_host;
190
197
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
191
198
}
Original file line number Diff line number Diff line change 47
47
48
48
- [ scrape-it] ( https://github.com/IonicaBizau/scrape-it )
49
49
50
- > 基于 Node.js 的爬虫框架
50
+ > 基于 Node.js 的爬虫框架
51
+
52
+ ### Wiki
53
+
54
+ - [ Outline] ( https://github.com/outline/outline )
55
+ - [ Wiki.js] ( https://github.com/Requarks/wiki )
56
+ - [ jingo] ( https://github.com/claudioc/jingo )
57
+ - [ Total.js] ( https://www.totaljs.com/wiki/ )
58
+ - [ Matterwiki] ( https://github.com/Matterwiki/Matterwiki )
You can’t perform that action at this time.
0 commit comments