Sie sind auf Seite 1von 7

Sheet 1 of 7 EXAMINATION PAPER Code: CTEC1801 Session - 2011 / 2012 (Pseudo past paper) Facu t! of Techno o"!

#odu e Code - CTEC1801 $e%e - & #odu e Tit e - E e'ents of Co'putin" (ate - Sunda! )th #a! 2012 Ti'e * o+ed - , hours Start 08:00 Finish 11:00 --------------------------------------------------------.nstructions to/ and infor'ation for/ candidates: The e0a'ination co'prises three sections/ each +orth 21 'ar2s3 *ns+er each section in a separate ans+er 4oo2 et/ c ear ! 'ar2ed as: Section * (*rchitecture) Section 5 (6peratin" S!ste's) Section C (7et+or2s) *ns+er a 8uestions3 #a0i'u' 'ar2s a%ai a4 e: 71

P ease turn o%er933

Code: CTEC1801

Sheet 2 of 7

Section A - Architecture (start a new answer booklet for section A)


Question A1 (15 marks) The asse'4 ! an"ua"e pro"ra' Eatsyscall/ is desi"ned to output the 'essa"e Eat at Joe's3 E0a'ine the pro"ra' source code "i%en 4e o+ and "i%e a detai ed e0p anation of the purpose of each instruction a4e ed as ## EXPLAIN ME ##3 :our ans+er shou d 'a2e reference to s!ste' ca s/ fi e descriptors/ interrupts/ a4e s and addresses3
;~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ; Executable name : EATSYSCALL ; Version : 1.0 ; Created date : 1/ /!00" ; Last u#date : !/1$/!00" ; Aut%or : &e'' (untemann ; (escri#tion : A sim#le #ro)ram in assembl* 'or Linux+ ; usin) ,AS- !.0.+ demonstratin) t%e use o' Linux /,T $00 s*scall ; to dis#la* text. ; ; 1uild usin) t%ese commands: ; nasm 2' el' 2) 23 stabs eats*scall.asm ; ld 2o eats*scall eats*scall.o ; SECT/4, .data ; Section containin) initialised data

Eat-s): db 5Eat at &oe6s75+10 EatLen: e8u 92Eat-s) SECT/4, .bss SECT/4, .text )lobal ;start: no# mo= mo= mo= mo= int ;start ; Section containin) uninitiali:ed data ; Section containin) code ; Lin<er needs t%is to 'ind t%e entr* #oint7

eax+> ebx+1 ecx+Eat-s) edx+EatLen $00

; ; ; ; ; ;

T%is no2o# ?? E@ALA/, ?? E@ALA/, ?? E@ALA/, ?? E@ALA/, ?? E@ALA/,

<ee#s )db %a##*... -E ?? -E ?? -E ?? -E ?? -E ??

-4V eax+1 ; Code 'or Exit S*scall mo= ebx+0 ; Beturn a code o' :ero int $00 ; -a<e <ernel call ;~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

P ease turn o%er933

Code:
Question A (5 marks) *ssu'in" 8-bit 's co!"le!ent representation/ e0p ain ho+: a) deci'a - !" +ou d 4e e0pressed/ 4) 4inar! #1#1 #1#1 +ou d 4e interpreted/

Sheet , of 7

Question A" (5 marks) 5rief ! out ine the ad%anta"es associated +ith the use of asse'4 er-pro"ra''in" an"ua"es and "i%e e0a'p es of si"nificant current usa"e3

Code: CTEC1801

Sheet & of 7

Section $ - O%eratin& S'stems (start a new answer booklet for section #)


