-
-
- /**
- * Processes a COPS request
- * @param msg COPS request received from the PEP
- * @throws COPSPdpException
- */
- protected void processRequest(COPSReqMsg msg)
- throws COPSPdpException {
-
- COPSHeader hdrmsg = msg.getHeader();
- COPSHandle handlemsg = msg.getClientHandle();
- COPSContext contextmsg = msg.getContext();
-
- //** Analyze the request
- //**
-
- /* <Request> ::= <Common Header>
- * <Client Handle>
- * <Context>
- * *(<Named ClientSI>)
- * [<Integrity>]
- * <Named ClientSI> ::= <*(<PRID> <EPD>)>
- *
- * Very important, this is actually being treated like this:
- * <Named ClientSI> ::= <PRID> | <EPD>
- *
-
- // Named ClientSI
- Vector clientSIs = msg.getClientSI();
- Hashtable reqSIs = new Hashtable(40);
- String strobjprid = new String();
- for (Enumeration e = clientSIs.elements() ; e.hasMoreElements() ;) {
- COPSClientSI clientSI = (COPSClientSI) e.nextElement();
-
- COPSPrObjBase obj = new COPSPrObjBase(clientSI.getData().getData());
- switch (obj.getSNum())
- {
- case COPSPrObjBase.PR_PRID:
- strobjprid = obj.getData().str();
- break;
- case COPSPrObjBase.PR_EPD:
- reqSIs.put(strobjprid, obj.getData().str());
- // COPSDebug.out(getClass().getName(),"PRID: " + strobjprid);
- // COPSDebug.out(getClass().getName(),"EPD: " + obj.getData().str());
- break;
- default:
- break;
- }
- }
-
- //** Here we must retrieve a decision depending on
- //** the supplied ClientSIs
- // reqSIs is a hashtable with the prid and epds
-
- // ................
- //
- Hashtable removeDecs = new Hashtable();
- Hashtable installDecs = new Hashtable();
- _process.setClientData(this, reqSIs);
-
- removeDecs = _process.getRemovePolicy(this);
- installDecs = _process.getInstallPolicy(this);
-
- //** We create the SOLICITED decision
- //**
- _sender.sendDecision(removeDecs, installDecs);
- _status = ST_DECS;
- */