def process(request, download_key):
    valid, msg, dl_product = _validate_key(download_key)
    if not valid:
        context = RequestContext(request, {'error_message': msg})
        return render_to_response('shop/download.html',
                                  context_instance=context)
    else:
        # The key is valid so let's set the session variable and redirect to the
        # download view
        request.session['download_key'] = download_key
        url = urlresolvers.reverse('satchmo_download_send', kwargs= {'download_key': download_key})
        context = RequestContext(request, {'download_product': dl_product,
                                            'dl_url' : url})
        return render_to_response('shop/download.html', context_instance=context)
Validate that the key is good, then set a session variable.
dataset/ETHPy150Open dokterbob/satchmo/satchmo/apps/product/modules/downloadable/views.py/process