It’s not clear what you’re asking for here, but I read your question as ‘How can I can I require registration/login before checkout?’
This is actually a simple setting in the WooCommerce administration area. Simply go to WooCommerce => Settings, select the ‘Accounts & Privacy’ tab and uncheck the ‘Allow customer to place orders without an account’
This option requires that a user either has an account and is logged in or creates an account during the checkout.