x

Search in
Sort by:

Question Status:

Search help

  • Simple searches use one or more words. Separate the words with spaces (cat dog) to search cat,dog or both. Separate the words with plus signs (cat +dog) to search for items that may contain cat but must contain dog.
  • You can further refine your search on the search results page, where you can search by keywords, author, topic. These can be combined with each other. Examples
    • cat dog --matches anything with cat,dog or both
    • cat +dog --searches for cat +dog where dog is a mandatory term
    • cat -dog -- searches for cat excluding any result containing dog
    • [cats] —will restrict your search to results with topic named "cats"
    • [cats] [dogs] —will restrict your search to results with both topics, "cats", and "dogs"

mount encrypted pak file at runtime

I have created an encrypted pak file using unrealpak.exe I am able to extract the contents using the key with unrealpak.

In my game I load content needed from a pak file on the fly, and all seems to be working well with unencrypted paks.

But I am not able to get the encrypted pak file to mount in the game at runtime. I can't seem to figure out where it wants me to supply the aes key.

it crashes on the PakFile declaration line everytime, complaining of an invalid key

 FPakFile PakFile(&PlatformFile, *PakFilename, false);

Can anyone show me where to supply the needed key to mount the pak file?

Product Version: UE 4.21
Tags:
more ▼

asked Nov 20 '18 at 04:52 PM in C++ Programming

avatar image

quentin252
1 1 5

avatar image quentin252 Nov 23 '18 at 06:14 PM

i tried added keys in various ini files. no go. i tried added the public definition of AES_KEY in my projects build.cs file. nothing. i tried the new crypto plugin, and added the key in project settings, no luck. then i used a generated key from project settings to pak file, still won't mount. i looked into these IPlatformCrypto classes but could not seem to get an understanding enough to use them correctly or at all. any thoughts out there would be much appreciated, thanks!

avatar image quentin252 Nov 26 '18 at 07:54 PM

today I tried using the command line parameter of the FPakPlatformFile->Initialize method.. I am not getting anywhere with this problem. I must be doing this very wrong.

for pak files not encrypted I was able to load with the following code:

     IPlatformFile& PlatformFile = FPlatformFileManager::Get().GetPlatformFile();
 FPakPlatformFile* PakPlatformFile = new FPakPlatformFile();
 PakPlatformFile->Initialize(&PlatformFile, TEXT(""));
 FPlatformFileManager::Get().SetPlatformFile(*PakPlatformFile);
 const FString PakFilename = "F:/test48.pak";
 FPakFile PakFile(&PlatformFile, *PakFilename, false);
 const FString MountPoint(FPaths::EngineContentDir());
 PakFile.SetMountPoint(*MountPoint);
 if (PakPlatformFile->Mount(*PakFilename, 0, *MountPoint)){...}

Has anyone encrypted a pak file and mounted it at runtime?

avatar image quentin252 Nov 28 '18 at 04:46 PM

moved to packaging and deployment in hopes of catching the eye of someone in the know :)

avatar image quentin252 Dec 03 '18 at 02:15 PM

moved to c++ for the real experts ! any thoughts would be most appreciated.

(comments are locked)
10|2000 characters needed characters left

1 answer: sort voted first

Quentin! stop talking to yourself! before you lose (the rest of) your mind!

seriously though, can ANYone give me ANY insight here?

more ▼

answered Dec 06 '18 at 04:27 PM

avatar image

quentin252
1 1 5

avatar image quentin252 Dec 10 '18 at 03:42 PM

bumping this.. please help

avatar image quentin252 Dec 13 '18 at 02:49 PM

Help! I need somebody!

avatar image quentin252 Dec 17 '18 at 04:39 PM

Help! Not just anybody! (actually, yes, anybody!)

avatar image quentin252 Dec 20 '18 at 10:20 PM

Help! You know I need someone!

avatar image quentin252 Jan 02 '19 at 04:36 PM

so much younger than today, I never needed anyone's help in any way..

avatar image quentin252 Jan 07 '19 at 07:54 PM

but now these days are gone I'm not so self-assured.
Now I find I've changed my mind, I've opened up the doors!

avatar image quentin252 Jan 14 '19 at 08:20 PM

Help me if you can, I'm feeling down!

avatar image CyberDev Jan 16 '19 at 11:39 AM

Also really curious about this. Nobody is doing this I guess.. PM me on the forums same name if you can

avatar image quentin252 Jan 22 '19 at 05:00 PM

I went to the forums and sent you a mail last week, maybe we can figure this thing.

avatar image quentin252 Feb 05 '19 at 06:01 PM

And I do appreciate you being 'round (anyone?)

avatar image quentin252 Feb 11 '19 at 07:15 PM

Help me get my feet back on the ground!

avatar image quentin252 Feb 21 '19 at 05:14 PM

Won't you please, please help me?

(comments are locked)
10|2000 characters needed characters left
Your answer
toggle preview:

Up to 5 attachments (including images) can be used with a maximum of 5.2 MB each and 5.2 MB total.

Follow this question

Once you sign in you will be able to subscribe for any updates here

Answers to this question