It's UWAweek 9 (1st semester, week 1)

help2002

This forum is provided to promote discussion amongst students enrolled in CITS2002 Systems Programming.
Please consider offering answers and suggestions to help other students! And if you fix a problem by following a suggestion here, it would be great if other interested students could see a short "Great, fixed it!"  followup message.
Displaying selected article
Showing 1 of 1168 articles.
Currently 5 other people reading this forum.


 UWA week 43 (2nd semester, study break) ↓
SVG not supported

Login to reply

👍?
helpful
7:29pm Fri 27th Oct, Christopher M.

ANONYMOUS wrote:
> How are we suppose to know when a file is trojan horse ?
There's no definition of a trojan-horse that you need to detect in your code. You're being asked to find/report any command names that each appear more than once in the directory names indicated by the value of PATH variable. If any particular filename appears more than once, then at least one of the instances is simply *suspected* of being a trojan-horse.
> Another question, do you have any tips to knowing when a function needs to fork as it is not directly stated in most of the past exam questions ?
There's no tips or magic 'formula' indicating when to use fork(). Its use enables either: - both the original parent and new child processes to execute the same code, at their own rate, OR - for the child process to be overlaid with a call to ``execve()``` to run a different program.

The University of Western Australia

Computer Science and Software Engineering

CRICOS Code: 00126G
Written by [email protected]
Powered by history
Feedback always welcome - it makes our software better!
Last modified  5:07AM Sep 06 2023
Privacy policy