Question $1 - Inter(aces (5 marks) *n operatin" s!ste' has 'an! interfaces to a o+ different t!pes of interaction3;er! 4rief ! discuss the purpose of the *pp ication Pro"ra''in" .nterface3

Question $ - Processes (5 marks) 5rief ! discuss +hat is 'eant 4! the ter' < Pre-E!"tion<3

Question $" - )i*e S'stems (5 marks) 5e o+/ there is a %er! si'p e fi e s!ste' tree for a =ni0 en%iron'ent3 a)3 *ssu'in" that the current ocation is the bin director!/ +hat is the a4so ute path for the fi e syslo$%&>3 4)3 *ssu'in" that the current ocation is the Icons su4director! of the user <"'n< ho'e director!/ +hat is the re ati%e path for the o"s director! ocated in the ho'e director! of the user <$la"wort(<>
/ 2 /bin 2 /boot 2 /de= 2 /etc 2 /%ome 22 /)la#Cort% 222 /solutions.txt 222 /#%#test.#%# 222 /(ocuments 2222 /lo)s 22222 /s*slo).1 22222 /s*slo).! 22222 /s*slo).D 22 /#dn 222 /exam.txt 222 /ansCers.txt 222 /(es<to# 2222 //cons 22222 /icon1.#n) 22222 /icon!.#n) 22222 /iconD.#n)

P ease turn o%er933

Code:

Sheet 1 of 7

Question $! - Memor' (5 marks) 5rief ! e0p ain +h! sin" e- e%e pa"e 'ap ta4 es +ith a pa"e si?e of 2@12 (ie &0A) 4!tes) are not suita4 e for ,2-4it s!ste's3

Question $5 - Scri%tin& (5 marks) 5e o+ is a s'a 4ash script3 Bhat is the output of the fina echo state'ent>
?7/bin/bas% iE0 'or a in F0..1...DG do HE100 'or b in 1 ! D > . I do let 5H2E15 done let 5iJE15 done ec%o 5iE9i HE9H5

Code: CTEC1801

Sheet ) of 7

Section + - Net,orks (start a new answer booklet for section ))


Question +1 (5 marks)

hu4 B - 1723283A73&0/2A
3&1 3&2 3&)

'1

'2

"+B
3110311

hu4 C - 1723213)23A)/27
310) 3107 312)

"+
3110321&

')

'7

"+C
311031)

.n the net+or2 dia"ra' a4o%e/ de%ices (/ B and C are descri4ed as (*bs% E0p ain ho+ their 4eha%iour +ou d 4e different if the! +ere switc(es rather than (*bs3

Question + (5 marks) This 8uestion uses the net+or2 dia"ra' of 8uestion C13 E0p ain ho+ the *ddress Deso ution Protoco (*DP) +ou d ena4 e ') to o4tain the address of "+C3 .n%ent an! suita4 e additiona addresses/ not sho+n on the dia"ra'/ if this he ps !our ans+er3

Question +" (5 marks) This 8uestion uses the net+or2 dia"ra' of 8uestion C13 *ssu'in" that "+C is a $inu0 de%ice +hich has had its routin" ta4 e correct ! confi"ured/ identif! the routin" ta4 e entries !ou +ou d e0pect to see in "+C3 The headin"s for the routin" ta4 e are sho+n 4e o+ as a re'inder3 *ssu'e eth0 connects to hu4 C and eth1 connects to hu4 (3
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ Kernel /A routin) table (estination LateCa* Lenmas< 3la)s -etric Be' Mse /'ace NNN O0AT S04ML( NNN NNN L4 0EBE NNN ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

P ease turn o%er933

Code:

Sheet 7 of 7

Question +! (5 marks) The Trans'ission Contro Protoco (TCP) uses a <three-+a! handsha2e< to esta4 ish se8uence nu'4ers3 5rief ! e0p ain the ro e of se8uence nu'4ers in TCP3

Question +5 (5 marks) This 8uestion uses the net+or2 dia"ra' of 8uestion C13 Eost '1 is a +e4 ser%er3 Construct the $inu0 ipta4 es co''ands that !ou +ou d put on fire+a "+B that +ou d per'it TCP port 80 (ie ETTP) traffic to pass throu"h to '1 and a so per'it the associated rep ies 4ac2 fro' '13

Das könnte Ihnen auch gefallen