Skip to content

Instantly share code, notes, and snippets.

#include <stdlib.h>
#include <stdio.h>
#include <time.h>
#include <sys/socket.h>
#include <netinet/in.h>
#include <string.h>
int main(int argc, char *argv[]) {
printf("hello\n");
(node:24776) Error Plugin: heroku-destroy-temp: files attribute must be specified in /Users/jkutner/.local/share/heroku/node_modules/heroku-destroy-temp/package.json
module: @oclif/[email protected]
plugin: heroku-destroy-temp
root: /Users/jkutner/.local/share/heroku/node_modules/heroku-destroy-temp
See more details with DEBUG=*
(node:24776) Error Plugin: heroku-repo: files attribute must be specified in /Users/jkutner/.local/share/heroku/node_modules/heroku-repo/package.json
module: @oclif/[email protected]
plugin: heroku-repo
root: /Users/jkutner/.local/share/heroku/node_modules/heroku-repo
See more details with DEBUG=*
#! /bin/bash
BOOT_TIMEOUT=55
forward_wrong_port() {
sleep $BOOT_TIMEOUT
local ports="$(ss -lt | awk '/LISTEN/ { print $4 }' | grep "*:[0-9]*")"
if echo "$ports" | grep -v "*:$PORT$"; then
local user_port="$(echo "$ports" | sed 's/\*://' | head -n 1)"
socat TCP-LISTEN:$PORT,fork TCP:0.0.0.0:$user_port
<?xml version="1.0" encoding="UTF-8"?>
<settings xmlns="http://maven.apache.org/SETTINGS/1.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/SETTINGS/1.0.0 http://maven.apache.org/xsd/settings-1.0.0.xsd">
<profiles>
<profile>
<id>jboss-public-repository</id>
<repositories>
<repository>
<id>jboss-no-bees</id>
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
<modelVersion>4.0.0</modelVersion>
<groupId>com.example</groupId>
<artifactId>spring-demo</artifactId>
<packaging>jar</packaging>
<version>1.0-SNAPSHOT</version>
<name>spring-demo</name>
<url>http://maven.apache.org</url>
BLACK="\[\033[0;38m\]"
RED="\[\033[0;31m\]"
RED_BOLD="\[\033[01;31m\]"
BLUE="\[\033[1;34m\]"
GREEN="\[\033[0;32m\]"
WHITE="\[\033[0;37m\]"
PURPLE="\[\033[0;35m\]"
export PS1="$WHITE[$BLUE\w$WHITE]$GREEN\$HEROKU_CLOUD$RED\$(git name-rev HEAD 2> /dev/null | sed 's#HEAD\ \(.*\)# (git::\1)#')$PURPLE\$(git remote get-url heroku 2> /dev/null | sed 's/https:\/\/git.heroku.com\/\(.*\).git/ (\1)/')$BLACK\n$ \[\e[0m\]"
<?xml version="1.0" encoding="UTF-8"?>
<project xmlns="http://maven.apache.org/POM/4.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
<modelVersion>4.0.0</modelVersion>
<groupId>com.example</groupId>
<version>1.0-SNAPSHOT</version>
<artifactId>helloworld</artifactId>
<packaging>jar</packaging>
import javax.crypto.Cipher;
import javax.crypto.SecretKey;
import javax.crypto.SecretKeyFactory;
import javax.crypto.spec.IvParameterSpec;
import javax.crypto.spec.PBEKeySpec;
import javax.crypto.spec.SecretKeySpec;
import java.security.AlgorithmParameters;
import java.security.spec.KeySpec;
public class JCE {
import javax.net.ssl.SSLSocketFactory;
import javax.net.ssl.SSLContext;
public class SSLTest {
public static void main (String[] args) throws Exception {
SSLContext context = SSLContext.getDefault();
SSLSocketFactory sf = context.getSocketFactory();
String[] cipherSuites = sf.getSupportedCipherSuites();
System.out.println("CipherSuite:");
package com.example.demo;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.web.bind.annotation.*;
import org.springframework.stereotype.*;
@Controller
@SpringBootApplication
public class DemoApplication {