﻿<?xml version="1.0" encoding="UTF-8"?>
<Request xmlns="urn:oasis:names:tc:xacml:1.0:context"
         xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
         xmlns:db="db_acad">


  <Subject>

    <Attribute AttributeId="db_acad_users_user_username"
               DataType="http://www.w3.org/2001/XMLSchema#string">
      <AttributeValue>teacher1</AttributeValue>
    </Attribute>

    <Attribute AttributeId="db_acad_users_user_role"
                DataType="http://www.w3.org/2001/XMLSchema#string" >
      <AttributeValue>teacher</AttributeValue>
    </Attribute>

    <Attribute AttributeId="db_acad_users_user_branch"
                DataType="http://www.w3.org/2001/XMLSchema#string" >
      <AttributeValue>IT</AttributeValue>
    </Attribute>

    <Attribute AttributeId="db_acad_users_user_teach"
                DataType="http://www.w3.org/2001/XMLSchema#string" >
      <AttributeValue>sub1</AttributeValue>
    </Attribute>
    
    
  </Subject>

  <Resource>

    <ResourceContent>

      <db:user type='target'>
        <db:username>student2</db:username>
        <db:password>xacml</db:password>
        <db:role>student</db:role>
        <db:branch>IT</db:branch>
        <db:permit>student3</db:permit>
        <db:permit>student1</db:permit>
        <db:dean_view_once>false</db:dean_view_once>
        
        <email>student2@acad.com</email>
        <db:marks>
          <db:sub1>86</db:sub1>
          <db:sub2>79</db:sub2>
          <db:sub3>85</db:sub3>
        </db:marks>
      </db:user>

      <db:user type='subject'>
        <db:username>teacher1</db:username>
        <db:role>teacher</db:role>
        <db:branch>IT</db:branch>
        <db:teach>sub2</db:teach >
      </db:user>



    </ResourceContent>

    <Attribute AttributeId="urn:oasis:names:tc:xacml:1.0:resource:resource-id"
                DataType="http://www.w3.org/2001/XMLSchema#string">
      <AttributeValue>sub2</AttributeValue>
    </Attribute>

    <Attribute AttributeId="policy_purpose"
                DataType="http://www.w3.org/2001/XMLSchema#string">
      <AttributeValue>marking</AttributeValue>
    </Attribute>

  </Resource>

  <Action>
    <Attribute AttributeId="urn:oasis:names:tc:xacml:1.0:action:action-id"
               DataType="http://www.w3.org/2001/XMLSchema#string">
      <AttributeValue>edit</AttributeValue>
    </Attribute>
  </Action>
</Request>


