Hacktoberfest 2026: the issues maintainers tagged for October, open and beginner-friendly. Browse Hacktoberfest issues

Primary Upstream DNS Server IPV6 Validation Issue

Open Beginner friendly
#59 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
2/5
Estimated time
1-3 hours
Newbie friendliness
82/100
Issue type
Bug
Clarity
Clearly specified
Activity status
Active
Tech stack
android, kotlin
Domain
mobile

Research direction

Start in app/src/main/java/net/pangolin/Pangolin/SettingsActivity.kt at the import of android.util.Patterns and the validation around line 267. Reproduce the issue in the Android settings screen with both Cloudflare IPv6 examples, then verify that valid IPv6 addresses are accepted without the validation error.

Written by the indexing model from the issue text.

Description

Describe the Bug

When using the Android app, IPV6 addresses fail the validation check in the "Primary Upstream DNS Server" field on the settings page.

The example listed below the field uses an address that is not accepted despite being valid and listed as an example.

Please watch the video linked below for further explanation and information.

https://github.com/fosrl/android/blob/main/app/src/main/java/net/pangolin/Pangolin/SettingsActivity.kt#L13
import android.util.Patterns
https://github.com/fosrl/android/blob/main/app/src/main/java/net/pangolin/Pangolin/SettingsActivity.kt#L267

isDnsField -> {
    if (newValue.isEmpty()) {
        true
    } else {
        Patterns.IP_ADDRESS.matcher(newValue).matches()
    }
}

Patterns.IP_ADDRESS might not support IPV6 addresses.

Environment
  • OS Type & Version: Android 17 (CPA2A.260605.016), Xiaomi HyperOS 3.0.336.0
  • Pangolin Version: 1.23.0
  • Edition (Community or Enterprise): Community
  • Gerbil Version: 1.5.2
  • Traefik Version: 3.7.13
  • Newt Version: 1.18
  • Client Version: 0.8.0
To Reproduce
  1. Access the Android Pangolin app
  2. Open the sidebar navigation menu
  3. Access "Settings" from the navigation menu
  4. Tap "Primary Upstream DNS Server" to edit the setting
  5. Enter Cloudflare's IPV6 DNS address 2606:4700:4700::1111 or 2606:4700:4700:0000:0000:0000:0000:1111 (Expanded - full 128-Bit Form)
  6. Note the momentary flash of validation feedback (red error message) which disappears.

https://github.com/user-attachments/assets/cf6af099-604a-43fb-9e45-c7be1f1a5896

AI Disclosure

N/A

Expected Behavior

Accept IPV6 address formats, fix the validation on the field to support IPV6 addresses.

Dominant language
Kotlin
Stars
44
Forks
11
Avg merge
1m
Merged PRs (30d)
5

Getting set up

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from fosrl/android

All issues in fosrl/android

Similar issues

More Kotlin issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.