aspose file tools*
The moose likes Web Component Certification (SCWCD/OCPJWCD) and the fly likes security-constraint issue? Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Certification » Web Component Certification (SCWCD/OCPJWCD)
Bookmark "security-constraint issue?" Watch "security-constraint issue?" New topic
Author

security-constraint issue?

Kosala W.Abayagunawardene
Ranch Hand

Joined: Dec 15, 2007
Posts: 47



What happens with code combinations 1 and 2, 1 and 3,2 and 3.

Answer
Although the first auth-constraint is empty, implying no one will have access to the resource, this is cancelled out by the second auth-constraint that will allow anyone to access the resource.

I thought that empty auth-constraint always wins and no one will have access...
from Ref


[SCJP] ::[SCWCD]::[BCS::BIT::SCBCD] - Studying[My Blog]
Ankit Garg
Sheriff

Joined: Aug 03, 2008
Posts: 9313
    
  17

Kosala please Quote Your Sources when you post a question.

The 1st part of the web.xml is actually not valid. There's a role-name tag outside the auth-constraint element. If there is an empty auth-constraint element, then it will override other auth-constraint elements for the same resource i.e. no one will be allowed (as you said)...


SCJP 6 | SCWCD 5 | Javaranch SCJP FAQ | SCWCD Links
Kosala W.Abayagunawardene
Ranch Hand

Joined: Dec 15, 2007
Posts: 47

Ankit Garg wrote:Kosala please Quote Your Sources when you post a question.

The 1st part of the web.xml is actually not valid. There's a role-name tag outside the auth-constraint element. If there is an empty auth-constraint element, then it will override other auth-constraint elements for the same resource i.e. no one will be allowed (as you said)...


Sorry about that.Its from Marcus Green Mock Exams,SCWCD Summary Quiz 1, question 6.Yes.I thought the same as 1 is wrong.what will append if is taken out from 1.thanks
Ankit Garg
Sheriff

Joined: Aug 03, 2008
Posts: 9313
    
  17

what will append if <role-name>manager</role-name>is taken out from 1.

I already answered that
Ankit Garg wrote:If there is an empty auth-constraint element, then it will override other auth-constraint elements for the same resource i.e. no one will be allowed (as you said)...
Kosala W.Abayagunawardene
Ranch Hand

Joined: Dec 15, 2007
Posts: 47

Ankit Garg wrote:
I already answered that


Thanks
 
 
subject: security-constraint issue?