The use of "for" vs "of" in that example is hard to explain, and I think it's more of a question of style than correctness. It doesn't feel right say that any one thing is the goal, or even a goal "for" a person. That somehow says that the person is less important than the goal, whatever that goal may be. However, in your example you quote the goal "for" an activity. That works; the goal is the entire purpose of the activity. "Of" would work there too.
I'd like to point out something else about the phrase. To refer something as the goal of something or someone, that goal needs to be the primary purpose.
For instance, it is the goal of a teacher for the students to learn the material. However, it is a goal of Mrs. Brown (the teacher) for her students to learn. In other words, Mrs. Brown has other priorities too, she's not just a teacher. Perhaps she's a wife, mother and Scrabble player too. So the big difference here isn't the use of "for" vs "of", the important distinction is between "a" or "the".