Weekend Sale Limited Time 70% Discount Offer - Ends in 0d 00h 00m 00s - Coupon code: xmas50

GIAC GSSP-.NET - GIAC GIAC Secure Software Programmer - C#.NET

Page: 1 / 15
Total 491 questions

You work as a Software Developer for ABC Inc. The company uses Visual Studio.NET as its application development platform. You have recently finished development of an application using .NET Framework. The application used two threads named threadOne and threadTwo. You are required to modify the code of the application to prevent the execution of threadOne until threadTwo completes execution. What will you do to accomplish this task?

A.

Use a WaitCallback delegate to synchronize the threads.

B.

Configure threadTwo to run at a higher priority.

C.

Configure threadOne to run at a lower priority.

D.

Call the Sleep method of threadOne.

E.

Call the SpinLock method of threadOne

You work as a Software Developer for ABC Inc. The company uses Visual Studio.NET 2005 as its application development platform. You are developing an application using the .NET Framework 2.0.

You are required to use a datatype that will store only numbers ranging from -32,768 to 32,767.

Which of the following datatypes will you use to accomplish the task?

Each correct answer represents a complete solution. Choose two.

A.

int

B.

string

C.

short

D.

System.Int16

You work as a Software Developer for ManSoft Inc. You create an application using Visual Studio .NET 2005. You are using the Custom authentication provider in the application. In order to enable the Custom authentication provider, you have to make an entry in the Web.config file for the application. Which of the following entries will you use to accomplish the task?

A.

B.

C.

D.

E.

Kathy works as a Software Developer for BlueWell Inc. She creates a serviced component named

Com1. She wants to ensure that all the employees of the company are able to use Com1. Therefore, she wants to install Com1 in the Global Assembly Cache (GAC). Before the installation, she wants to register the serviced component manually with COM+. Which of the following tools will Kathy use to register Com1?

A.

Al.exe

B.

Regsvcs.exe

C.

Regasm.exe

D.

Mscorcfg.msc

You work as a Software Developer for Mansoft Inc. You create an application and use it to create users as members of the local Users group. Which of the following code snippets imperatively demands that the current user is a member of the local Users group?

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

A.

System.AppDomain.CurrentDomain.SetPrincipalPolicy(PrincipalPolicy.WindowsPrincipal);

PrincipalPermission MyPermission = new PrincipalPermission(null, @"BUILTIN\Users", true);

MyPermission.Demand();

B.

PrincipalPermission MyPermission = new PrincipalPermission(null, @"BUILTIN\Users", true); MyPermission.Demand();

C.

System.AppDomain.CurrentDomain.SetPrincipalPolicy(PrincipalPolicy.WindowsPrincipal);

PrincipalPermission MyPermission = new PrincipalPermission(null, @"Users", true);

MyPermission.Demand();

D.

PrincipalPermission MyPermission = new PrincipalPermission(null, @"Users", true);

MyPermission.Demand();

You work as a Web Application Developer for SunInfo Inc. The company uses Visual Studio 2008 as its application development platform. You create a Web application using .NET Framework 3.5.

You want to ensure that the data input by a user falls within a predetermined range. Which of the following validation controls will you use to accomplish the task?

A.

RangeValidator

B.

CompareValidator

C.

RequiredFieldValidator

D.

RegularExpressionValidator

You work as a Software Developer for ABC Inc. The company uses Visual Studio .NET 2008 as its application development platform. You create an ASP.NET Web application using .NET Framework 3.5. The application stores sensitive profile data in a SQL Server 2008 database. You are required to make sure that no profile data is stored in clear text. What will you do to accomplish the task?

A.

Use the Aspnet_regiis.exe tool to encrypt the connection string that is used to connect to the database.

B.

Create a custom profile provider and ensure that the provided information is encrypted before it is stored in the database.

C.

Enable the secure sockets layer encryption for the SQL Server connections.

D.

Use SQL Profiler.

Dennis works as a Software Developer for BlueWell Inc. He develops an application, named App1, using Visual C# .NET. App1 contains a class, named Class1, which is stored in a namespace, named BlueWell.Namespace1. Dennis wants to create another class, named Class2, and use Class1 from Class2. For this, he wants to define an alias, named Alias1, and use it in Class2.

Which of the following statements will Dennis use to define Alias1?

A.

BlueWell.Namespace1.Class1 : Alias1;

B.

BlueWell.Namespace1.Class1, Alias1;

C.

using Alias1 = BlueWell.Namespace1.Class1;

D.

Alias1 = BlueWell.Namespace1.Class1;

You work as a Software Developer for InfoTech Inc. You develop an application named MyApp that works as a scientific calculator. A user inputs data and retrieves the calculated results based on the input values. The application uses a SQL database that contains two tables. One table contains data related to standard calculation specifications and the other table stores input values entered by the user. You want to ensure that the user is able to retrieve appropriate data fast. Which of the following actions will you take to accomplish the task?

Each correct answer represents a part of the solution. Choose all that apply.

A.

Use more than one component to process input data.

B.

Write code that performs multiple tasks simultaneously.

C.

Run multiple processes on a single thread.

D.

Use a single component to process input data.

E.

Run multiple processes on separate threads.

Allen works as a Software Developer for ABC Inc. The company uses Visual Studio.NET 2008 as its application development platform. Allen develops an application using .NET Framework 3.5. The application connects to a SQL Server database using a SqlConnection object named Connection1. He creates some stored procedures in the database, which are used to update the data. Allen finds that sometimes, the update operation does not affect any row. He wants to add an error handling code to the application. Which of the following code segments will he use to accomplish the task?

A.

try

{

Connection1.open();

}

catch(DataException Myexcept)

{

//Error-handling code

}

B.

try

{

Connection1.open();

}

catch(SqlException Myexcept)

{

//Error-handling code

}

C.

try

{

Connection1.open();

}

catch(DBConcurrencyException Myexcept)

{

//Error-handling code

}

D.

try

{

Connection1.open();

}

catch(InvalidCastException Myexcept)

{

//Error-handling code

}