[Free] 2017(Sep) CollectDumps Testking GIAC GSSP-Java Dumps with VCE and PDF 71-80

CollectDumps 2017 Sep GIAC Official New Released GSSP-Java
100% Free Download! 100% Pass Guaranteed!
http://www.CollectDumps.com/GSSP-Java.html

GIAC Secure Software Programmer – Java

Question No: 71 – (Topic 1)

You work as a Software Developer for NewTech Inc. You want to configure the deployment descriptor so as to specify the error pages used in the FORM based authentication. Which of the following elements will you use to accomplish the task?

  1. The lt;realm-namegt; sub-element of the lt;login-configgt; element.

  2. The lt;role-linkgt; sub-element of the lt;security-role-refgt; element.

  3. The lt;methodgt; sub-element of the lt;method-permissiongt; element.

  4. The lt;form-login-configgt; sub-element of the lt;login-configgt; element.

Answer: D

Question No: 72 – (Topic 1)

Mark works as a Programmer for InfoTech Inc. He develops a class named Data that imports all the required packages. The class Data uses a method named PrintData(), which uses a method that checks whether the caller has a BeanUser security role. Which of the following code of the method PrintData() will satisfy the requirement?

  1. public void PrintData()

    {

    @DeclareRoles(quot;BeanUserquot;)

    @Resource SessionContext ctx;

    @RolesAllowed(quot;BeanUserquot;)

    Principal caller = ctx.getCallerPrincipal(); if (ctx.getCallerIdentity(quot;BeanUserquot;)) {

    System.out.println(quot;It is the correct userquot;);} else{System.out.println(quot;It is the incorrect userquot;);}//more code}

  2. public void PrintData()

    {@DeclareRoles(quot;BeanUserquot;)

    @Resource SessionContext ctx;

    @RolesAllowed(quot;BeanUserquot;) Principal caller = ctx.getEJBHome();

    if (!isCallerInRole(ctx)) {System.out.println(quot;It is the correct userquot;);} else{System.out.println(quot;It is the incorrect userquot;);}//more code}

  3. public void PrintData()

    {@DeclareRoles(quot;BeanUserquot;)

    @Resource SessionContext ctx;

    @RolesAllowed(quot;BeanUserquot;)

    Principal caller = ctx.getCallerPrincipal(); if (ctx.isCallerInRole(quot;BeanUserquot;)) {

    System.out.println(quot;It is the correct userquot;);} else{System.out.println(quot;It is the incorrect userquot;);}//more code}

  4. public void PrintData()

{@DeclareRoles(quot;BeanUserquot;)

@Resource SessionContext ctx;

@RolesAllowed(quot;BeanUserquot;)

Principal caller = ctx.getCallerPrincipal();

if (ctx.getStatus(quot;BeanUserquot;)) {System.out.println(quot;It is the correct userquot;);} else{System.out.println(quot;It is the incorrect userquot;);}//more code}

Answer: C

Question No: 73 – (Topic 1)

Which of the following methods can be invoked from the ejbStore() method of an entity bean class?

Each correct answer represents a complete solution. Choose all that apply.

  1. getPrimaryKey()

  2. getUserTransaction()

  3. getRollbackOnly()

  4. isCallerInRole()

  5. getEJBObject()

Answer: A,C,D,E

Question No: 74 – (Topic 1)

Harry works as a Software Developer for SoftTech Inc. He has developed a Java application to perform various SQL statements such as INSERT, UPDATE, etc., against a database table named Employee. He has used the executeUpdate() method to perform various SQL queries and to know the exact affected rows in the database if any of the operations is performed against the database table.

Which of the following types of values is returned by this method?

  1. Double

  2. Integer

  3. Float

  4. String

Answer: B

Question No: 75 – (Topic 1)

Drag and drop the appropriate authentication types from the given options to match their properties.

Collectdumps 2017 PDF and VCE

A.

Answer: A

Question No: 76 – (Topic 1)

Which of the following are valid class declarations?

Each correct answer represents a complete solution. Choose all that apply.

  1. public abstract final Ques0160c

  2. public abstract class Ques0160a

  3. final public class Ques0160b

  4. native synchronized class Ques0160d

Answer: B,C

Question No: 77 – (Topic 1)

Which of the following exceptions will be thrown if the caller does not have permission to invoke the doAsPrivileged method?

  1. LoginException

  2. NullPointerException

  3. SecurityException

  4. PrivilegedActionException

Answer: C

Question No: 78 – (Topic 1)

Which of the following statements about the isCallerInRole() method are true? Each correct answer represents a complete solution. Choose all that apply.

  1. It can be called from the PostConstruct and PreDestroy callback methods of a stateful session bean.

  2. It is present in the UserTransaction interface.

  3. It cannot be called from a message-driven bean.

  4. It can be invoked only from the business method of an enterprise bean.

Answer: A,C,D

Question No: 79 – (Topic 1)

Which of the following actions can you take to seal two packages, PackageA and PackageB, in the JAR file MyJar.jar?

Each correct answer represents a complete solution. Choose all that apply.

  1. Execute the following command.

    jar cvf MyJar.jar Manifest.txt MyPackage/*.class

  2. Create a text file named Manifest.txt with the following contents. Name. myCompany/*Sealed. true

  3. Execute the following command.

    jar cmf MyJar.jar Manifest.txt MyPackage/*.class

  4. Create a text file named Manifest.txt with the following contents. Name. myCompany/PackageA/Sealed. true

    Name. myCompany/PackageB/ Sealed. true

    Answer: C,D

    Question No: 80 – (Topic 1)

    Sam works as a Software Developer for Gentech Inc. He writes the following code.

    1. class TryFinallyTest {

    2. public static void main(String[] args) {

    3. try {

4. int i=15/0;

5. System.out.println(quot;Testing Tryquot;); 6. }

  1. catch(ArithmeticException ae) {

  2. System.out.println(quot;Arithmetic exceptionquot;); 9. }

  1. System.out.println(quot;Correctquot;);

  2. finally {

  3. System.out.println(quot;Must executequot;);

13. }

14. }

15. }

What will happen when he attempts to compile and execute the code?

  1. It will compile successfully and run with output Arithmetic exception.

  2. It will compile successfully and run with output Must execute.

  3. It will compile successfully and run with output Correct.

  4. It will give a compile-time error.

Answer: D

100% Free Download!
Download Free Demo:GSSP-Java Demo PDF
100% Pass Guaranteed!
Download 2017 CollectDumps GSSP-Java Full Exam PDF and VCE

CollectDumps ExamCollection Testking
Lowest Price Guarantee Yes No No
Up-to-Dated Yes No No
Real Questions Yes No No
Explanation Yes No No
PDF VCE Yes No No
Free VCE Simulator Yes No No
Instant Download Yes No No

2017 CollectDumps IT Certification PDF and VCE