Skip to content

Commit dffdc00

Browse files
committed
Add authentication for CurseForge downloads
1 parent b4017c1 commit dffdc00

4 files changed

Lines changed: 8 additions & 4 deletions

File tree

changelog.md

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,11 @@
1-
## Resourcify 1.8.4
1+
## Resourcify 1.8.5
22

33
Please make sure to report any bugs and/or visual anomalies
44
on [Resourcify's GitHub](https://github.com/DeDiamondPro/Resourcify/issues) or in
55
the [Discord](https://dediamondpro.dev/discord).
66

7-
- Ported Resourcify to 26.2 fabric!
7+
- Add authentication to CurseForge downloads, starting 16/06/2026 this will be a requirement to download any file from
8+
CurseForge, **CurseForge downloads will not work without this update, therefore it is HIGHLY recommended you update**.
89

910
----------------------------------------------------------------------------------------------------
1011

gradle.properties

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
mod_name = Resourcify
22
mod_id = resourcify
3-
mod_version = 1.8.4
3+
mod_version = 1.8.5
44

55
org.gradle.jvmargs=-Xmx4G
66
org.gradle.parallel=true

src/main/kotlin/dev/dediamondpro/resourcify/Constants.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,6 @@ import org.slf4j.LoggerFactory
2323
object Constants {
2424
const val NAME = /*$ mod_name*/ "Resourcify"
2525
const val ID = /*$ mod_id*/ "resourcify"
26-
const val VERSION = /*$ mod_version*/ "1.8.4"
26+
const val VERSION = /*$ mod_version*/ "1.8.5"
2727
val LOGGER: Logger = LoggerFactory.getLogger(NAME)
2828
}

src/main/kotlin/dev/dediamondpro/resourcify/util/DownloadManager.kt

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,7 @@ package dev.dediamondpro.resourcify.util
1919

2020
import dev.dediamondpro.resourcify.Constants
2121
import dev.dediamondpro.resourcify.platform.Platform
22+
import dev.dediamondpro.resourcify.services.curseforge.CurseForgeService
2223
import dev.dediamondpro.resourcify.services.modrinth.ModrinthAnalytics
2324
import org.apache.commons.compress.archivers.zip.ZipArchiveEntry
2425
import org.apache.commons.compress.archivers.zip.ZipFile
@@ -89,6 +90,8 @@ object DownloadManager {
8990
gameVersion = Platform.getMcVersion(),
9091
loader = Platform.getLoader(),
9192
).toJson()
93+
} else if (url.host == "edge.forgecdn.net") {
94+
headers["x-api-key"] = CurseForgeService.API_KEY
9295
}
9396

9497
val con = url.toURL().setupConnection(headers)

0 commit comments

Comments
 (0)