Hacktoberfest 2026:维护者为十月标记出来的 issue,仍然开放、适合新手。 浏览 Hacktoberfest issue

NDK 27 arm64 Navigation Native libraries have non-16 KB GNU_RELRO segment ends

未关闭
#7,978 0 条评论 0 个 reaction 已指派 0 人 在 GitHub 查看

还没有人认领这个 Issue。

评估

难度
4/5
预计耗时
3-5 天
新手友好度
48/100
Issue 类型
缺陷
描述清晰度
描述清楚
活跃度
活跃
技术栈
android, kotlin
领域
mobile-dev

调研方向

The report identifies arm64-v8a libraries in the dash-native-ndk27 AARs, especially libnavigator-android.so and libnn-perf-replay.so, with GNU_RELRO ends that fail the 16 KB alignment check. Start by locating how this repository selects and packages the Navigation Native NDK 27 artifacts, then inspect the reported AARs with llvm-readelf -lW. Done means the relevant artifacts meet Android's RELRO alignment guidance or the project documents why their layout is safe; the issue does not identify a source file or test.

由索引模型根据 Issue 内容生成。

描述

Android API: 36 (Android 16) for the bounded emulator result below; the static artifact check is API-independent.
Mapbox Navigation SDK version: 3.33.0, then 3.32.3 (-ndk27; Navigation Native 324.33.0, then 324.32.3).

Steps to trigger behavior
  1. Download each official AAR linked below, for example curl -fLO '<AAR URL>'.
  2. Extract the arm64 libraries: unzip '<artifact>.aar' 'jni/arm64-v8a/*.so' -d extracted (use a separate destination for each AAR).
  3. Run the Android NDK tool llvm-readelf -lW extracted/jni/arm64-v8a/<library>.so for each library.
  4. Check every LOAD: p_align is at least 0x4000, is a power of two, and (VirtAddr - Offset) % p_align == 0; all pass here. For GNU_RELRO, calculate (VirtAddr + MemSiz) % 0x4000; the nonzero values below reproduce the defect against the documented end-alignment check.

Official AARs (dash-native-ndk27 ships both libraries):

Expected behavior

The GNU_RELRO segment end is aligned to 16 KB, so (VirtAddr + MemSiz) % 0x4000 == 0, per Android's RELRO guidance, or Mapbox documents why this layout is safe on native 16 KB devices.

Actual behavior

Both libraries retain nonzero GNU_RELRO end remainders in the newest stable 3.33.0 dependency, although every LOAD meets 16 KB alignment:

Library (arm64-v8a) AAR version Every LOAD p_align GNU_RELRO VirtAddr + MemSiz = end end % 0x4000
libnavigator-android.so 324.33.0 0x4000, 0x4000, 0x4000 0x1d92ae0 + 0x74520 = 0x1e07000 0x3000
libnn-perf-replay.so 324.33.0 0x4000, 0x4000, 0x4000 0x1d790 + 0x870 = 0x1e000 0x2000
libnavigator-android.so 324.32.3 0x4000, 0x4000, 0x4000 0x1d4a7c0 + 0x73840 = 0x1dbe000 0x2000
libnn-perf-replay.so 324.32.3 0x4000, 0x4000, 0x4000 0x1d760 + 0x8a0 = 0x1e000 0x2000

In a prior bounded Android 16 / API 36 arm64 emulator run with 16 KB pages and linker/package compatibility mode disabled, Navigation 3.32.0 / Navigation Native 324.32.0 -ndk27 completed one Free Drive start/stop with seven emulator GPS fixes: no crash observed. No Active Guidance was exercised. That result does not establish safety, physical-device compatibility, or runtime behavior of 3.33.0/3.32.3; those versions were checked statically only.

主要语言
Kotlin
星标
653
派生
321
平均合并
4 小时 6 分钟
30 天内合并 PR
9

环境准备

从这里开始

  1. 先读完整个 Issue,再读项目的贡献指南。
  2. 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
  3. Fork 仓库,在一个分支上完成修改。
  4. 提交 Pull Request,并在描述里引用这个 Issue 编号。

mapbox/mapbox-navigation-android 的其他 Issue

查看 mapbox/mapbox-navigation-android 的全部 Issue

相似的 Issue

更多 Kotlin Issue

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。