CARVIEW |
Select Language
HTTP/2 200
date: Fri, 10 Oct 2025 03:23:00 GMT
content-type: text/html; charset=utf-8
vary: X-PJAX, X-PJAX-Container, Turbo-Visit, Turbo-Frame, X-Requested-With,Accept-Encoding, Accept, X-Requested-With
etag: W/"23ae8dbcb73d36a98c6ded2ea7561335"
cache-control: max-age=0, private, must-revalidate
strict-transport-security: max-age=31536000; includeSubdomains; preload
x-frame-options: deny
x-content-type-options: nosniff
x-xss-protection: 0
referrer-policy: origin-when-cross-origin, strict-origin-when-cross-origin
content-security-policy: default-src 'none'; base-uri 'self'; child-src github.githubassets.com github.com/assets-cdn/worker/ github.com/assets/ gist.github.com/assets-cdn/worker/; connect-src 'self' uploads.github.com www.githubstatus.com collector.github.com raw.githubusercontent.com api.github.com github-cloud.s3.amazonaws.com github-production-repository-file-5c1aeb.s3.amazonaws.com github-production-upload-manifest-file-7fdce7.s3.amazonaws.com github-production-user-asset-6210df.s3.amazonaws.com *.rel.tunnels.api.visualstudio.com wss://*.rel.tunnels.api.visualstudio.com github.githubassets.com objects-origin.githubusercontent.com copilot-proxy.githubusercontent.com proxy.individual.githubcopilot.com proxy.business.githubcopilot.com proxy.enterprise.githubcopilot.com *.actions.githubusercontent.com wss://*.actions.githubusercontent.com productionresultssa0.blob.core.windows.net/ productionresultssa1.blob.core.windows.net/ productionresultssa2.blob.core.windows.net/ productionresultssa3.blob.core.windows.net/ productionresultssa4.blob.core.windows.net/ productionresultssa5.blob.core.windows.net/ productionresultssa6.blob.core.windows.net/ productionresultssa7.blob.core.windows.net/ productionresultssa8.blob.core.windows.net/ productionresultssa9.blob.core.windows.net/ productionresultssa10.blob.core.windows.net/ productionresultssa11.blob.core.windows.net/ productionresultssa12.blob.core.windows.net/ productionresultssa13.blob.core.windows.net/ productionresultssa14.blob.core.windows.net/ productionresultssa15.blob.core.windows.net/ productionresultssa16.blob.core.windows.net/ productionresultssa17.blob.core.windows.net/ productionresultssa18.blob.core.windows.net/ productionresultssa19.blob.core.windows.net/ github-production-repository-image-32fea6.s3.amazonaws.com github-production-release-asset-2e65be.s3.amazonaws.com insights.github.com wss://alive.github.com wss://alive-staging.github.com api.githubcopilot.com api.individual.githubcopilot.com api.business.githubcopilot.com api.enterprise.githubcopilot.com; font-src github.githubassets.com; form-action 'self' github.com gist.github.com copilot-workspace.githubnext.com objects-origin.githubusercontent.com; frame-ancestors 'none'; frame-src viewscreen.githubusercontent.com notebooks.githubusercontent.com; img-src 'self' data: blob: github.githubassets.com media.githubusercontent.com camo.githubusercontent.com identicons.github.com avatars.githubusercontent.com private-avatars.githubusercontent.com github-cloud.s3.amazonaws.com objects.githubusercontent.com release-assets.githubusercontent.com secured-user-images.githubusercontent.com/ user-images.githubusercontent.com/ private-user-images.githubusercontent.com opengraph.githubassets.com marketplace-screenshots.githubusercontent.com/ copilotprodattachments.blob.core.windows.net/github-production-copilot-attachments/ github-production-user-asset-6210df.s3.amazonaws.com customer-stories-feed.github.com spotlights-feed.github.com objects-origin.githubusercontent.com *.githubusercontent.com; manifest-src 'self'; media-src github.com user-images.githubusercontent.com/ secured-user-images.githubusercontent.com/ private-user-images.githubusercontent.com github-production-user-asset-6210df.s3.amazonaws.com gist.github.com; script-src github.githubassets.com; style-src 'unsafe-inline' github.githubassets.com; upgrade-insecure-requests; worker-src github.githubassets.com github.com/assets-cdn/worker/ github.com/assets/ gist.github.com/assets-cdn/worker/
server: github.com
content-encoding: gzip
accept-ranges: bytes
set-cookie: _gh_sess=7XkjufzI%2F5RSZ%2BxC5tvaeoEJNMwjfUqNeaDTiDZIdxF73AbUeCmRNgpm4GQdzK%2BUiqL7kNgxWEjurSLunjupJE7bZuNPI8Bbpbw2huBdBo7kCRJIZb5YCeKO5CRK3pCoO0l9DN%2FlMg8xtCjVO1C9J1qC2%2FlfvLzPMOvfepWQI4Zr2qM685iygBmMqL4ymHvrumYBnVA2b3iUvk5xicK9%2BpMwAjhi4Hxi0gtrv9FrdeGC%2BuobI4ajL2ltKvEd8p1Ttv7UTRjhGVec9JXevPET9w%3D%3D--yN0GkDzakuCQMlpR--K3Fd5xQ%2Blwm82hxS8q2Osg%3D%3D; Path=/; HttpOnly; Secure; SameSite=Lax
set-cookie: _octo=GH1.1.634498717.1760066579; Path=/; Domain=github.com; Expires=Sat, 10 Oct 2026 03:22:59 GMT; Secure; SameSite=Lax
set-cookie: logged_in=no; Path=/; Domain=github.com; Expires=Sat, 10 Oct 2026 03:22:59 GMT; HttpOnly; Secure; SameSite=Lax
x-github-request-id: ECCE:66FF4:11F661F:15D6D50:68E87C13
second_stage.py · GitHub
Show Gist options
Save balidani/91326787a8900b3a2c2d to your computer and use it in GitHub Desktop.
{{ message }}
Instantly share code, notes, and snippets.
balidani/second_stage.py Secret
Created
May 19, 2014 01:15
-
Star
0
(0)
You must be signed in to star a gist -
Fork
0
(0)
You must be signed in to fork a gist
-
Save balidani/91326787a8900b3a2c2d to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
seed = open('seed', 'rb').read() | |
count_max = 0xf81000 - 0x20 | |
def calc4(buf, arg2): | |
res = 0 | |
for arg3 in range(4): | |
res |= calc(buf, arg2, arg3) | |
return res | |
def calc(buf, arg2, arg3): | |
shift = arg2 >> 3 | |
w = arg2 & 7 | |
v1 = ord(buf[shift + arg3]) | |
esi = v1 << w | |
v2 = ord(buf[shift + arg3 + 1]) | |
edx = v2 >> (8 - w) | |
eax = (esi | edx) & 0xff | |
eax = eax << [24, 16, 8, 0][arg3] | |
return eax | |
def unloop(id): | |
i = id / 4 | |
j = id % 4 | |
count1 = i / count_max | |
count2 = i % count_max | |
result = calc4(seed, count1) ^ calc4(seed, count2) | |
return (result >> [24, 16, 8, 0][j]) & 0xff | |
# We got these after running the first part of the solution | |
otp = [599521712711912, 856316164104560, 851375299807737, 226795474523010, 690343477575657, 530610340387377, 402190494029161, 435574450270296, 1003903144987565, 933916790309578, 576245728766126, 588241585631380, 897535963540551, 184202982571948, 755391352053788, 499858102942276, 573081870210472, 801849170089785, 638395633557041, 799213889332420, 1055945742133509, 525694201254105, 1047919585821714, 120655124875111, 178112910059018, 681464867239468, 330601444697131, 713225398903763, 449046221226234, 684150454390929, 83445625775525, 216053647017703, 28210504105632, 667024320238515, 630378564532229, 289267338813144, 601558443994855, 770418906081774] | |
flag = [0x03, 0x74, 0xef, 0xa1, 0x22, 0x15, 0xf5, 0x27, 0x35, 0xfb, 0xca, 0xfa, 0xe6, 0xd8, 0x77, 0x85, 0xd4, 0x79, 0x76, 0x23, 0x50, 0xef, 0x57, 0xd9, 0x7a, 0xf7, 0x81, 0xdb, 0x89, 0x49, 0x4e, 0xff, 0xc1, 0xc9, 0xbc, 0x7a, 0x46, 0x69] | |
print ''.join([chr(unloop(o) ^ f) for o, f in zip(otp, flag)]) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
You can’t perform that action at this time.