Mostly a classical "extract the flag from compiler messages" challenge, except you don't directly have the compiler but only the language server.
You'll have to speak a bit of the protocol, send a payload C file that includes the flag and #define ictf int some_function to then read off the unknown variable diagnostic the compiler sends you.
run ltrace to get the secret key, enter the secret key in the print flag function.
After that you will get a string. As you maybe saw with strings its probably the encrypted flag with aes-ecb
Use ghidra or some other tool and find the key. You will find the key in 1 function. Its not static, so you need to reverse that.
Its just adding 0x3, and then finally you can decrypt it to get the flag.(You can use cyberchef, python or some other languages/tools)
Recover the modulus n through gcd with some pairs E(x^2) - E(x)^2, it turns out it's a fairly small modulus.
Simply factor it and take a discrete log of E(x) to basis x to recover the exponent e.
From there, just decrypt the key and decrypt the flag.