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
more ▼

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

avatar image

1 1 4

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(""));
 const FString PakFilename = "F:/test48.pak";
 FPakFile PakFile(&PlatformFile, *PakFilename, false);
 const FString MountPoint(FPaths::EngineContentDir());
 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

1 1 4

avatar image quentin252 6 days ago

bumping this.. please help

avatar image quentin252 3 days ago

Help! I need somebody!

(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