新老用户都可能遇到陷阱。下面我们列出频繁出现的问题,以及如何解决。 在 Freenode IRC #nginx 频道,我们经常看到这些问题。
[TOC]
最常见的是有人试图从其他指南拷贝配置片段。并非所有的指南是错误的,但绝大部分是有问题的。
| <?xml version="1.0" encoding="UTF-8"?> | |
| <!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd"> | |
| <plist version="1.0"> | |
| <dict> | |
| <key>PayloadContent</key> | |
| <array> | |
| <dict> | |
| <key>IPSec</key> | |
| <dict> | |
| <key>AuthenticationMethod</key> |
新老用户都可能遇到陷阱。下面我们列出频繁出现的问题,以及如何解决。 在 Freenode IRC #nginx 频道,我们经常看到这些问题。
[TOC]
最常见的是有人试图从其他指南拷贝配置片段。并非所有的指南是错误的,但绝大部分是有问题的。
| # to generate your dhparam.pem file, run in the terminal | |
| openssl dhparam -out /etc/nginx/ssl/dhparam.pem 2048 |
| country=cn | |
| update_config=1 | |
| network={ | |
| ssid="your ssid" | |
| psk="your psk" | |
| key_mgmt=WPA-PSK | |
| } |
https://github.com/djvirgen/virgen-acl Simple and elegant, create your own checks. No middleware?
https://github.com/OptimalBits/node_acl Use as middleware, create your own roles and access. Great choice.
https://github.com/tschaub/authorized Similar to connect roles... but a bit more robust? you can create roles and action, and associate many roles with that action
| var CryptoJS = require('crypto-js') | |
| var request = require('request-promise') | |
| /* | |
| * npm install crypto-js request-promise | |
| * node wx_t1t_hack.js | |
| */ | |
| // export function testEncription(msg, fullKey) { | |
| // var fullKey = fullKey.slice(0, 16) |
| Open("FZLTHJW.TTF") | |
| SelectAll() | |
| ScaleToEm(1024) | |
| Generate("temp.ttf", "", 0x14) | |
| Close() | |
| Open("futura.ttf") | |
| SelectAll() | |
| ScaleToEm(1024) | |
| const path = require('path') | |
| const getBaseWebpackConfig = require('next/dist/build/webpack-config').default | |
| const generateBuildId = require('next/dist/build/generate-build-id').generateBuildId | |
| const loadConfig = require('next/dist/next-server/server/config').default | |
| const { PHASE_DEVELOPMENT_SERVER } = require('next/dist/next-server/lib/constants') | |
| const shortId = require('shortid') | |
| module.exports = async ({ config, mode }) => { | |
| const dir = path.resolve(__dirname, '..') | |
| const _config = loadConfig(PHASE_DEVELOPMENT_SERVER, dir) |
| * CloudFare IP list: https://www.cloudflare.com/ips/ | |
| * Google's IP addresses: | |
| nslookup -q=TXT _netblocks.google.com 8.8.8.8 | |
| nslookup -q=TXT _netblocks2.google.com 8.8.8.8 | |
| nslookup -q=TXT _netblocks3.google.com 8.8.8.8 | |
| Each of the above line will display a CIDR block or Google’s IP addresses. | |
| * Amazon IP addresses: https://ip-ranges.amazonaws.com/ip-ranges.json |
| * CloudFare IP list: https://www.cloudflare.com/ips/ | |
| * Google's IP addresses: | |
| nslookup -q=TXT _netblocks.google.com 8.8.8.8 | |
| nslookup -q=TXT _netblocks2.google.com 8.8.8.8 | |
| nslookup -q=TXT _netblocks3.google.com 8.8.8.8 | |
| Each of the above line will display a CIDR block or Google’s IP addresses. | |
| * Amazon IP addresses: https://ip-ranges.amazonaws.com/ip-ranges.json |