RunestoneInteractive / rs

A New Monorepo structure for Runestone
Other
43 stars 69 forks source link

Can't create Fill in the blank problem, blocked by cloudfare #556

Closed lleskow closed 2 weeks ago

lleskow commented 1 month ago

What Course are you in A Runestone Blue Book

What Page were you on Admin assignements

What is your username ll

Describe the bug While trying to save and add a fill in the blank problem succesfully generated nothing happens. The issue doesn't occurs with mchoice or activecode. It's the same problem with different browsers and computers.

Traceback There's a 403 error with the following response

You can email the site owner to let them know you were blocked. Please include what you were doing when this page came up and the Cloudflare Ray ID found at the bottom of this page.

Cloudflare Ray ID: 8d3f034b4d97035c • Your IP: 2001:861:3002:4d70:a0b5:f6f1:7658:1aa5 • Performance & security by Cloudflare

HTTP/2 403 Forbidden date: Thu, 17 Oct 2024 08:45:30 GMT content-type: text/html; charset=UTF-8 x-frame-options: SAMEORIGIN referrer-policy: same-origin cache-control: max-age=15 expires: Thu, 17 Oct 2024 08:45:45 GMT report-to: {"endpoints":[{"url":"https:\/\/a.nel.cloudflare.com\/report\/v4?s=V7SuDQVIY7B%2FEsWhlN%2BBbSzhrEpuWNQ4OHn8CkRJ%2Ffai84eoNJjxr1vEkbhN8GeyrAHvvV1zIeOMAnggPf7IuYqRcpcdjhsp6Nejud44IUImIcfYjqwG0n1ZolhvUv4rnTrq%2FoNELItdJzxg447l"}],"group":"cf-nel","max_age":604800} nel: {"success_fraction":0,"report_to":"cf-nel","max_age":604800} vary: Accept-Encoding server: cloudflare cf-ray: 8d3f034b4d97035c-CDG content-encoding: br X-Firefox-Spdy: h2

template=fillintheblank&name=u142171217&question=%0A++++..+fillintheblank%3A%3A+u142171217%0A%0A++++++++Put+the+text+of+the+question+here.%0A++++++++See+https%3A%2F%2Frunestone.academy%2Frunestone%2Fbooks%2Fpublished%2Foverview%2FAssessments%2Ffitb.html%0A++++++++for+additional+options+and+documentation.%0A%0A++++++++-+++%3APut+the+correct+answer+here%3A+Put+feedback+displayed+for+this+answer+here.%0A++++++++++++%3Ax%3A+Put+feedback+displayed+for+an+incorrect+answer+here.%0A++++&difficulty=1&tags=&chapter=Exams&subchapter=Exercises&isprivate=true&tab=formative&assignmentid=164222&points=1&timed=false&htmlsrc=%0A++++++++%3Cdiv+class%3D%22runestone+%22%3E%0A++++++++%3Cdiv+data-component%3D%22fillintheblank%22+data-question_label%3D%221%22+id%3D%22u142171217%22++style%3D%22visibility%3A+hidden%3B%22%3E%0A++++++++++++%3Cp%3EQ-1%3A+Put+the+text+of+the+question+here.%0ASee+%3Ca+class%3D%22reference+external%22+href%3D%22https%3A%2F%2Frunestone.academy%2Frunestone%2Fbooks%2Fpublished%2Foverview%2FAssessments%2Ffitb.html%22%3Ehttps%3A%2F%2Frunestone.academy%2Frunestone%2Fbooks%2Fpublished%2Foverview%2FAssessments%2Ffitb.html%3C%2Fa%3E%0Afor+additional+options+and+documentation.%3C%2Fp%3E%0A%3Cinput+type%3D%22text%22%3E%0A++++++++%3Cscript+type%3D%22application%2Fjson%22%3E%0A++++++++++++%5B%5B%7B%22regex%22%3A+%22%5E%5C%5CsPut%5C%5Cs%2Bthe%5C%5Cs%2Bcorrect%5C%5Cs%2Banswer%5C%5Cs%2Bhere%5C%5Cs%24%22%2C+%22regexFlags%22%3A+%22%22%2C+%22feedback%22%3A+%22%3Cp%3EPut+feedback+displayed+for+this+answer+here.%3C%2Fp%3E%5Cn%22%7D%2C+%7B%22regex%22%3A+%22%5E%5C%5Csx%5C%5Cs%24%22%2C+%22regexFlags%22%3A+%22%22%2C+%22feedback%22%3A+%22%3Cp%3EPut+feedback+displayed+for+an+incorrect+answer+here.%3C%2Fp%3E%5Cn%22%7D%5D%5D%0A++++++++%3C%2Fscript%3E%0A%0A++++++++%3C%2Fdiv%3E%0A++++++++%3C%2Fdiv%3E%0A++++++++++++

POST /runestone/admin/createquestion HTTP/2 Host: runestone.academy User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.14; rv:109.0) Gecko/20100101 Firefox/115.0 Accept: application/json, text/javascript, /; q=0.01 Accept-Language: fr,fr-FR;q=0.8,en-US;q=0.5,en;q=0.3 Accept-Encoding: gzip, deflate, br Content-Type: application/x-www-form-urlencoded; charset=UTF-8 X-Requested-With: XMLHttpRequest Content-Length: 1822 Origin: https://runestone.academy DNT: 1 Connection: keep-alive Referer: https://runestone.academy/runestone/admin/assignments Cookie: session_id_runestone=58970749:b368f2f7-351a-4c69-8c1b-127dff54e8d0; route=b695e0f8f84c274afbca59a507bbba0e; cf_clearance=F4D3fMyrxBbLyJOd0pBtDT.HZHXDaDVMbOr9pwMo2Os-1729154626-1.2.1.1-xj5hEsb5WmDKj1jMPrv.Oxr6skGwfluXw.FUikiIxdtpnJsdQMInpJQwA2sTwoFWKd2l6y4TogNn80hTtWiyVR1cYFmu.HBmRdMDVVpTj.CC9NmOqGXu76occ6yLHsSo0TtcNEeS26F.Ej5_3X3OnlUDJOalrGYqqjS_sgvHBlkrLyMmqQJQci2gV3BYNJMZz1S1ijh02Ckwp8tH36_wzcUJpwW4915jbGHYyGYw0Zju0cOjVjhQQIc0WvQ2ndejtcOkPAa5enernoCHfx84RWkyMmDmUQSR31qnowTaIRBMu.8BeEJvTDEjQAvLTWgISq2p9OYUYSRJVDhTQqldJGUFx9ldhE83XOWS5nU5xigeFxD4T6kMOa2Fyc.EHVlNHOZHV4nPDg21wKGRmgcK7k1AzyDd7H10w1JuSOY7_4U; access_token=eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJzdWIiOiJsbCIsImV4cCI6MTczODIyNjYzMX0.P4OTIkIH8y-0MWwSTUtYz0xgZyfpQWBnBCW-OUq7WrQ; RS_info="{\"readings\": []\054 \"tz_offset\": -2.0}"; CookieInfoScript=1 Sec-Fetch-Dest: empty Sec-Fetch-Mode: cors Sec-Fetch-Site: same-origin TE: trailers

bnmnetp commented 1 month ago

CloudFlare is letting the vast majority of these go through... I'm not sure why it is choosing to block you. I'll have to investigate. You are coming from France??

bnmnetp commented 1 month ago

It appears that whatever a fill in the blank question is triggering a html-injection script tag rule...

bnmnetp commented 2 weeks ago

Fixed