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
import UIKit | |
extension NSMutableAttributedString { | |
func highlightTarget(target: String, color: UIColor) -> NSMutableAttributedString { | |
let targetValue = String(target.characters.dropFirst().dropLast()) | |
let regPattern = "\\[\(targetValue)\\]" | |
if let regex = try? NSRegularExpression(pattern: regPattern, options: []) { | |
let matchesArray = regex.matchesInString(self.string, options: [], range: NSRange(location: 0, length: self.length)) | |
for match in matchesArray { |
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
#!/usr/bin/env swift | |
//swiftc facetime_cli.swift -o facetime_cli | |
// sudo cp facetime_cli /usr/bin | |
// Enjoy! usage: facetime_cli $PHONE_NUMBER or $APPLE_ID | |
import Foundation | |
import Cocoa | |
extension Array { |
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
//LOAD CSV script for GFTS data | |
create constraint on (a:Agency) assert a.id is unique; | |
create constraint on (r:Route) assert r.id is unique; | |
create constraint on (t:Trip) assert t.id is unique; | |
create index on :Trip(service_id); | |
create constraint on (s:Stop) assert s.id is unique; | |
create index on :Stoptime(stop_sequence); | |
create index on :Stop(name); | |
schema await |
This gist contains lists of modules available in
in AWS Lambda.
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
/* | |
nfc_creditcard_reader by Jose Miguel Esparza (jesparza AT eternal-todo.com) | |
http://eternal-todo.com | |
Based on the PoC readnfccc by Renaud Lifchitz ([email protected]) | |
Fixed to work with libnfc 1.7.4 by bluec0re | |
License: distributed under GPL version 3 (http://www.gnu.org/licenses/gpl.html) |
For these hacks the iPhone must be jailbroken. But there currently is a jailbreak available for iOS 8.4 and some below. 4 digit pins can be bruteforced unless there is a attempt limit. Even with the limit it can still be hacked but you would need to break the phone open to rig the power to cut before the attempt is registered. Example here.
For all of these you need:
- Phone to be jailbroken
- OpenSSH installed on the phone
###1) Dump the iOS Keychain
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
/**************************************************************************/ | |
/*! | |
This example attempts to dump the contents of a Mifare Ultralight card | |
Note that you need the baud rate to be 115200 because we need to print | |
out the data and read from the card at the same time! | |
To enable debug message, define DEBUG in PN532/PN532_debug.h | |
Edited by Sam Decrock to read out Mifare Ultralight cards |
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
// | |
// FileUploader.swift | |
// | |
// Copyright (c) 2015 Narciso Cerezo Jiménez. All rights reserved. | |
// Largely based on this stackoverflow question: http://stackoverflow.com/questions/26121827/uploading-file-with-parameters-using-alamofire/28467829// | |
import Foundation | |
import Alamofire | |
private struct FileUploadInfo { |