API remove CSRF

http://laravel.com/

http://kejyun.github.io/Laravel-4-Docum ... roduction/
回覆文章
yehlu
Site Admin
文章: 3245
註冊時間: 2004-04-15 17:20:21
來自: CodeCharge Support Engineer

API remove CSRF

文章 yehlu »

代碼: 選擇全部

<?php

namespace App\Http\Middleware;

use Illuminate\Foundation\Http\Middleware\VerifyCsrfToken as BaseVerifier;

App\Http\Middleware\VerifyCsrfToken.php
class VerifyCsrfToken extends BaseVerifier
{
    /**
     * The URIs that should be excluded from CSRF verification.
     *
     * @var array
     */
    protected $except = [
        //
        '/photorotate/*',
        '/exif/*',
        '/resize/*',
        'alipaywebNotify',
        'alipaywebReturn',
        '/wechatwebReturn/*',
        '/wechatBack/*',
        '/govlntest/*',
    ];
}

回覆文章

回到「laravel」