|
*:96 Internet Application Protocols and Standards Exam 1998-05-08 with answers |
The following documents are allowed during the exam:
Note 1: Compendium 4 and 5 are not allowed during the exam.
Note 2: Some students may have the compendiums from the previous time this course was given. These compendiums have yellow paper only on the front page of the allowed documents, and there was a separate document Appendix A: ASN.1 syntax (basic items) which is allowed during the exam.
Important warning
It is not acceptable to answer an exam question by just a verbatim quote from the allowed documents above. You must show that you understand the question and your answer by using your own words.
Exam in English
You can submit the exam in either Swedish or English. If you want the exam questions in English, you must notify the teacher at least two weeks before the exam.
Questions during the exam
Jacob Palme will be available by phone 08-664 77 48 between 9 and 12 on the day of the exam for questions about the exam.
Special for students who have previously participated in the ASN.1 course
If you have previously participated in, and passed the exam on, the course segment *:73 about ASN.1, then you must skip question 1 in this exam and will then get only 2,5 instead of 3,5 points for this exam (plus 0,5 points for the work task). If you are one of these, you must very clearly mark this on the exam.
Notification of result by e-mail
If you write your e-mail address on the front cover page of the exam, then you will be notified by e-mail if you did not pass the exam.
No. |
Question in English |
Maximum score |
||||||||||||
Question no. 1 |
Specify an ASN.1 data type to indicate for every day of the year, whether this day was a holiday or a working day. Only these two values are allowed. |
Maximum score: 6 points |
||||||||||||
Answer alternative 1: |
DaysOpen ::= BIT STRING (SIZE (365..366)) | |||||||||||||
Answer alternative 2: |
DaysOpen ::= SEQUENCE
SIZE (12) OF MonthDaysOpen MonthDaysOpen ::= BIT STRING (SIZE (28..31)) |
|||||||||||||
Answer alternative 3: |
Year ::= SEQUENCE SIZE
(365..366) OF IsWorkingDay IsWorkingDay ::= BOOLEAN |
|||||||||||||
Common error 1: |
A common error was to use a CHOICE, but have the same tag on both the data types in the tag. This is not permitted, CHOICE requires different tag for all alternatives in a CHOICE. | |||||||||||||
Common error 2: |
Another common error was to use SEQUENCE instead of SEQUENCE OF. (Or SET instead of SET OF.) | |||||||||||||
Question no. 2 |
|
Maximum score: 6 points |
||||||||||||
Above is shown a part of a web page. You might first think that this is one big GIF file. But it is not! To save the download time of large graphic, only a small part of this is actually a GIF file. What, then, is the HTML behind this? | ||||||||||||||
Answer alternative 1: |
There are many possible answers. Here is one of them. The HTML code below is slightly simplified. <TABLE BORDER=0 CELLPADDING=0 CELLSPACING=0> <TR> <TD ROWSPAN=2 BGCOLOR="#0066FF"> <P ALIGN=CENTER> <FONT SIZE=7 COLOR="#FFFFFF"><B>*:96</B></FONT> <BR> </TD> <TD WIDTH=73 HEIGHT=100 BGCOLOR="#0066FF"> <IMG SRC="exam-98-05a.gif" WIDTH=73 HEIGHT=100> </TD> <TD WIDTH=254 HEIGHT=100 BGCOLOR="#FFFFCC"> <FONT SIZE=5><B>Internet application<BR> protocols and standards</B></FONT> </TD> </TR> <TR> <TD HEIGHT=14 COLSPAN=2 BGCOLOR="#3366FF"> </TD> </TR> </TABLE> Here is the rendering of answer alternative 1, but with BORDER=2 to show the cell divisions:
The only cell in the table above, which contains an image, is the second cell in the first row! |
|||||||||||||
Answer alternative 2: |
For some reason, I do not know why, answer alternative 1 will not work perfectly with the version of Netscape, on which I tested it. It did work OK with Explorer. Below is a variant with a slightly larger GIF image, but which worked OK when I tested it with both Netscape and Explorer. <TABLE BORDER=1 CELLPADDING=0 CELLSPACING=0> <TR> <TD ROWSPAN=2 BGCOLOR="#0066FF"> <P ALIGN=CENTER><FONT SIZE=7 COLOR="#FFFFFF"><B>*:96</B></FONT> <BR> </TD> <TD WIDTH=73 ROWSPAN=2 BGCOLOR="#0066FF"> <IMG SRC="exam-98-05b.gif" WIDTH=73 HEIGHT=114> </TD> <TD WIDTH=254 HEIGHT=100 BGCOLOR="#FFFFCC"> <FONT SIZE=5><B>Internet application<BR> protocols and standards</B></FONT> </TD> </TR> <TR> <TD HEIGHT=14 BGCOLOR="#0066FF"> </TD> </TR> </TABLE> Here is the rendering of answer alternative 2, but with BORDER=2 to show the cell divisions:
|
|||||||||||||
Not quite working answer alternative 3: |
Here is a solution which some of you submitted, and which is smart and almost does the trick. However, with this solution, it is difficult to ensure correct alignment between the horizontal ruler and the logo. A solution which works with one browser might not work with another browser. Also, the GIF picture is much larger with this solution. <BODY BGCOLOR="#FFFFCC"> <IMG SRC="exam-98-05c.gif" WIDTH=145 HEIGHT=112 ALIGN=LEFT BORDER=0> <BR><BR><FONT SIZE=5><B>Internet application<BR> protocols and standards</B></FONT></P> <HR ALIGN=LEFT SIZE=13 NOSHADE> <BR clear=all> |
|||||||||||||
Not quite working answer alternative 4: |
This solution works almost correctly, but not quite. Some browsers insert some kind of horizontal bar between the two images. <IMG SRC="exam-98-05d.gif" WIDTH=145 HEIGHT=98 ALIGN=LEFT BORDER=0><BR> <FONT SIZE=5><B>Internet application<BR> protocols and standards</B></FONT></P> <P><BR clear=all> <IMG SRC="exam-98-bottom-bar.gif" WIDTH=400 HEIGHT=14 ALIGN=BOTTOM BORDER=0></P> |
|||||||||||||
Not quite working answer alternative 5: |
Several students tried with diff solution: <BODY BACKGROUND="exam-98-05e.gif"> <BLOCKQUOTE> <BLOCKQUOTE> <BLOCKQUOTE> <H3><BR> <FONT FACE="Geneva"><B>Internet application<BR> protocols and standards</B></FONT> </BLOCKQUOTE></BLOCKQUOTE></BLOCKQUOTE> This solution has, however, several problems. First, you do not save much downloading time, since the GIF will be almost the same size as a GIF with the text included. Secondly, the background picture is tiled multiple times, so that the result will look something like this (the number of tiles horizontally and vertically will depend on the window size):
|
|||||||||||||
Question no. 3 |
When the MIME standard was defined, it was carefully designed so that MIME data would not break older mail software. How was this done? |
Maximum score: 6 points |
||||||||||||
Answer: |
Note: Many students answered with description of the MIME-Version header field. But that field does not solve this problem, since the older mailers do not understand this header field, they do not know what MIME is, since they were written before MIME existed.This answer shows a fundamental misunderstanding of the problem in the question, which was how old software, defined before MIME was known, would treat MIME messages. However, there are certain smart e-mail routers, which know, for each user, the capabilities of the client used by that user, and which will convert MIME messages to a format which the client can handle. With this method, the MIME header fields can help to avoid breaking older mail software, but this works only because some of the software (the mail routers) does understand MIME. |
|||||||||||||
Question no. 4 |
How can an HTTP client automatically select in which language a HTML page is to be displayed? |
Maximum score: 6 points |
||||||||||||
Answer: |
In the request command, the HTTP client includes the following header field to the server: Accept-Language: sv Where "sv" indicates the Swedish language. The language tags are based on an ISO standard, further enhanced by IETF in RFC 1766.The value in the Accept-language header field can, according to the present HTTP/1.1 proposed standard, be one or a list of preferred languages, for example Accept-Language: da, en-gb;q=0.8, en;q=0.7 indicates that Danish is best, British English second best, any other English third choice. However, much existing software today (May 1998), is only able to handle a single, or the first, language. This method is known under the term server-driven selection, since it is the server which decides which version to send based on information from the client. The RFC 2068 version of HTTP/1.1 also specified a header for client-driven selection, with the name Alternates. The idea is that the server sends a list of alternate forms of a document, with information about them, and the client choses which to download. This field has not been very much used, and will probably be removed from the next version of HTTP. |