Welcome to the TC forums.
As some business guru once said, "Don't try to learn the tricks of the trade. Learn the trade. The tricks will come along on their own."
Same with Linux.
Do not run your system as root. There are actual good reasons to not do so. Everyone (myself included) initially wants to run as root - and generations of Unix/linux users and admins have realized they should not normally do so.
Having said that, There are several ways it can be done and it will be a learning experience figuring them out - hopefully a long enough one that you will have learned not to do it by the time you learn how to do it.
And having said -that-, lets help you to not need to run as root....
First, after I install xfw, it runs under sudo without complaining. I don't know why it would refuse to run for you with sudo but the message "don't run this as root" looks like what tce-load says when you try to run it as root - so I wonder... did you have xfw installed ondemand? I don't use ondemand myself, but I suppose it must invoke tce-load the first time you run an ondemand program? Anybody have experience with this?
If I'm right, just try running xfw as a regular user once to get it fully installed before trying to run it with sudo.
If that works then you will be able to edit files using sudo xfw
Lastly, re. just one file in /opt - open a terminal and run this command:
ls -l /opt
Then run this one:
ls -la /opt
The files whose names begin with a dot are "hidden" files - not shown by ls unless you explicitly ask to have them shown with the -a flag.