Github pages show "CNAME is already taken" although it is not. #22705
-
I want to host the repository https://github.com/cmitiisertvm/cmitiisertvm.github.io on github pages and use the custom subdomain cmit.iisertvm.ac.in. I added a CNAME record for cmitiisertvm.github.io in my domain’s DNS settings, but when I tried to add a CNAME record for the subdomain in the respository, it shows: The CNAME cmit.iisertvm.ac.in is already taken. There are no other repositories using this CNAME currently, so I can’t figure out the problem. Please help. |
Beta Was this translation helpful? Give feedback.
Replies: 5 comments
-
Hey @thesagniksaha, it looks like this got resolved, is there any suggestions you can write up for folks with the same issue you had? Thanks! |
Beta Was this translation helpful? Give feedback.
-
The problem that happened here was a case of subdomain takeover, and is a serious issue. If you create a subdomain CNAME record in your domain’s DNS settings that points to a github username and don’t update the custom domain address in your repository’s Settings > GitHub Pages within a stipulated amount of time, your subdomain could be taken over by someone else, and if you try to add that subdomain to a repository later, it will show that “The CNAME subdomain.domain.com is already taken”. Patrik has written a lot about subdomain takeovers in his blog here: https://0xpatrik.com/ Hope this was useful. |
Beta Was this translation helpful? Give feedback.
-
Were you able to resolve the takeover? How did you determine that it had been taken over in the first place? |
Beta Was this translation helpful? Give feedback.
-
I have the same issue yet to be resolved. |
Beta Was this translation helpful? Give feedback.
-
Got the same error as well when I tried to use my custom domain “lo.fish”. Maybe a cache problem? Looked up on Stack Overflow and tried everything but to no avail. here is the repo: https://github.com/CAST3LLA/lo.fish/ |
Beta Was this translation helpful? Give feedback.
The problem that happened here was a case of subdomain takeover, and is a serious issue. If you create a subdomain CNAME record in your domain’s DNS settings that points to a github username and don’t update the custom domain address in your repository’s Settings > GitHub Pages within a stipulated amount of time, your subdomain could be taken over by someone else, and if you try to add that subdomain to a repository later, it will show that “The CNAME subdomain.domain.com is already taken”.
Patrik has written a lot about subdomain takeovers in his blog here: https://0xpatrik.com/
Hope this was useful.