Skip to content

Instantly share code, notes, and snippets.

@captn3m0
captn3m0 / muzi-blog-post.md
Created February 27, 2014 09:11
Blog post of new updates in Muzi. Publishing here since blog.sdslabs.co is down.

Muzi has consistently been our most popular application, and we've worked on it continously over time to make it even better. Today, we announce a slew of new features that we've brought to muzi. We hope these features will help you use Muzi more extensively. As always, we are [open to feedback][feedback] regarding these new features or any bugs you may face.

##Nano

For those of you who have created lots of playlists on Muzi, we bring you [Nano][nano], a specially crafted light version of Muzi. It was designed from the ground up to be lightweight, minimal, and above all easily usable. It does not boast of all the features that Muzi has, but it more than makes up for it with its beautiful interface. Just hit (you must be logged in), choose a playlist, and you're all set. Repeat is enabled by default in Nano, and you can turn on shuffle at will. The share link is available directly in Nano for you to use as well. The controls (including keyboard shortcuts) for Nano are same as th

@captn3m0
captn3m0 / jsbin.qitowijo.css
Created March 7, 2014 16:56
A basic mockup of our new status page.
.header{
position: fixed;
top: 50%;
left: 50%;
margin-top: -50px;
margin-left: -100px;
}
.min{
font-family: 'Simonetta', cursive;
}
@captn3m0
captn3m0 / keybase.md
Created June 15, 2014 09:26
keybase.io

Keybase proof

I hereby claim:

  • I am captn3m0 on github.
  • I am captn3m0 (https://keybase.io/captn3m0) on keybase.
  • I have a public key whose fingerprint is CD8A 6149 3FF2 A8AC 9B16 4551 D7BB DF1B B896 3685

To claim this, I am signing this object:

@captn3m0
captn3m0 / 01-README.md
Created August 11, 2014 17:00
ENML Scrubber in ruby using Loofah

The problem is converting a valid html document to a valid ENML (Evernote Markup Language) schema. Validation is performed, but performing validation over and over is not a good solution. The idea is to transform the doc by scrubbing out invalid tags and attributes, which come under the following categories:

  1. allowed_tags : These are the only valid tags in ENML, and have a set of valid attributes for each
  2. disallowed_tags: Remove these tags completely from the doc

If a tag other than these is found, strip it (replace it with its children). To "know which tags to remove and which to keep", I have a dtd file (enml2.dtd) and want to parse it.

@captn3m0
captn3m0 / iitr-ip-check.md
Last active August 29, 2015 14:06
Simple script to check if visitor is from IITR (Ruby)

Sample ruby code to check if the request IP is from a location in IIT-Roorkee.

  • Remember to install the netaddr gem.
  • IP ranges used from http://www.iitr.ac.in/radware/
  • If you are using cloudflare, install mod_cloudflare for apache
@captn3m0
captn3m0 / README.md
Created October 6, 2014 03:42
ecryptfs-performance-hit-trusty

According to my tests, I take a 18.89% performance hit because of using ecryptfs. I understand this is not much, but just wanted to test and document it anyway.

Hard Disk Model: Western Digital, WDC WD5000LPVX-2, 500GB (465GiB)

##With ecryptfs

$ time dd if=/dev/zero of=filename bs=1024 count=1000000

1000000+0 records in
1000000+0 records out
@captn3m0
captn3m0 / response.txt
Last active August 29, 2015 14:13
Yureka Deal Status
HTTP/1.1 200 OK
Date: Tue, 13 Jan 2015 10:21:18 GMT
Server: Server
x-amzn-RequestId: ea145a86-9b0d-11e4-a894-931a3cd42caf
X-Amz-Date: Tue, 13 Jan 2015 10:21:19 GMT
Content-Type: application/json
Content-Length: 2852
Vary: Accept-Encoding,User-Agent
@captn3m0
captn3m0 / 01-README.md
Last active August 29, 2015 14:14
HackIM 2015 Web 500 Write-up Source Code

#Output

Final output of the tool

Attempt number 50
Code is yGrkeP
           Score :50 
Attempt number 51
Code is tcrYlt

Score :51Flag is H@CKIM_C@pTcha!09022015

@captn3m0
captn3m0 / 01-README.md
Created April 2, 2015 15:04
Backdoor CTF 15 leaderboard (submitted to CTFTime)

Just make sure that the team name you see here is added as an alias in your ctftime team profile page.