This tutorial has a new version, check it out!

Symfony Security Voters (free cookies!)

14:28

What you'll be learning

// composer.json
{
    "require": {
        "php": ">=5.3.3",
        "symfony/symfony": "dev-master", // dev-master
        "doctrine/orm": "~2.2,>=2.2.3", // v2.4.5
        "doctrine/doctrine-bundle": "~1.2", // v1.2.0
        "twig/extensions": "~1.0", // v1.1.0
        "symfony/assetic-bundle": "~2.3", // v2.3.0
        "symfony/swiftmailer-bundle": "~2.3", // v2.3.7
        "symfony/monolog-bundle": "~2.4", // v2.6.1
        "sensio/distribution-bundle": "~3.0", // v3.0.6
        "sensio/framework-extra-bundle": "~3.0", // v3.0.2
        "incenteev/composer-parameter-handler": "~2.0", // v2.1.0
        "hautelook/alice-bundle": "~0.1" // 0.1.5
    },
    "require-dev": {
        "sensio/generator-bundle": "~2.3" // v2.4.0
    }
}

Tutorial has been updated! See https://knpuniversity.com/screencast/new-in-symfony3/voter

Symfony Voters are the work horses of authorization. But they're not well-understood and are totally under-utilized. So let's take our wild security business logic and see how a customer voter can centralize things and make your controller and templates dead simple.


Your Guides

Ryan Weaver Leanna Pelham


Questions? Conversation?