コンテンツへのアクセスを制限するためにアクセス制御を設定します。IP制限、地域ブロック、認証を使用して機密リソースを保護します。
| 方法 | 説明 |
|---|---|
| IP制限 | 特定のIPを許可/ブロック |
| 地域ブロック | 国/地域によるブロック |
| トークン認証 | URLトークン検証 |
{
"ip_access": {
"mode": "allowlist",
"ips": ["10.0.0.0/8", "192.168.1.0/24"]
}
}
{
"ip_access": {
"mode": "blocklist",
"ips": ["1.2.3.4", "5.6.7.8"]
}
}
{
"geo_blocking": {
"action": "block",
"countries": ["XX", "YY"]
}
}
function generateSignedUrl(url, secret, expiry) {
const expires = Math.floor(Date.now() / 1000) + expiry;
const signature = crypto
.createHmac("sha256", secret)
.update(url + expires)
.digest("hex");
return url + "?expires=" + expires + "&signature=" + signature;
}
curl -X GET https://api.sudun.com/v1/domains/{domain}/access \
-H "Authorization: Bearer YOUR_API_KEY"
ヘルプが必要ですか? support@sudun.com までお問い合わせください