How to edit some hard coded key in a java project made with Plexus Archiver and Apache Maven

24 Views Asked by At

We have a project in our AWS Lambda account which was developed by a Freelancer long back. In that project IAM Credentials API KEY ID and ACCESS KEY ID are hardcoded. Now we have to change those keys. But we don't have the project source code.

  1. We are unable to unzip the project but we did it by using Mac terminal unzip <path>
  2. I've edited the class by using a byte code editor program rej
  3. I've compressed the entire program as it was before and uploaded it to the lambda. Now we are getting Class not found Exception

The project MANIFEST file has following data Manifest-Version: 1.0 Archiver-Version: Plexus Archiver Built-By: ..... Created-By: Apache Maven 3.3.3 Build-Jdk: 1.8.0_31

Is there any way to edit the hardcoded keys in the project with the above configuration.

Many Thanks in advance.

1

There are 1 best solutions below

0
AudioBubble On

I've updated the contents of .class files by using Byte code editor http://rejava.sourceforge.net/features.html. Later I've opened the original project's zip file in WinRAR and replaced those modified class files. And that's it, I've uploaded the zip file to Lambda and it's worked as usual.