Gifts are generally taxed with their money-equivalent in Germany, but there are exemptions, depending on how you are related.
The name of the tax is: Schenkungssteuer and here is some detailed information (in German)
What you do with your possessions after they are gifted to you will underly the same rules as if you bought it, so if you sell a stock it is generally subject to the Abgeltungssteuer, if you sell it without any gains, that is nil though.
(Disclaimer: This is to the best of my knowledge, but I am not a legal professional and mymay not be held liable for any errors)