Skip to content
This repository has been archived by the owner on Feb 12, 2022. It is now read-only.

Curve.decodePoint throws OOBE when input byte array isn't proper size #5

Open
mcginty opened this issue Feb 11, 2015 · 0 comments
Open
Assignees

Comments

@mcginty
Copy link

mcginty commented Feb 11, 2015

Caught while debugging device provisioning problems, seems like it should throw some kind of decoding exception instead? Full log:

        AndroidRuntime  E  FATAL EXCEPTION: AsyncTask #2
                        E  Process: org.thoughtcrime.securesms, PID: 19613
                        E  java.lang.RuntimeException: An error occured while executing doInBackground()
                        E      at android.os.AsyncTask$3.done(AsyncTask.java:300)
                        E      at java.util.concurrent.FutureTask.finishCompletion(FutureTask.java:355)
                        E      at java.util.concurrent.FutureTask.setException(FutureTask.java:222)
                        E      at java.util.concurrent.FutureTask.run(FutureTask.java:242)
                        E      at android.os.AsyncTask$SerialExecutor$1.run(AsyncTask.java:231)
                        E      at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1112)
                        E      at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:587)
                        E      at java.lang.Thread.run(Thread.java:841)
                        E  Caused by: java.lang.ArrayIndexOutOfBoundsException: src.length=30 srcPos=1 dst.length=32 dstPos=0 length=32
                        E      at java.lang.System.arraycopy(Native Method)
                        E      at org.whispersystems.libaxolotl.ecc.Curve25519.decodePoint(Curve25519.java:71)
                        E      at org.whispersystems.libaxolotl.ecc.Curve.decodePoint(Curve.java:35)
                        E      at org.thoughtcrime.securesms.DeviceProvisioningActivity$3.doInBackground(DeviceProvisioningActivity.java:110)
                        E      at org.thoughtcrime.securesms.DeviceProvisioningActivity$3.doInBackground(DeviceProvisioningActivity.java:96)
                        E      at android.os.AsyncTask$2.call(AsyncTask.java:288)
                        E      at java.util.concurrent.FutureTask.run(FutureTask.java:237)
                        E      ... 4 more
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Development

No branches or pull requests

2 participants