apachecn / apachecn/apachecn.github.io

Subdomain takeover on *.apachecn.org

Open
#1 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
HTML
Stars
1
Forks
1
PR merge metrics
No merged PRs in 30d

Description

## Summary

The domain **apachecn.org.io** has a subdomain wildcard CNAME record pointing to **apachecn.github.io**. This allows an attacker to use any subdomain he wants on apachecn.org with Github pages.

## Security issue

An attacker could create it's own repository and configure it to use any subdomain he wants, allowing him to serve it's own content.

## POC

I have made [a POC](http://what-i-want.apachecn.org/).

![image](https://user-images.githubusercontent.com/23080994/72226149-2a540900-358e-11ea-81fc-6f8279617e44.png)

## Remediation

Remove the wildcard CNAME record for apachecn.org.

## Impact

This issue make it possible for an attacker to carry out several type of attacks like XSS, phishing campaign or session hijacking.

Contributor guide

No contributing guide indexed for this repository

Research direction

Start by reviewing the wildcard CNAME configuration described in the issue and the linked proof of concept at what-i-want.apachecn.org. Confirm whether apachecn.org still routes arbitrary subdomains to apachecn.github.io; done means the wildcard CNAME record is removed and the proof-of-concept subdomain no longer serves attacker-controlled content.

Written by the indexing model from the issue text.

Assessment

Tech stack
github
Domain
infrastructure, security
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.