content
stringlengths
263
5.24M
pred_label
stringclasses
1 value
pred_score_pos
float64
0.6
1
#include <map> #include <cstdlib> #include <glib-object.h> #include <json-glib/json-glib.h> #include "Helpers.h" #include "OrderNewSingleRequest.h" using namespace std; using namespace Tizen::ArtikCloud; OrderNewSingleRequest::OrderNewSingleRequest() { //__init(); } OrderNewSingleRequest::~OrderNewSingleRequest()...
__label__POS
0.62656
package org.voltdb.regressionsuites.specexecprocs; import org.apache.log4j.Logger; import org.voltdb.ProcInfo; import org.voltdb.SQLStmt; import org.voltdb.VoltProcedure; import org.voltdb.VoltTable; import edu.brown.benchmark.tm1.TM1Constants; /** * Simple single-partition transaction that checks to see * whether...
__label__POS
0.672507
# Vault ## Description A binary is given ## Solution Let's reverse the code using [Ghidra](https://ghidra-sre.org/). ```c undefined8 main(void) { int iVar1; undefined8 *__s1; char *__s; __s1 = (undefined8 *)malloc(0x1a); *__s1 = 0x7e394c2f38323434; __s1[1] = 0x54834c1f7b783a78; __s1[2] = 0x2f72857...
__label__POS
0.88116
# About Time ## Description > Let's see if you can figure out this password.. > > Use the following command to connect to the server and interact with the binary! > > `nc challenges.tamuctf.com 4321` Tha binary corresponding to the service is provided. ## Solution Let's connect to the service. ![about time](../i...
__label__POS
0.761668
# BBPWN ## Description > Welcome to pwnland! > > `nc challenges.tamuctf.com 4252` The corresponding binary is given. ## Solution Let's reverse the code using [Ghidra](https://ghidra-sre.org/). ```c /* WARNING: Function: __x86.get_pc_thunk.bx replaced with injection: get_pc_thunk_bx */ undefined4 main(void) { ...
__label__POS
0.640538
package org.voltdb.regressionsuites.specexecprocs; import org.apache.log4j.Logger; import org.voltdb.ProcInfo; import org.voltdb.SQLStmt; import org.voltdb.VoltProcedure; import org.voltdb.VoltTable; import edu.brown.benchmark.tm1.TM1Constants; import edu.brown.utils.ThreadUtil; @ProcInfo( partitionParam = 0, ...
__label__POS
0.605852
# Mental Math ## Description > My first web app, check it out! > > http://mentalmath.tamuctf.com > > Hint: I don't believe in giving prizes for solving questions, no matter how many! ![mentalmath](../images/mentalmath.png) ## Solution The website is a simple webapp where simple math challenges are given. We may an...
__label__POS
0.912543
# Password Extraction ## Description > The owner of this website often reuses passwords. Can you find out the password they are using on this test server? > > http://passwordextraction.tamuctf.com > > You do not need to use brute force for this challenge. The website is a simple login form. ## Solution The simpl...
__label__POS
0.900073
# Eternal Game ## Description > No one has ever won my game except me! > > `nc challenges.tamuctf.com 8812` The source code of the game is given: ```python from collections import defaultdict import random import hashlib import sys x = 1 d = defaultdict(int) game_running = True high_score = 65308606989177490446610...
__label__POS
0.700734
# Comprehensive 2 > His power level increased... What do I do now?? > > Output: [1, 18, 21, 18, 73, 20, 65, 8, 8, 4, 24, 24, 9, 18, 29, 21, 3, 21, 14, 6, 18, 83, 2, 26, 86, 83, 5, 20, 27, 28, 85, 67, 5, 17, 2, 7, 12, 11, 17, 0, 2, 20, 12, 26, 26, 30, 15, 44, 15, 31, 0, 12, 46, 8, 28, 23, 0, 11, 3, 25, 14, 0, 65] Att...
__label__POS
0.76354
# Bad Python > My friend wrote a cool program to encode text data! His code is sometimes hard to understand, and only he knows how it works. I ran the program twice, but forgot the input I used for the first time. I didn't save the key I used either, but I know it was 15 characters long. Can you figure out what text I...
__label__POS
0.99782
# Difficult Decryption > We intercepted communication between two VERY important people, named Alice and Bob. Can you figure out what this is supposed to mean? > > Alice: "Bob, I need to tell you something." > > Bob: "What?" > > Alice: "It's top-secret, so let's use a secure encryption method." > > Bob: "Is that r...
__label__POS
0.997495
package org.voltdb.regressionsuites.specexecprocs; import org.voltdb.ProcInfo; import org.voltdb.VoltTable; import edu.brown.benchmark.smallbank.procedures.SendPayment; /** * Special version of SmallBank's SendPayment that is not blockable but * will not abort if there is no data. * @author pavlo */ @ProcInfo( ...
__label__POS
0.76513
# El Primo > My friend just started playing Brawl Stars and he keeps raging because he can't beat El Primo! Can you help him? > > nc p1.tjctf.org 8011 ## Description Let's decompile the binary with Ghidra. ```c undefined4 main(void) { char local_30 [32]; undefined *local_10; local_10 = &stack0x00000004; ...
__label__POS
0.649751
package org.voltdb.regressionsuites.specexecprocs; import java.util.HashMap; import java.util.Map; import java.util.concurrent.Semaphore; import org.apache.log4j.Logger; import org.voltdb.ProcInfo; import org.voltdb.SQLStmt; import org.voltdb.VoltProcedure; import org.voltdb.VoltTable; import edu.brown.benchmark.tm1...
__label__POS
0.647296
# Gotta Decrypt Them All > You are stuck in another dimension while you were riding Solgaleo. > You have Rotom-dex with you to contact your friends but he won't activate the GPS unless you can prove yourself to him. > He is going to give you a series of phrases that only you should be able to decrypt and you have a l...
__label__POS
0.626554
# haySTACK > Help! I've lost my favorite needle! > > nc pwn.chal.csaw.io 5002 ## Description We are given the binary. We give it to Ghidra to get the disassembled code: *Note: I renamed functions and variables for clarity*. ```c void init_stack(void) { long lVar1; long in_FS_OFFSET; int iVar2; lVar1 = *...
__label__POS
0.880808
# Ninja > Hey guys come checkout this website i made to test my ninja-coding skills. > > http://web.chal.csaw.io:5000 ## Description The website only has a field where we can input stuff, and it is reflected to us on another page. ![](../images/ninja.png) We can inject javascript but that will not help us. I tri...
__label__POS
0.941973
# Mr Game and Watch ## Description > My friend is learning some wacky new interpreted language and different hashing algorithms. He's hidden a flag inside this program but I cant find it... > > He told me to connect to challenges.auctf.com 30001 once I figured it out though. We are given a `.class` file. ## Soluti...
__label__POS
0.967012
#include <iostream> #include <sstream> #include <cstdlib> #include <map> #include <list> #include <cstring> #include "Helpers.h" #include "Object.h" using namespace std; using namespace Tizen::ArtikCloud; void helper_func(JsonObject *object, const gchar* member_name, JsonNode *member_node,gpointer user_data) { gcha...
__label__POS
0.781922
# Cracker Barrel ## Description > I found a USB drive under the checkers board at cracker barrel. My friends told me not to plug it in but surely nothing bad is on it? > > I found this file, but I can't seem to unlock it's secrets. Can you help me out? > > Also.. once you think you've got it I think you should try ...
__label__POS
0.917897
# Thanksgiving Dinner ## Description > I just ate a huge dinner. I can barley eat anymore... so please don't give me too much! > > nc challenges.auctf.com 30011 > > Note: ASLR is disabled for this challenge The corresponding binary is given. ## Solution When connecting to the challenge, we see a string, then we ...
__label__POS
0.912031
# Extraordinary ## Description > On their way back from the market, Alice and Bob noticed a little device on the ground. Next to it was a piece of paper with what looked like a bunch of scrambled numbers on it. It looked completely random. They took it to the lost and found, but on their way they played with it a lit...
__label__POS
0.957097
package org.voltdb.regressionsuites.prefetchprocs; import org.voltdb.ProcInfo; import org.voltdb.SQLStmt; import org.voltdb.VoltProcedure; import org.voltdb.VoltTable; import edu.brown.interfaces.Prefetchable; import edu.brown.utils.ThreadUtil; @ProcInfo( partitionInfo = "TABLEA.A_ID: 0", singlePartition = f...
__label__POS
0.772264
package org.voltdb.benchmark.tpcc; import edu.brown.BaseTestCase; import edu.brown.statistics.Histogram; import edu.brown.statistics.ObjectHistogram; import edu.brown.utils.ProjectType; public class TestTPCCSimulation extends BaseTestCase { private static int NUM_WAREHOUSES = 8; private ScaleParameters...
__label__POS
0.918614
# Escape from ELF > > A good traveller is one who knows how to travel with the mind. > > Un de vos collègues vous a envoyé un programme qu'il a développé et souhaite vous défier. > > Fournissez-lui les mots de passe les plus courts validant votre accès. ## Description Let's decompile the binary with Ghidra. As usual...
__label__POS
0.930699
# Lost in C++ > Corrigez le code et obtenez le flag. ```cpp #include <iostream> #include <string> #include <algorithm> #include <utility> #include <vector> #include <thread> #include <condition_variable> #define MAX_CHAR 19 class Token { std::array<char, MAX_CHAR> r_; public: void set(int pos, char c, int...
__label__POS
0.760529
# PCAP 101 > Un flux TCP suspect nous a été fourni, pouvez-vous découvrir les données qui s'y cachent ? ## Description I open the pcap file with Wireshark. As I know I am looking for a TCP stream, I right click on the first one I find, `Follow -> TCP Stream`. A lot of streams look the same, except the HTTP request ...
__label__POS
0.989405
# Yet Another Ridiculous Acronym > Sauras-tu écrire une signature qui détecte le bon binaire à partir des marquants extraits dans l'analyse ci-jointe ? ![r2.png](../images/r2.png) Attached is a compressed folder containing around 1000 binaries. ## Description When I look at the binaries, I see that running them wi...
__label__POS
0.704922
# Spaceships > Everything that lives is designed to end. > > Attention all units: we have detected a rogue AI within one of our simulations. The machine possesses advanced capabilities and is rapidly adapting to our tactics. We need you to engage with the enemy and neutralize the threat using any means necessary. Prep...
__label__POS
0.922088
# Moth > Find the correct entry. ## Description Let's reverse this program using Ghidra. I find the address of the `main` function as the first argument of `__libc_start_main` in the `entry` function. Here is the decompiled code: ```c int main(int argc,char **argv) { int iVar1; size_t sVar2; if (argc ==...
__label__POS
0.901732
# In the Kitchen Wrist Twistin like it's Stir Fry ## Description > I love a little strfry > > nc ctf.umbccd.io 5100 ## Solution Let's connect to the server. ![strfry](../images/strfry.png) The challenge is then to scramble the given strings (there are 30 of them) in order to get the flag. For every string, we hav...
__label__POS
0.924114
# Left Foot Two Stomps ## Description > n=960242069 e=347 > c=346046109,295161774,616062960,790750242,259677897,945606673,321883599,625021022,731220302,556994500,118512782,843462311,321883599,202294479,725148418,725148418,636253020,70699533,475241234,530533280,860892522,530533280,657690757,110489031,271790171,221180...
__label__POS
0.881482
package edu.brown; import java.util.ArrayList; import java.util.List; import java.util.concurrent.CountDownLatch; import junit.framework.TestCase; import org.voltdb.VoltProcedure; import org.voltdb.client.ClientResponse; import org.voltdb.client.ProcedureCallback; import edu.brown.hstore.PartitionExecutor; import e...
__label__POS
0.640062
# Benford's Law Firm, LLC ## Description > Someone's faking their finances. Can you figure out which file has fake financial data? A zip is joined. ## Solution We unzip the file and this gives us hundreds of CSV files, with each a different flag as their name. They look like this ![benford](../images/benford.png)...
__label__POS
0.614078
# Iconic License > Pour pouvoir continuer à participer au FCSC il faut acheter une licence au prix modique de 1 Gogol€. Pourrez-vous trouver une licence valide ? We are given a .exe file. ## Reverse engineering Let's reverse the file with [Ghidra](https://ghidra-sre.org/). As it is a Windows executable, I am using...
__label__POS
0.717336
# My Tailor is Rich > Vos collègues experts en reverse engineering ont reconstitué un algorithme d'encodage de mots de passe d'un certain équipement. Ils se doutent qu'il est cryptographiquement faible mais ils font appel à vos services pour le démontrer. > > nc challenges.france-cybersecurity-challenge.fr 2100 ```p...
__label__POS
0.983894
# T-Rex > Vous devez déchiffrer le flag :-) ```python import os from Crypto.Cipher import AES from Crypto.Util.Padding import pad class TRex: def __init__(self, key): N = len(key) M = 2 ** (8 * N) self.key = key self.iv = int.from_bytes(key, "big") R = lambda x: ((2 * x + 1) * x) for _ in range(31337): ...
__label__POS
0.959452
# The Devil Never Sleeps > If you put the devil to sleep, you will get the flag successfully. Unfortunately, the devil never sleeps. But what if you use some sleeping pills? > > http://194.5.207.57:8080 ## Description If we go to the website, we are greeted with the following: > To get sleeping pills, navigate to /s...
__label__POS
0.800751
# Common Factor > How much do you know about the RSA algorithm? ## Description We are given a Python file ```python from Crypto.Util.number import * from functools import reduce def encrypt(msg, n): enc = pow(bytes_to_long(msg), e, n) return enc e = 65537 primes = [getPrime(2048) for i in range(5)] n =...
__label__POS
0.909455
package edu.brown.statistics; import java.util.HashSet; import java.util.Map; import java.util.Random; import java.util.Set; import org.junit.Test; import junit.framework.TestCase; public class TestHistogramUtil extends TestCase { private static final int NUM_SAMPLES = 100; private static final int RANGE =...
__label__POS
0.941177
# Casino > Get rich. ## Description We are given an APK file. I fire [Android Studio](https://developer.android.com/studio) and run the APK on an emulator. ![casino](../images/casino_app.png) There are 2 relevant tabs: one for training and one for getting the flag. On the training tab, we need to guess the next nu...
__label__POS
0.677846
# Heavy Computation > A friend of mine handed me this script and challenged me to recover the flag. However, I started running it on my school cluster and everything is burning now... Help me please! ## Description We are given a Python script ```python from Crypto.Util.number import bytes_to_long, long_to_bytes fr...
__label__POS
0.796974
# Give Away 1 > Make good use of this gracious give away. > > nc sharkyctf.xyz 20334 ## Description For this one we are given both a library and the executable. Let's dissasemble the executable with [Ghidra](https://ghidra-sre.org/). ```c undefined4 main(void) { init_buffering(&stack0x00000004); FUN_000104c0("G...
__label__POS
0.807656
package edu.brown.logging; import java.util.regex.Matcher; import org.apache.log4j.AppenderSkeleton; import org.apache.log4j.Logger; import org.apache.log4j.spi.LocationInfo; import org.apache.log4j.spi.LoggingEvent; import junit.framework.TestCase; public class TestFastLoggingEvent extends TestCase { class Mo...
__label__POS
0.706831
package edu.brown.logging; import java.util.HashMap; import java.util.Map; import java.util.concurrent.atomic.AtomicBoolean; import junit.framework.TestCase; import org.junit.Test; import edu.brown.benchmark.markov.RandomGenerator; public class TestLoggerUtil extends TestCase { // private long rounds = 1000000...
__label__POS
0.987671
# 8 vers 10 > Bonjour agent, > > Nous avons intercepté un message d'un membre de Hallebarde. Trouvez les informations qu'il a envoyé le plus vite possible. > > Au fait, certains de leurs agents ne chiffrent pas leurs messages, et je pense que celui-ci en fait partie. > > Bonne chance ! On nous donne un fichier avec u...
__label__POS
0.878373
package edu.brown.catalog; import junit.framework.TestCase; public class TestPlanFragmentIdGenerator extends TestCase { private static final int BASE_ID = 1234; private void check(boolean readonly, boolean fastAggregate, boolean fastCombine) { int id = PlanFragmentIdGenerator.createPlanFragm...
__label__POS
0.841597
package edu.brown.profilers; import org.junit.Test; import junit.framework.TestCase; /** * Simple tests for AbstractProfiler * @author pavlo */ public class TestAbstractProfiler extends TestCase { private static final int NUM_COUNTERS = 4; protected class MockProfiler extends AbstractProfiler { ...
__label__POS
0.853381
# La fonte des hashs > Nos experts ont réussi à intercepter un message de Hallebarde : > > 18f2048f7d4de5caabd2d0a3d23f4015af8033d46736a2e2d747b777a4d4d205 > > Malheureusement il est haché ! L'équipe de rétro-ingénierie vous a laissé cette note : > > > Voici l'algorithme de hachage. Impossible de remonter le haché ma...
__label__POS
0.980498
package edu.brown.designer; import java.io.File; import org.voltdb.catalog.Table; import edu.brown.BaseTestCase; import edu.brown.benchmark.tm1.TM1Constants; import edu.brown.hashing.AbstractHasher; import edu.brown.hashing.DefaultHasher; import edu.brown.statistics.WorkloadStatistics; import edu.brown.utils.Project...
__label__POS
0.765883
# Dégâts collatéraux > Bonjour Agent, > > Nous avons réussi à infiltrer une connexion sécurisée d'Hallebarde via une attaque MITM. Malheureusement, cette connexion est chiffrée via un protocole qui semble très similaire à PGP, et même si nous avons un certain contrôle sur les informations qui transitent, nous n'avons ...
__label__POS
0.643812
package edu.brown.terminal; import java.util.ArrayList; import java.util.List; import org.junit.Test; import org.voltdb.benchmark.tpcc.procedures.neworder; import org.voltdb.types.QueryType; import edu.brown.BaseTestCase; import edu.brown.utils.ProjectType; public class TestTokenCompletor extends BaseTestCase { ...
__label__POS
0.725446
package edu.brown.graphs; import java.util.*; import org.voltdb.catalog.*; import edu.brown.BaseTestCase; import edu.brown.designer.*; import edu.brown.utils.ProjectType; public class TestDirectedGraph extends BaseTestCase { protected static AbstractDirectedGraph<DesignerVertex, DesignerEdge> graph; p...
__label__POS
0.775285
package edu.brown.graphs; import java.util.*; import junit.framework.TestCase; import org.json.JSONException; import org.json.JSONObject; import org.json.JSONStringer; import org.voltdb.catalog.*; public class TestAbstractGraphElement extends TestCase { public static class TestElement extends AbstractGraphElem...
__label__POS
0.814332
package edu.brown.graphs; import java.util.ArrayList; import java.util.Arrays; import java.util.List; import junit.framework.TestCase; import org.junit.Test; import org.voltdb.catalog.CatalogType; import edu.brown.graphs.VertexTreeWalker.Direction; import edu.brown.graphs.VertexTreeWalker.TraverseOrder; /** * @au...
__label__POS
0.967315
package edu.brown.hashing; import java.util.HashMap; import java.util.Map; import org.voltdb.benchmark.tpcc.TPCCConstants; import edu.brown.BaseTestCase; import edu.brown.statistics.Histogram; import edu.brown.statistics.ObjectHistogram; public class TestDefaultHasher extends BaseTestCase { private static fina...
__label__POS
0.65573
-module(openapi_order_new_single_request). -export([encode/1]). -export_type([openapi_order_new_single_request/0]). -type openapi_order_new_single_request() :: #{ 'exchange_id' := binary(), 'client_order_id' := binary(), 'symbol_id_exchange' => binary(), 'symbol_id_coinapi' => binary(), ...
__label__POS
0.82484
-module(openapi_order_execution_report). -export([encode/1]). -export_type([openapi_order_execution_report/0]). -type openapi_order_execution_report() :: #{ 'exchange_id' := binary(), 'client_order_id' := binary(), 'symbol_id_exchange' => binary(), 'symbol_id_coinapi' => binary(), 'am...
__label__POS
0.840311
package edu.brown.net; import java.io.IOException; import java.nio.ByteBuffer; import java.nio.channels.ByteChannel; import java.util.ArrayList; public class MockByteChannel implements ByteChannel { private ByteBuffer nextRead; public boolean end = false; public boolean closed = false; public final A...
__label__POS
0.734786
# Compress and Attack > Your goal is to find the flag. > > nc mercury.picoctf.net 2431 The following Python file is provided: ```python #!/usr/bin/python3 -u import zlib from random import randint import os from Crypto.Cipher import Salsa20 flag = open("./flag").read() def compress(text): return zlib.compres...
__label__POS
0.943691
package edu.brown.hstore; import org.voltdb.ProcInfo; import org.voltdb.SQLStmt; import org.voltdb.VoltProcedure; import org.voltdb.VoltTable; import edu.brown.benchmark.ycsb.YCSBConstants; /** * Select Blaster Procedure */ @ProcInfo( singlePartition=true ) public class SelectBlaster extends VoltProcedure { ...
__label__POS
0.699252
import numpy as np def rank_sup(I, rad): nl, nc = I.shape R = np.zeros([nl, nc]) for i in range(-rad, rad+1): # indice de ligne for j in range(-rad, rad+1): # indice de colonne if i != 0: if i < 0: tmp = np.concatenate([I[-i:, :], np.zeros([-i, n...
__label__POS
0.990909
# Spentalkux > Spentalkux 🐍📦 ## Description With such a small description, and no file attached, the first thing to do is to use your favorite search engine to find something interesting. In this case, I have found a Python library: [spentalkux](https://pypi.org/project/spentalkux/). ## Solution ### First versio...
__label__POS
0.980098
# Monster issue > Agent, > > We've got a case of industrial espionage, quite an unusual one at that. An international building contractor - Hamilton-Lowe, has written to us that they are having their private client contracts leaked. > > After conducting initial incident response, they managed to find a hidden direct...
__label__POS
0.637415
# BTLE > I stored my flag inside a remote database, but when I tried to read it back it had been redacted! Can you recover what I wrote? Attached is a PCAP file. ## Description By looking at the pcap file in Wireshark we see that it is Bluetooth communication. A lot of packets don't have relevant data in them. Rel...
__label__POS
0.782782
# Ghost Writer > While I was writing the beginning of my new bestselling novel, a ghost possessed my keyboard and began typing in a flag! I tried to finish the story, but the computer died shortly after. Luckily, my digital voice recorder caught it all. Can you recover it? > > I'm a slow writer, and my custom keyboard...
__label__POS
0.989012
# Alkaloid Stream > I found a weird stream cipher scheme. Can you break this? Attached are a Python file and its output. ```python #!/usr/bin/env python3 import random from flag import flag def keygen(ln): # Generate a linearly independent key arr = [ 1 << i for i in range(ln) ] for i in range(ln): ...
__label__POS
0.662218
# Steroid Stream > I found a weird stream cipher scheme. Can you break this? The Python code: ```python #!/usr/bin/env python3 import random from flag import flag def keygen(ln): # Generate a linearly independent key arr = [ 1 << i for i in range(ln) ] for i in range(ln): for j in range(i): ...
__label__POS
0.896446
package edu.brown.costmodel; import junit.framework.TestCase; import org.voltdb.benchmark.tpcc.TPCCProjectBuilder; import org.voltdb.catalog.Catalog; import org.voltdb.catalog.Database; import edu.brown.workload.*; import edu.brown.workload.filters.ProcedureLimitFilter; public class TestAbstractCostModel extends Te...
__label__POS
0.762927
package edu.brown.costmodel; import java.io.File; import java.util.ArrayList; import java.util.Collection; import java.util.Collections; import java.util.List; import java.util.Random; import org.voltdb.benchmark.tpcc.procedures.neworder; import org.voltdb.catalog.CatalogType; import org.voltdb.catalog.Procedure; imp...
__label__POS
0.71521
package edu.brown.utils; import java.util.ArrayList; import java.util.List; import java.util.Map; import java.util.Random; import junit.framework.TestCase; public class TestTableUtil extends TestCase { private static final int num_cols = 5; private static final int num_rows = 10; private static final R...
__label__POS
0.631674
package edu.brown.utils; import java.util.ArrayList; import java.util.List; import java.util.Map; import java.util.Random; import org.apache.commons.collections15.map.ListOrderedMap; import junit.framework.TestCase; public class TestStringUtil extends TestCase { Random rand = new Random(); /** * ...
__label__POS
0.934675
package edu.brown.utils; import org.junit.Test; import junit.framework.TestCase; /** * @author pavlo */ public class TestEnumUtil extends TestCase { enum CosbyKids { FAT_ALBERT_JACKSON, MUSHMOUTH, DUMB_DONALD, BILL_COSBY, RUSSELL_COSBY, WEIRD_HAROLD, RUDY...
__label__POS
0.827817
package edu.brown.utils; import junit.framework.TestCase; public class TestFormatter extends TestCase { static final String SQL = "SELECT B_NAME " + "from TRADE_REQUEST, SECTOR, INDUSTRY, COMPANY, BROKER, SECURITY " + "where TR_S_SYMB = S_SYMB and " + "S_CO_ID = CO_ID and " ...
__label__POS
0.781875
package edu.brown.utils; import java.util.ArrayList; import java.util.HashSet; import java.util.List; import java.util.Set; import java.util.SortedMap; import java.util.TreeMap; import junit.framework.TestCase; import org.junit.Test; import edu.brown.logging.LoggerUtil; /** * * @author pavlo */ public class Te...
__label__POS
0.985271
package edu.brown.utils; import java.util.ArrayList; import java.util.List; import java.util.concurrent.CountDownLatch; import java.util.concurrent.ScheduledThreadPoolExecutor; import java.util.concurrent.TimeUnit; import java.util.concurrent.atomic.AtomicInteger; import org.voltdb.utils.Pair; import junit.framework...
__label__POS
0.958847
package edu.brown.utils; import java.util.Collection; import java.util.Collections; import java.util.HashMap; import java.util.HashSet; import java.util.Map; import java.util.Random; import java.util.Set; import java.util.TreeSet; import edu.brown.hstore.HStoreConstants; import junit.framework.TestCase; public clas...
__label__POS
0.81155
package edu.brown.protorpc; import static org.junit.Assert.assertFalse; import static org.junit.Assert.assertEquals; import static org.junit.Assert.assertTrue; import java.io.ByteArrayOutputStream; import java.io.IOException; import org.junit.Before; import org.junit.Test; import ca.evanjones.protorpc.Counter; imp...
__label__POS
0.794584
#include <stdlib.h> #include <string.h> #include <stdio.h> #include "reject_reason.h" char* reject_reason_reject_reason_ToString(ems___rest_api_reject_reason__e reject_reason) { char *reject_reasonArray[] = { "NULL", "OTHER", "EXCHANGE_UNREACHABLE", "EXCHANGE_RESPONSE_TIMEOUT", "ORDER_ID_NOT_FOUND", "INVALID_TYP...
__label__POS
0.728024
package edu.brown.oltpgenerator; import java.util.Calendar; import java.util.Date; import java.util.Random; public class RandUtil { private static final Random seed = new Random(); /** * * @param m * @param n * @return An Unsigned numeric value with m total digits, of which n digits ...
__label__POS
0.983207
package edu.brown.oltpgenerator; import org.voltdb.VoltType; import org.voltdb.catalog.Column; public class Utils { public static Column[] getNonNullElements(Column[] itemsArray) { int nCnt = 0; for (Object o : itemsArray) { if (o != null) nCnt++; }...
__label__POS
0.997977
package edu.brown.mappings; import java.util.Random; import edu.brown.mappings.PearsonCorrelationMapping; import junit.framework.TestCase; public class TestPearsonCorrelationMapping extends TestCase { private final Random rand = new Random(0); private final int num_samples = 1000; public stati...
__label__POS
0.967272
package edu.brown.mappings; import java.util.Random; import edu.brown.mappings.RatioMapping; import junit.framework.TestCase; public class TestRatioMapping extends TestCase { private final Random rand = new Random(0); private final int num_samples = 1000; public static double roundToDecimals(d...
__label__POS
0.968098
package edu.brown.rand; import java.util.Random; import edu.brown.BaseTestCase; import edu.brown.statistics.Histogram; import edu.brown.statistics.ObjectHistogram; import edu.brown.benchmark.ycsb.distributions.CustomSkewGenerator; public class TestCustomSkew extends BaseTestCase { private final Random rand = n...
__label__POS
0.995131
/** * */ package edu.brown.rand; import java.util.Random; import edu.brown.statistics.Histogram; import edu.brown.statistics.HistogramUtil; import edu.brown.statistics.ObjectHistogram; import junit.framework.TestCase; /** * @author pavlo * */ public class TestWrappingRandomDistribution extends TestCase { ...
__label__POS
0.989994
package edu.brown.pools; import org.apache.commons.pool.impl.StackObjectPool; import edu.brown.pools.TypedPoolableObjectFactory; import junit.framework.TestCase; public class TestTypedPoolableObjectFactory extends TestCase { public static class MockObject implements Poolable { boolean finished = false;...
__label__POS
0.992795
#include <stdlib.h> #include <string.h> #include <stdio.h> #include "ord_type.h" char* ord_type_ord_type_ToString(ems___rest_api_ord_type__e ord_type) { char *ord_typeArray[] = { "NULL", "LIMIT" }; return ord_typeArray[ord_type]; } ems___rest_api_ord_type__e ord_type_ord_type_FromString(char* ord_type) { ...
__label__POS
0.76358
package edu.brown.workload.filters; import java.util.Iterator; import org.junit.Test; import org.voltdb.catalog.CatalogType; import edu.brown.hstore.HStoreConstants; import edu.brown.workload.AbstractTraceElement; import edu.brown.workload.TransactionTrace; /** * @author pavlo */ public class TestBasePartitionTxn...
__label__POS
0.880795
#include <stdlib.h> #include <string.h> #include <stdio.h> #include "time_in_force.h" char* time_in_force_time_in_force_ToString(ems___rest_api_time_in_force__e time_in_force) { char *time_in_forceArray[] = { "NULL", "GOOD_TILL_CANCEL", "GOOD_TILL_TIME_EXCHANGE", "GOOD_TILL_TIME_OMS", "FILL_OR_KILL", "IMMEDIATE_...
__label__POS
0.731918
package edu.brown.workload.filters; import java.io.File; import edu.brown.BaseTestCase; import edu.brown.utils.ProjectType; import edu.brown.workload.Workload; public abstract class AbstractTestFilter extends BaseTestCase { protected static final int WORKLOAD_XACT_LIMIT = 1000; protected static final int NU...
__label__POS
0.942023
package edu.brown.workload.filters; import java.util.HashMap; import java.util.Iterator; import java.util.Map; import java.util.Map.Entry; import org.junit.Test; import org.voltdb.benchmark.tpcc.procedures.delivery; import org.voltdb.benchmark.tpcc.procedures.neworder; import org.voltdb.benchmark.tpcc.procedures.slev...
__label__POS
0.728639
package edu.brown.workload.filters; import java.util.Iterator; import org.junit.Test; import org.voltdb.benchmark.tpcc.procedures.neworder; import org.voltdb.catalog.CatalogType; import org.voltdb.catalog.ProcParameter; import org.voltdb.catalog.Procedure; import edu.brown.workload.AbstractTraceElement; import edu.b...
__label__POS
0.928052
#include <stdlib.h> #include <string.h> #include <stdio.h> #include "ord_side.h" char* ord_side_ord_side_ToString(ems___rest_api_ord_side__e ord_side) { char *ord_sideArray[] = { "NULL", "BUY", "SELL" }; return ord_sideArray[ord_side]; } ems___rest_api_ord_side__e ord_side_ord_side_FromString(char* ord_side...
__label__POS
0.728239
#include <stdlib.h> #include <string.h> #include <stdio.h> #include "ord_status.h" char* ord_status_ord_status_ToString(ems___rest_api_ord_status__e ord_status) { char *ord_statusArray[] = { "NULL", "RECEIVED", "ROUTING", "ROUTED", "NEW", "PENDING_CANCEL", "PARTIALLY_FILLED", "FILLED", "CANCELED", "REJECTED" }; ...
__label__POS
0.712593
package edu.brown.benchmark.ycsb; import edu.brown.BaseTestCase; import edu.brown.profilers.ProfileMeasurement; //import edu.brown.benchmark.ycsb.distributions.ZipfianGenerator; import edu.brown.utils.ProjectType; public class TestYCSBUtil extends BaseTestCase { // private long init_record_count = 1000; // pri...
__label__POS
0.849271
/** * */ package edu.brown.designer.partitioners; import java.io.File; import java.util.List; import java.util.Observable; import org.voltdb.catalog.*; import edu.brown.BaseTestCase; import edu.brown.designer.*; import edu.brown.graphs.IGraph; import edu.brown.gui.common.GraphVisualizationPanel; import edu.brown....
__label__POS
0.753425
import '@apollo-elements/components/apollo-mutation'; import { ApolloQueryController } from '@apollo-elements/core'; import { LitElement, html } from 'lit'; import { customElement } from 'lit/decorators.js'; import { ifDefined } from 'lit/directives/if-defined.js'; import { ProfileQuery } from './Profile.query.graphql...
__label__POS
0.600281
package edu.brown.hstore.estimators; import java.util.List; import edu.brown.catalog.special.CountedStatement; import edu.brown.hstore.estimators.Estimate; import edu.brown.markov.EstimationThresholds; import edu.brown.utils.PartitionSet; public class MockEstimate implements Estimate { private final long remaini...
__label__POS
0.999461
package edu.brown.hstore.util; import java.util.LinkedList; import java.util.Queue; import edu.brown.BaseTestCase; import edu.brown.rand.DefaultRandomGenerator; /** * * @author pavlo */ public class TestThrottlingQueue extends BaseTestCase { private static final int QUEUE_THRESHOLD = 20; private static ...
__label__POS
0.724202