Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support for arm64 #3

Closed
khanhldt opened this issue Jun 4, 2014 · 9 comments
Closed

Support for arm64 #3

khanhldt opened this issue Jun 4, 2014 · 9 comments

Comments

@khanhldt
Copy link

khanhldt commented Jun 4, 2014

Hi, we're using this library as one of our protection strategies in our products. Apparently the assembly instruction set for arm64 has changed for the ones used by this library. Will you be able to provide an update for this?

Thanks!

@khanhldt
Copy link
Author

khanhldt commented Jun 4, 2014

Attached here the failure log for your reference:

:2:2: error: unknown directive
.arm
^
../DebuggerDetection/Internal/readSys.s:24:1: note: while in macro instantiation
BEGIN_FUNCTION readSys
^
../DebuggerDetection/Internal/readSys.s:28:11: error: vector register expected
push {r4,r5,r6, r7,lr}
^
../DebuggerDetection/Internal/readSys.s:29:9: error: invalid operand for instruction
add r7, sp,#12
^
../DebuggerDetection/Internal/readSys.s:30:11: error: vector register expected
push {r8,r10,r11,r14}
^
../DebuggerDetection/Internal/readSys.s:31:14: error: unexpected token in argument list
vstmdb sp!, {d8-d15}
^
../DebuggerDetection/Internal/readSys.s:34:9: error: invalid operand for instruction
mov r4, #0
^
../DebuggerDetection/Internal/readSys.s:35:9: error: invalid operand for instruction
mov r5, #0
^
../DebuggerDetection/Internal/readSys.s:36:9: error: invalid operand for instruction
mov r8, #0
^
../DebuggerDetection/Internal/readSys.s:37:9: error: invalid operand for instruction
mov r9, #0
^
../DebuggerDetection/Internal/readSys.s:39:9: error: invalid operand for instruction
mov r12, #202
^
../DebuggerDetection/Internal/readSys.s:46:14: error: unexpected token in argument list
vldmia sp!, {d8-d15}
^
../DebuggerDetection/Internal/readSys.s:47:10: error: vector register expected
pop {r8,r10,r11,r14}
^
../DebuggerDetection/Internal/readSys.s:48:10: error: vector register expected
pop {r4,r5,r6, r7,pc}
^
:1:1: error: unrecognized instruction mnemonic
bx lr
^
../DebuggerDetection/Internal/readSys.s:50:1: note: while in macro instantiation
END_FUNCTION

@gandg
Copy link
Member

gandg commented Jun 9, 2014

Hello,

Thank you for finding this issue.
We currently do not have these newest devices, but are in the process of ordering. We will revisit this issue at that time.

--Gregg

From: Khanh [mailto:notifications@github.com]
Sent: Wednesday, June 04, 2014 3:58 AM
To: project-imas/security-check
Subject: Re: [security-check] Support for arm64 (#3)

Attached here the failure log for your reference:

:2:2: error: unknown directive
.arm
^
../DebuggerDetection/Internal/readSys.s:24:1: note: while in macro instantiation
BEGIN_FUNCTION readSys
^
../DebuggerDetection/Internal/readSys.s:28:11: error: vector register expected
push {r4,r5,r6, r7,lr}
^
../DebuggerDetection/Internal/readSys.s:29:9: error: invalid operand for instruction
add r7, sp,#12
^
../DebuggerDetection/Internal/readSys.s:30:11: error: vector register expected
push {r8,r10,r11,r14}
^
../DebuggerDetection/Internal/readSys.s:31:14: error: unexpected token in argument list
vstmdb sp!, {d8-d15}
^
../DebuggerDetection/Internal/readSys.s:34:9: error: invalid operand for instruction
mov r4, #0
^
../DebuggerDetection/Internal/readSys.s:35:9: error: invalid operand for instruction
mov r5, #0
^
../DebuggerDetection/Internal/readSys.s:36:9: error: invalid operand for instruction
mov r8, #0
^
../DebuggerDetection/Internal/readSys.s:37:9: error: invalid operand for instruction
mov r9, #0
^
../DebuggerDetection/Internal/readSys.s:39:9: error: invalid operand for instruction
mov r12, #202
^
../DebuggerDetection/Internal/readSys.s:46:14: error: unexpected token in argument list
vldmia sp!, {d8-d15}
^
../DebuggerDetection/Internal/readSys.s:47:10: error: vector register expected
pop {r8,r10,r11,r14}
^
../DebuggerDetection/Internal/readSys.s:48:10: error: vector register expected
pop {r4,r5,r6, r7,pc}
^
:1:1: error: unrecognized instruction mnemonic
bx lr
^
../DebuggerDetection/Internal/readSys.s:50:1: note: while in macro instantiation
END_FUNCTION


Reply to this email directly or view it on GitHubhttps://github.com//issues/3#issuecomment-45061519.

@magnus80a
Copy link

Do you have an estimate of when there will be support for arm64?

@gavin-black
Copy link
Member

@magnus80a

We are slowly working on it, and my guess is that it would hopefully be completed by this winter. It is definitely on our radar to-do, and we have someone assigned to look into it.

@gavin-black
Copy link
Member

@magnus80a This should now be supported. If you do get a chance to try it let us know if you run into any issues.

@gavin-black
Copy link
Member

Fixed by: f749a82

@Emmo213
Copy link

Emmo213 commented Jan 12, 2015

I recently did a pull of this project and now am receiving errors when using on the simulator. Here are the errors I'm receiving. If there are any ideas on how to resolve I would appreciate them. Thank you.

/security-check/SecurityCheck/readSys.s:24:17: error: brackets expression not supported on this target
stp fp, lr, [sp, #-16]!
^
/security-check/SecurityCheck/readSys.s:25:17: error: unknown token in expression
add fp, sp, #0
^
/security-check/SecurityCheck/readSys.s:27:13: error: unknown token in expression
mov x4, #0
^
/security-check/SecurityCheck/readSys.s:28:13: error: unknown token in expression
mov x5, #0
^
/security-check/SecurityCheck/readSys.s:29:14: error: unknown token in expression
mov x16, #202
^
/security-check/SecurityCheck/readSys.s:30:5: error: invalid instruction mnemonic 'svc'
svc #128
^~~
/security-check/SecurityCheck/readSys.s:33:17: error: brackets expression not supported on this target
ldp fp, lr, [sp], #16
^
Command /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang failed with exit code 1

@zerpt
Copy link
Contributor

zerpt commented Jan 12, 2015

Hello @Emmo213 !
This was an issue with how Security Check was detecting target architecture. I've pushed a fix which seems to resolve the issue. Let me know if this doesn't work for you.

@Emmo213
Copy link

Emmo213 commented Jan 12, 2015

Yes, that solved my issue. Thank you very much, @zerpt!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

6 participants