<%@ Page Language="C#" AutoEventWireup="true" %>

<%

    var ckSize = Request.QueryString.Get("ckSize");
    var value = 0;
    if (int.TryParse(ckSize, out value)) { }
    if (value < 1) value = 100;

    using (var rng = new System.Security.Cryptography.RNGCryptoServiceProvider())
    {
        var block = 1024;
        var ks = 1048576 / block;
        var buffer = new byte[block];

        Response.ContentType = "application/octet-stream";
        var stream = Response.OutputStream;
        for (var m = 0; m < value; m++)
        {

            for (var k = 0; k < ks; k++)
            {
                rng.GetBytes(buffer);
                stream.Write(buffer, 0, block);
            }
        }
    }

%>