# -*- coding: utf-8; mode: tcl; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- vim:fenc=utf-8:ft=tcl:et:sw=4:ts=4:sts=4

PortSystem          1.0

name                cpabe
version             0.11
revision            3
categories          security
platforms           darwin
maintainers         nomaintainer
license             GPL-2

description         ciphertext-policy attribute-based encryption toolkit

long_description    The cpabe toolkit provides a set of programs implementing \
                    a ciphertext-policy attribute-based encryption scheme. \
                    \n\nIn a ciphertext policy attribute-based encryption \
                    scheme, each user's private key is associated with a set \
                    of attributes representing their capabilities, and a \
                    ciphertext is encrypted such that only users whose \
                    attributes satisfy a certain policy can decrypt. For \
                    example, we can encrypt a ciphertext such that in a \
                    company it can only be decrypted by a someone with \
                    attributes "Senior" and "Human Resources" or has the \
                    attribute "Executive." One interesting application of \
                    this tool is that we can do Role-Based Access Control \
                    (RBAC) without requiring trusted data storage.

homepage            http://acsc.cs.utexas.edu/cpabe/
master_sites        ${homepage}

checksums           sha1    3781df5b3c8f900120dfa124345c66d35bfdd234 \
                    rmd160  43fcb2b12e8cc219f5a1753ea627bca3307d8f20

depends_build       port:pkgconfig
depends_lib         port:pbc \
                    port:libbswabe \
                    port:gettext \
                    path:lib/pkgconfig/glib-2.0.pc:glib2 \
                    path:lib/libssl.dylib:openssl

configure.args      --with-bswabe-include=${prefix}/include \
                    --with-bswabe-lib=${prefix}/lib \
                    --with-gmp-include=${prefix}/include \
                    --with-gmp-lib=${prefix}/lib \
                    --with-pbc-include=${prefix}/include/pbc \
                    --with-pbc-lib=${prefix}/lib