Re: MFC resources
Hi Joe,
One failsafe thing I always do is have a default language (usually English)
that displays if one of my satellite DLLS is missing or a bad version. That
way the program can run even if the resource DLLs are missing. I am
meticulous about updating the version number in the DLLS and I change it
with every translation drop. I've been hit several times in the past where a
resource DLL didn't have a newly added resource and, thus, asserted when
said resource was requested. It's sometimes difficult to manage, but it's
worth the effort. I also like keeping them separate since I can distribute
or install any or all of the languages and even add new languages after the
release.
I've never even thought about trying to protect it from users using VS to
get at the resources. I guess that's how people steal icons and stuff :o)
Tom
"Joseph M. Newcomer" <newcomer@flounder.com> wrote in message
news:dunfi3lh0ql3mi4naq0s9v1af3i0etdqhi@4ax.com...
I agree. Why is the notion of editing resources something you care about?
If someone
changes your executable, the most likely thing that will happen is that it
will break.
Note that you have to deal with issues of localization in the presence of
checksums, so
the checksums have to be stored in the resources as well. If you pick
something
well-known like SHA-1 then anyone can recompute them.
It is reasonably safe to assume that you have no control over someone
editing resources.
BUt as Tom says, they get what they deserve.
joe
On Tue, 30 Oct 2007 15:01:28 -0700, "Tom Serface"
<tom.nospam@camaswood.com> wrote:
You could build some sort of checksum into your code based on the
resources
and check that at runtime. It would make starting up a little more time
consuming, but ...
I think if a user modifies the .EXE they sort of get what they get. They
can always reinstall.
Tom
"GT" <tihenea@berivoi.com> wrote in message
news:uHty1hyGIHA.3768@TK2MSFTNGP06.phx.gbl...
Hi,
Is there a way to mark an executable (mfc app) in such a way that no
tool can easily edit the resources? As it is I can just use vs.net 2005
to
open the .exe file and then I can not only see all the resources, but I
can also change them. There has to be a way to just tell the compiler or
the linker to include them in such a form so they cannot be edited?
Thanks,
G.
Joseph M. Newcomer [MVP]
email: newcomer@flounder.com
Web: http://www.flounder.com
MVP Tips: http://www.flounder.com/mvp_tips.htm