Commit Graph

2502 Commits

Author SHA1 Message Date
Hamid Reza Mohammadi
fecbf0ec3b people tags #387 2026-10-03 18:05:55 +03:30
Hamid Reza Mohammadi
b5ca0f3b9c people tags #387 2026-10-03 12:14:25 +03:30
Hamid Reza Mohammadi
864cd6b38d people tags #387 2026-10-03 08:55:08 +03:30
Hamid Reza Mohammadi
4ba7da57b8 people tags #387 2026-10-03 08:41:31 +03:30
Hamid Reza Mohammadi
b8c45ed93c book list api 2026-10-02 13:40:21 +03:30
Hamid Reza Mohammadi
433cffa5ae people tags #387 2026-10-02 08:06:26 +03:30
Hamid Reza Mohammadi
d7ac35a9fc people tags #387 2026-10-01 22:05:18 +03:30
Hamid Reza Mohammadi
cee01357fc people tags #387 2026-10-01 08:01:18 +03:30
Hamid Reza Mohammadi
ddbef76d94 people tags #387 2026-09-30 20:44:35 +03:30
Hamid Reza Mohammadi
6fb3425fde people tags #387 2026-09-30 18:38:55 +03:30
Hamid Reza Mohammadi
eb88056d0b people tags #387 2026-09-30 18:31:59 +03:30
Hamid Reza Mohammadi
f305394ad7 people tags #387 2026-09-30 18:17:44 +03:30
Hamid Reza Mohammadi
d0efebd2cd people tags #387 2026-09-30 17:50:51 +03:30
Hamid Reza Mohammadi
df4ae4bd01 RSecurityBackend package update 2026-09-30 08:51:39 +03:30
Hamid Reza Mohammadi
0cb288228d people tags #387 2026-09-29 21:10:46 +03:30
Hamid Reza Mohammadi
e0ab9915b6 people tags #387 2026-09-29 19:53:09 +03:30
Hamid Reza Mohammadi
bb68c074b0 people tags #387 2026-09-29 19:32:57 +03:30
Hamid Reza Mohammadi
9d12c23400 people tags #387 2026-09-29 17:13:02 +03:30
Hamid Reza Mohammadi
1c65da5ade people tags #387 2026-09-29 12:35:40 +03:30
Hamid Reza Mohammadi
07cb45f58c people tags #387 2026-09-28 20:10:20 +03:30
Hamid Reza Mohammadi
fa8544b62d people tags #387 2026-09-28 15:06:14 +03:30
Hamid Reza Mohammadi
8110e09a07 people tags #387 2026-09-28 14:41:47 +03:30
Hamid Reza Mohammadi
57e6d77df2 people tags #387 2026-09-28 14:26:37 +03:30
Hamid Reza Mohammadi
073222ec6d people tags #387 2026-09-28 13:48:43 +03:30
Hamid Reza Mohammadi
5003f92f00 people tags #387 2026-09-28 08:54:42 +03:30
Hamid Reza Mohammadi
1614b6e7ca people tags #387 2026-09-28 08:49:48 +03:30
Hamid Reza Mohammadi
da4a0f7c14 people tags #387 2026-09-28 08:40:25 +03:30
Hamid Reza Mohammadi
601c29af36 logout from other sessions 2026-09-27 15:49:07 +03:30
Hamid Reza Mohammadi
ab254fefd5 commennt sanitization 2026-09-26 21:32:02 +03:30
Hamid Reza Mohammadi
748b4b5b0a comment sanitzier 2026-09-26 20:50:24 +03:30
Hamid Reza Mohammadi
2ca4de21d6 image upload security fix 2026-09-26 20:16:54 +03:30
Hamid Reza Mohammadi
d7e6678395 sql inj fixes 2026-09-26 19:52:59 +03:30
Hamid Reza Mohammadi
b0d6a0e83f RSecurityBacked bug fix 2026-09-26 19:26:41 +03:30
Hamid Reza Mohammadi
ece7f41484 RSecurityBackedn upgrade 2026-09-26 18:45:25 +03:30
Hamid Reza Mohammadi
bbe892cdf3 security enhancements 2026-09-26 18:22:45 +03:30
Hamid Reza Mohammadi
ce05b9be0e #421 geo tag suggestion 2026-09-25 15:38:22 +03:30
Hamid Reza Mohammadi
13d493978a #421 geo tag moderation 2026-09-25 15:02:57 +03:30
Hamid Reza Mohammadi
fc241748e7 #421 geo tag suggestion + typo fixes in editors 2026-09-25 14:37:51 +03:30
Hamid Reza Mohammadi
de279b75fd #421 geo tag moderation 2026-09-25 13:29:23 +03:30
Hamid Reza Mohammadi
42c4961c82 geo tag suggestion 2026-09-25 13:07:04 +03:30
Hamid Reza Mohammadi
afa5b24ded geotag edit fix 2026-09-25 12:54:51 +03:30
Hamid Reza Mohammadi
ff8f6f3a96 geotag suggestion 2026-09-23 08:11:58 +03:30
Hamid Reza Mohammadi
4aef7ace1b ui for enable users to suggest geo location tags #421 2026-09-20 06:43:36 +03:30
Hamid Reza Mohammadi
f6bd5a756c enable users to suggest geo location tags #421 2026-09-18 17:34:30 +03:30
Hamid Reza Mohammadi
47011429f5 replace resitation 2026-09-17 21:08:41 +03:30
Hamid Reza Mohammadi
e6397afae4 fix shadow 2026-09-14 20:30:50 +03:30
Hamid Reza Mohammadi
fd609f86c5
Merge pull request #509 from emohandesi/feature/music-link-suggestions
Suggest songs by pasting a link, instead of the broken Spotify search
2026-09-14 15:43:46 +03:30
Ehsan Mohandesi
9063f9d732 Give the public data import job its own HttpClient
StartImportFromPublicDataRepo captured the injected, request-scoped HttpClient
inside the queued work item. The request completes long before the background
job runs, so the client was already disposed and the import died immediately
with ObjectDisposedException. Let the job own a client for its lifetime.
2026-09-13 22:16:28 -05:00
Ehsan Mohandesi
cb7b1b03a3 Replace Spotify search with a validated music link box
The Spotify Web API integration stopped working, leaving /spotify unable to
suggest songs at all. Replace the artist/album/track search flow with a single
box where the user pastes a link to the track on a music service.

