laravelium/sitemap
Framework-agnostic PHP package for generating XML, TXT, HTML, and Google News sitemaps. Works with Laravel, Symfony, or any PHP project, with support for images, videos, translations, alternates, and Google News. Includes extensible adapters and high test coverage.
Pros:
laravelium/sitemap) fits cleanly into existing Laravel applications.lastmod, changefreq, priority, images, videos, and multilingual xhtml:link alternates.Cons:
Sitemap::store, so older versions should not be used with user-influenced filenames.Laravel Compatibility:
Non-Laravel PHP:
Release Impact:
Sitemap::store filenames.Sitemap::store, especially if the filename is derived from request data, tenant input, CMS content, or admin configuration.Medium Risk, reduced by v1.0.4:
lastmod, malformed XML, or bad canonical URLs if untested.priority, changefreq, hreflang, or News metadata can reduce crawl efficiency.Sitemap::store filenames. v1.0.4 mitigates this, but application code should still avoid user-controlled filenames and keep sitemap storage paths constrained.Mitigation:
>=1.0.4.Sitemap::store calls for user-controlled filenames.<1.0.4?Sitemap::store filenames?hreflang requirements needed beyond basic XML?Laravel-Specific:
Framework-Agnostic:
Sitemap::store usage follows the v1.0.4 security fix and application-level filename validation.v1.0.4 or later immediately if using Sitemap::store.1.0.4.>=1.0.4.Sitemap::store calls and restrict filenames/paths.lastmod or content queries.| Failure Scenario | Impact | Mitigation |
|---|---|---|
| Malformed XML output | Crawl errors and possible SEO impact | Validate XML schema and test with Search Console |
| Database query timeouts | Partial or missing sitemap entries | Use retries, queues, and query optimization |
| Disk full during generation | Failed sitemap writes | Stream to object storage or use temp directories |
| Route changes break URLs | Broken links in sitemap | Add route/URL tests and post-deploy validation |
| High traffic during updates | Server overload | Rate-limit generation, queue jobs, and serve via CDN |
Path traversal in Sitemap::store filename on versions <1.0.4 |
Unauthorized file write/exposure depending on filesystem permissions | Upgrade to >=1.0.4, sanitize filenames, restrict storage paths, and avoid user-controlled filenames |
| Public storage misconfiguration | Internal or unintended files exposed | Store outside public root unless intentionally published; validate generated filenames |
How can I help you explore Laravel packages today?