After receiving a bachelor 's degree in law at the University of Cairo , he joined the foreign ministry and was posted to the United Nations office in Geneva .