TLDR Web Dev · ARTICLES & TUTORIALS

A DEEP DIVE INTO DEEPLY RECURSIVE GO

mattermost.com8 min read

Summary from the TLDR Web Dev newsletter

Deep recursion in Go programming is dangerous as it can lead to stack exhaustion and program crashes. This is because Go doesn't support tail call optimization and has limited stack memory that grows in 2KB increments until hitting system limits. This can be a security concern in Go, as stack exhaustion was the root cause of three Denial-of-Service vulnerabilities fixed in Go 1.22.7 and 1.23.1.