Phison based flash drives have various modes that dictate how they operate;
- as a regular flash drive (mode 3)
- as a dual-volume flash drive (mode 7)
- as a single volume flash drive + cdrom (mode 21)
// Usage: swift remove_alpha_channel.swift filename.png | |
import Foundation | |
import CoreImage | |
let arguments = CommandLine.arguments | |
let filename = arguments[1] | |
let dataProvider = CGDataProvider(filename: filename)! | |
let cgImage = CGImage(pngDataProviderSource: dataProvider, decode: nil, shouldInterpolate: true, intent: .defaultIntent)! |
public extension UIImage { | |
public struct FlipOptions: OptionSet { | |
public typealias RawValue = Int | |
public let rawValue: RawValue | |
public init(rawValue: RawValue) { | |
self.rawValue = rawValue |
/* | |
* Star Micronics | |
* | |
* CUPS Filter | |
* | |
* [ Linux ] | |
* compile cmd: gcc -Wl,-rpath,/usr/lib -Wall -fPIC -O2 -o rastertostar rastertostar.c -lcupsimage -lcups | |
* compile requires cups-devel-1.1.19-13.i386.rpm (version not neccessarily important?) | |
* find cups-devel location here: http://rpmfind.net/linux/rpm2html/search.php?query=cups-devel&submit=Search+...&system=&arch= | |
* |
Psync;1;0 # **RESERVED COMMAND** | |
<HEADER>Psmgr;1 # **RESERVED COMMAND** | |
Ppws;1537499426 # **RESERVED COMMAND** | |
Pps;0;n # Printer status after reply. (0=disable 1=enable);(n=force no persistent, 0=disable printer status extension;1=enable printer status extension) | |
Pcla;1 # **RESERVED COMMAND** | |
Psid;2 # **RESERVED COMMAND** Set current session identification number | |
Pr;0;t # Read ribbon value (0=RIBBON_YMCKO);(t=Previous parameter is a number, not a string) | |
Pwres;300;300;0 # Card resolution? | |
Psk;10 # Monochrome print speed (10=fastest, 1=slowest) | |
Piqla;a;d # Print quality level adjust (a=activate adjustment, d=disable) |
#include "Mac.h" | |
Mac::Mac(){ | |
for(int i=0;i<6;i++){ | |
adress[i] = 0x00; | |
} | |
} | |
Mac::Mac(uint8_t first, uint8_t second, uint8_t third, uint8_t fourth, uint8_t fifth, uint8_t sixth){ | |
adress[0] = first; |
url - https://aws.amazon.com/blogs/security/a-safer-way-to-distribute-aws-credentials-to-ec2/ | |
Finding hard-coded credentials in your code | |
Hopefully you’re excited about deploying credentials to EC2 that are automatically rotated. Now that you’re using Roles, a good security practice would be to go through your code and remove any references to AKID/Secret. We suggest running the following regular expressions against your code base: | |
Search for access key IDs: (?<![A-Z0-9])[A-Z0-9]{20}(?![A-Z0-9]). In English, this regular expression says: Find me 20-character, uppercase, alphanumeric strings that don’t have any uppercase, alphanumeric characters immediately before or after. | |
Search for secret access keys: (?<![A-Za-z0-9/+=])[A-Za-z0-9/+=]{40}(?![A-Za-z0-9/+=]). In English, this regular expression says: Find me 40-character, base-64 strings that don’t have any base 64 characters immediately before or after. | |
If grep is your preferred tool, run a recursive, Perl-compatible search using the following commands |
/* | |
*** Academy Engraved LET *** | |
AcademyEngravedLetPlain | |
--------------------- | |
*** Al Nile *** | |
AlNile | |
AlNile-Bold | |
--------------------- | |
*** American Typewriter *** | |
AmericanTypewriter |