Links are checked against a hardcoded allow-list of legal streaming and store
domains so links to ripped audio cannot be submitted. The check lives in the
service layer, not just the page: any authenticated user can POST to
/api/ganjoor/song directly and bypass the UI. Hosts are matched against the
full host or a dot-prefixed suffix, so look-alikes such as
open.spotify.com.evil.com are rejected; https is required, and userinfo and
non-default ports are refused. Accepted URLs are canonicalised - https,
lowercased host, tracking parameters stripped - so the same track always yields
the same stored URL and duplicate detection actually works.

Links are stored under one new type, PoemMusicTrackType.MusicUrl, with the
platform derived from the host at render time. That needs no migration or
backfill, and supporting another service later needs no new enum value. The
duplicate check no longer keys on TrackType, which closes a gap where the same
URL could be resubmitted as a different type. Several links per poem remain
allowed; only an identical URL for the same poem is refused.

The Spotify search page and its OAuth plumbing are kept and simply redirect to
/musiclink while the existing SpotifyWorking flag is false, so the old flow can
be restored if that API ever works again.

Track URLs are no longer written through Html.Raw into href attributes. They
previously came from the Spotify API; now that they are user supplied, encoding
them prevents stored XSS.

Also fixes two latent bugs in SuggestSong that this flow would have hit: a null
dereference when TrackUrl is empty, and a singer lookup that matched any singer
with an empty Url.
2026-09-13 22:16:18 -05:00
Hamid Reza Mohammadi
0811bfd868 moderation new option 2026-09-13 13:39:48 +03:30